ghost.zh#
Variables#
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
|
const int |
Functions#
bool |
__IsPit(int combo) |
bool |
|
bool |
ghost2__OnSidePlatform(int x, int y, int xOff, int yOff, int h, int w) |
Variable descriptions#
const int GH_SHADOW_TILE = 27400
π Source
See docs/ghost/index.html for documentation. All User Settings Standard settings ββββββββββββββββββββ Small (1x1) shadow settings
const int GH_SHADOW_CSET = 7
π Source
const int GH_SHADOW_FRAMES = 4
π Source
const int GH_SHADOW_ANIM_SPEED = 8
π Source
const int GH_SHADOW_TRANSLUCENT = 1
π Source
0 = No, 1 = Yes
const int GH_SHADOW_FLICKER = 0
π Source
0 = No, 1 = Yes
const int GH_LARGE_SHADOW_TILE = 27392
π Source
Top-left corner
const int GH_LARGE_SHADOW_CSET = 7
π Source
const int GH_LARGE_SHADOW_FRAMES = 4
π Source
const int GH_LARGE_SHADOW_ANIM_SPEED = 8
π Source
const int GH_LARGE_SHADOW_MIN_WIDTH = 3
π Source
Enemies must be at least this wide
const int GH_LARGE_SHADOW_MIN_HEIGHT = 3
π Source
and this high to use large shadows
const int AUTOGHOST_MIN_FFC = 1
π Source
Min: 1, Max: 32
const int AUTOGHOST_MAX_FFC = 32
π Source
Min: 1, Max: 32
const int AUTOGHOST_MIN_ENEMY_ID = 20
π Source
Min: 20, Max: 511
const int AUTOGHOST_MAX_ENEMY_ID = 511
π Source
Min: 20, Max: 511
const int GH_DRAW_OVER_THRESHOLD = 32
π Source
Other settings
const int GH_GRAVITY = 0.16
π Source
const int GH_TERMINAL_VELOCITY = 3.2
π Source
const int GH_SPAWN_SPRITE = 22
π Source
Min: 0, Max: 255, Default: 22
const int GH_FAKE_Z = 0
π Source
0 = No, 1 = Yes
const int __GH_FAKE_EWEAPON_Z = 0
π Source
0 = No, 1 = Yes
const int GH_ENEMIES_FLICKER = 0
π Source
0 = No, 1 = Yes
const int GH_PREFER_GHOST_ZH_SHADOWS = 0
π Source
0 = No, 1 = Yes
const int GH_BLANK_TILE = 65456
π Source
Min: 0, Max: 65456
const int GH_INVISIBLE_COMBO = 1
π Source
Min: 1, Max: 65279
const int __GH_ALWAYS_USE_NAME = 0
π Source
Always read script name and combo from the enemyβs name, freeing up attributes 11 and 12
const int AUTOGHOST_READ_NAME = -1
π Source
End standard settings ββββββββββββββββββ- Advanced settings ββββββββββββββββββββ AutoGhost will read a script name from the enemyβs name if attribute 12 is set to this. Must be a negative number.
const int AUTOGHOST_DELIMITER = 64
π Source
When reading a script from the enemy name, this character marks the beginning of the script name. Default: 64 ( @ )
const int __GH_INVISIBLE_ALT = -1
π Source
Misc. attribute 11 can be set to this instead of GH_INVISIBLE_COMBO. Must be a negative number.
const int __GH_INVISIBLE_EXTEND = -2
π Source
This will use the invisible combo, but also set npc->Extend to 3 or 4, hiding the initial spawn puff. Must be a negative number.
const int __GH_USE_DRAWCOMBO = 1
π Source
If enabled, the FFC will be invisible, and Screen->DrawCombo will be used to display enemies.
const int __GH_FLASH_TIME = 32
π Source
Enemies flash or flicker for this many frames when hit. This does not affect enemies that use the invisible combo. Default: 32
const int __GH_KNOCKBACK_TIME = 16
π Source
Enemies will be knocked back for this many frames when hit. Default: 16 Max: 4095
const int __GH_KNOCKBACK_STEP = 4
π Source
The speed at which enemies are knocked back, in pixels per frame. Default: 4
const int __GH_DEFAULT_IMPRECISION = 2
π Source
The imprecision setting used when a movement function is called internally (except for walking functions).
const int __GH_CLEAR_FFC_LINK = 0
π Source
Whether to set ffc->Link=0 when cleaning up an FFC. In 2.50.3 RC1 and before, this does not work due to a bug. Set this to 1 only if youβre using a newer ZC version than 2.50.3 RC1.
const int __GH_FIX_255_ANONE = 1
π Source
For ZC Versions where Animation Style (None) does not set ->Tile, enable this.
const int __GH_ETHEREAL = 1
π Source
Set to 1 to make ghost ffcs Ethereal so that they cannot block other combo types/flags on the screen. Added in 2.8.12. The prior versions did not have this. Set to 0 if this causes bugs in legacy quests or scripts.
const int __GH_WEAPONS_HIT_PLATFORMS = 1
π Source
If set to 1, weapons in sideview will die when they hit a solid sideview platform. Set to 0 if this causes bugs in legacy quests or scripts.
const int __GH_FIX_EWM_FALL = 1
π Source
If set to 1, this will patch bugs where falling weapons can be inappropriately destroyed because of their position. Set to 0 if this causes bugs in legacy quests or scripts.
const int __GH_FIX_EWM_THROW = 1
π Source
If set to 1, this will patch bugs where thrown weapons can be inappropriately destroyed because of their position. Set to 0 if this causes bugs in legacy quests or scripts.
const int __GHI_NPC_DATA = 15
π Source
npc->Misc[] index Set this so it doesnβt conflict with other scripts. Legal values are 0-15.
const int __EWI_FLAGS = 15
π Source
Every index but this one can be used by non-ghost.zh EWeapons
const int __EWI_ID = 3
π Source
const int __EWI_XPOS = 4
π Source
const int __EWI_YPOS = 5
π Source
const int __EWI_WORK = 6
π Source
const int __EWI_WORK_2 = 7
π Source
Only used by a few movement types
const int __EWI_MOVEMENT = 8
π Source
const int __EWI_MOVEMENT_ARG = 9
π Source
const int __EWI_MOVEMENT_ARG_2 = 10
π Source
const int __EWI_LIFESPAN = 11
π Source
const int __EWI_LIFESPAN_ARG = 12
π Source
const int __EWI_ON_DEATH = 13
π Source
const int __EWI_ON_DEATH_ARG = 14
π Source
const int __EWI_DUMMY_SOUND = 2
π Source
These are only used by dummy EWeapons; they can use the same values as __EWI_XPOS and __EWI_YPOS
const int __EWI_DUMMY_STEP = 4
π Source
Function descriptions#
bool __IsPit(int combo) π Source
Returns true if the given combo should be considered a pit.
bool __HaveAmulet() π Source
Returns true if enemies are visible on screens with the βAll Enemies Are Invisibleβ flag enabled
bool ghost2__OnSidePlatform(int x, int y, int xOff, int yOff, int h, int w) π Source
Used to determine if a weapon hit a platform in sideview.