ACSUtils Wiki

An ACS library for ZDoom-based ports

User Tools

Site Tools


source_port_identification

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
Last revisionBoth sides next revision
source_port_identification [2019/08/26 02:07] korshunsource_port_identification [2019/08/26 03:48] korshun
Line 5: Line 5:
 You can identify what engine your mod is running in using ACSUtils. This may be useful to avoid using features if they're not present in the engine your mod is running in. You can identify what engine your mod is running in using ACSUtils. This may be useful to avoid using features if they're not present in the engine your mod is running in.
  
-<note important>Don't use [[functions:IsGZDoom]] to check for OpenGL renderer. Use [[functions:IsOpenGL]]!</note>+<note important>Don't use these functions to check for renderer. Use [[renderer_identification|IsOpenGL]]!</note>
  
 ===== Functions ===== ===== Functions =====
  
-  [[functions:IsZDoom]] +==== Is<Port> ==== 
-  * [[functions:IsGZDoom]] + 
-  * [[functions:IsZandronum]] +  ''bool IsZDoom()'' -- returns true if the mod is running in ZDoom, but not GZDoom or Zandronum. 
-  * [[functions:IdentifySourcePort]]+  * ''bool IsGZDoom()'' -- returns true if the mod is running in GZDoom or a GZDoom-based engine like Zandronum. 
 +  * ''bool IsZandronum()'' -- returns true if the mod is running in Zandronum. 
 + 
 +==== IdentifySourcePort ==== 
 + 
 +''int IdentifySourcePort()'' -- returns the exact source port the mod is running in. It can be one of the following constants: 
 +  * ''PORT_ZDOOM'' -- ZDoom 
 +  * ''PORT_GZDOOM'' - GZDoom 
 +  * ''PORT_ZANDRONUM'' -- Zandronum 
 + 
  
 ===== How it works ===== ===== How it works =====