DCDecomp
A decompilation of Dark Cloud for the PlayStation 2
Loading...
Searching...
No Matches
MONSTOR Struct Reference

#include <monstorunit.hpp>

Public Attributes

s32 state
 
s32 last_attacker
 
s32 stop_timer
 
s32 poison_timer
 
s32 anger_timer
 
s32 slow_timer
 
float player_distance
 
s32 base_model
 
s32 max_hp
 
s32 hp
 
s16 attachment_kind
 
s16 attachment_weight [5]
 
s32 money
 
s32 money_chance
 
s32 stolen_money
 
s16 kind
 
s16 name_no
 
float body_radius
 
float collision_radius
 
CCPoly * collision_poly
 
s32 collision_poly_count
 
u8 unk_054 [0x0C]
 
sceVu0FVECTOR movement
 
sceVu0FVECTOR turn_target
 
float movement_speed
 
float turn_speed
 
s32 falls
 
u8 unk_08C [4]
 
s16 defense
 
s16 hardness
 
s16 unk_094
 
u8 unk_096 [2]
 
s32 invincible_timer
 
u8 unk_09C [4]
 
s16 drop_item
 
u8 unk_0A2 [2]
 
float clip_distance
 
s32 collision_off_timer
 
s16 shot_effect
 
s16 shot_effect2
 
s32 exp
 
s16 attachment_count
 
u8 unk_0B6 [2]
 
float ground_distance
 
float ground_y
 
s32 last_hit_damage
 
s32 last_hit_id
 
s32 hit_element
 
float shadow_length
 
s16 shadow_visible
 
s16 shadow_enabled
 
s16 revealed
 
s16 free_fall
 
s16 steal_item
 
s16 drops_items
 
s16 item_damage_rate
 
s16 status_chance
 
s16 rare_item
 
u8 unk_0E2 [2]
 
s32 invincible_blocked
 
s32 view_held
 
s16 requested_motion
 
s16 requested_motion_flags
 
float requested_motion_speed
 
s16 motion_reset_pending
 
s16 event_flag2
 
s16 event_flag2_pending
 
u8 unk_0FA [2]
 
CFrame * lockon_frame
 
sceVu0FVECTOR lockon_position
 
float lockon_scale_x
 
float lockon_scale_y
 
float lock_range
 
s16 lockon_enabled
 
u8 unk_11E [2]
 
float palette_alpha
 
float palette_alpha_step
 
s32 palette_delay
 
u8 unk_12C [0x04]
 
sceVu0FVECTOR palette_target
 
sceVu0FVECTOR palette_color
 
sceVu0FVECTOR palette_override
 
s32 palette_override_pending
 
s32 palette_cycles
 
float palette_step
 
float palette_blend
 
sceVu0FVECTOR knockback_direction
 
sceVu0FVECTOR knockback
 

Detailed Description

Records what one monster of the floor is doing.

Definition at line 63 of file monstorunit.hpp.

Member Data Documentation

◆ state

s32 MONSTOR::state

2 while the monster stands on the floor and takes part.

Definition at line 64 of file monstorunit.hpp.

◆ last_attacker

s32 MONSTOR::last_attacker

Character credited with the kill, or -1.

Definition at line 65 of file monstorunit.hpp.

◆ stop_timer

s32 MONSTOR::stop_timer

Steps left before the stop status wears off; the monster cannot move or act meanwhile.

Definition at line 66 of file monstorunit.hpp.

◆ poison_timer

s32 MONSTOR::poison_timer

Steps left until poison next takes a tenth of the monster's life.

Definition at line 67 of file monstorunit.hpp.

◆ anger_timer

s32 MONSTOR::anger_timer

Steps left of anger, which doubles the damage the monster deals and halves the damage it takes.

Definition at line 68 of file monstorunit.hpp.

◆ slow_timer

s32 MONSTOR::slow_timer

Steps left of the slowing status, which halves the monster's motion and movement speed.

Definition at line 69 of file monstorunit.hpp.

◆ player_distance

float MONSTOR::player_distance

Distance from the player, measured by CheckViewLevel.

Definition at line 70 of file monstorunit.hpp.

◆ base_model

s32 MONSTOR::base_model

Index of the loaded model the monster was set up from.

Definition at line 71 of file monstorunit.hpp.

◆ max_hp

s32 MONSTOR::max_hp

Life the monster has at full health.

Definition at line 72 of file monstorunit.hpp.

◆ hp

s32 MONSTOR::hp

Life the monster has left.

Definition at line 73 of file monstorunit.hpp.

◆ attachment_kind

s16 MONSTOR::attachment_kind

Family of the monster.

See also
MonsterFamily.

Definition at line 74 of file monstorunit.hpp.

◆ attachment_weight

s16 MONSTOR::attachment_weight[5]

Weight of each attachment kind in the drop choice and in elemental damage.

Definition at line 75 of file monstorunit.hpp.

◆ money

s32 MONSTOR::money

Least amount of money the monster drops.

Definition at line 76 of file monstorunit.hpp.

◆ money_chance

s32 MONSTOR::money_chance

Percentage chance that the monster drops money.

Definition at line 77 of file monstorunit.hpp.

◆ stolen_money

s32 MONSTOR::stolen_money

Money the monster has drained from the player and drops when defeated.

Definition at line 78 of file monstorunit.hpp.

◆ kind

s16 MONSTOR::kind

Kind of monster model.

See also
MonsterKind.

Definition at line 79 of file monstorunit.hpp.

◆ name_no

s16 MONSTOR::name_no

Identifies the name the lock-on cursor shows.

Definition at line 80 of file monstorunit.hpp.

◆ body_radius

float MONSTOR::body_radius

Radius the player and the walls keep from the monster.

Definition at line 81 of file monstorunit.hpp.

◆ collision_radius

float MONSTOR::collision_radius

Radius the monster keeps from other monsters.

Definition at line 82 of file monstorunit.hpp.

◆ collision_poly

CCPoly* MONSTOR::collision_poly

Polygons the monster tests its movement against this step.

Definition at line 83 of file monstorunit.hpp.

◆ collision_poly_count

s32 MONSTOR::collision_poly_count

Polygons in collision_poly.

Definition at line 84 of file monstorunit.hpp.

◆ unk_054

u8 MONSTOR::unk_054[0x0C]

Definition at line 85 of file monstorunit.hpp.

◆ movement

sceVu0FVECTOR MONSTOR::movement

Direction the monster moves in.

Definition at line 86 of file monstorunit.hpp.

◆ turn_target

sceVu0FVECTOR MONSTOR::turn_target

Point the monster turns to face.

Definition at line 87 of file monstorunit.hpp.

◆ movement_speed

float MONSTOR::movement_speed

Distance the monster moves each step.

Definition at line 88 of file monstorunit.hpp.

◆ turn_speed

float MONSTOR::turn_speed

Angle the monster turns each step; zero once the turn is done.

Definition at line 89 of file monstorunit.hpp.

◆ falls

s32 MONSTOR::falls

Nonzero while the monster keeps to the ground beneath it and bounces off it.

Definition at line 90 of file monstorunit.hpp.

◆ unk_08C

u8 MONSTOR::unk_08C[4]

Definition at line 91 of file monstorunit.hpp.

◆ defense

s16 MONSTOR::defense

Amount taken off the damage of each hit.

Definition at line 92 of file monstorunit.hpp.

◆ hardness

s16 MONSTOR::hardness

Wear the monster puts on the weapon that hits it.

Definition at line 93 of file monstorunit.hpp.

◆ unk_094

s16 MONSTOR::unk_094

Definition at line 94 of file monstorunit.hpp.

◆ unk_096

u8 MONSTOR::unk_096[2]

Definition at line 95 of file monstorunit.hpp.

◆ invincible_timer

s32 MONSTOR::invincible_timer

Steps left in which the monster takes no hits.

Definition at line 96 of file monstorunit.hpp.

◆ unk_09C

u8 MONSTOR::unk_09C[4]

Definition at line 97 of file monstorunit.hpp.

◆ drop_item

s16 MONSTOR::drop_item

Key or attachment the monster drops when defeated, or -1.

Definition at line 98 of file monstorunit.hpp.

◆ unk_0A2

u8 MONSTOR::unk_0A2[2]

Definition at line 99 of file monstorunit.hpp.

◆ clip_distance

float MONSTOR::clip_distance

Distance past which the monster stops taking part and being drawn.

Definition at line 100 of file monstorunit.hpp.

◆ collision_off_timer

s32 MONSTOR::collision_off_timer

Steps left in which the monster moves through the player, other monsters and walls.

Definition at line 101 of file monstorunit.hpp.

◆ shot_effect

s16 MONSTOR::shot_effect

Effect the first projectile fires, or -1.

Definition at line 102 of file monstorunit.hpp.

◆ shot_effect2

s16 MONSTOR::shot_effect2

Effect the second projectile fires, or -1.

Definition at line 103 of file monstorunit.hpp.

◆ exp

s32 MONSTOR::exp

Experience the weapon that defeats the monster gains.

Definition at line 104 of file monstorunit.hpp.

◆ attachment_count

s16 MONSTOR::attachment_count

Attachment characters the monster draws with.

Definition at line 105 of file monstorunit.hpp.

◆ unk_0B6

u8 MONSTOR::unk_0B6[2]

Definition at line 106 of file monstorunit.hpp.

◆ ground_distance

float MONSTOR::ground_distance

Height of the monster above the ground beneath it.

Definition at line 107 of file monstorunit.hpp.

◆ ground_y

float MONSTOR::ground_y

Height of the ground beneath the monster.

Definition at line 108 of file monstorunit.hpp.

◆ last_hit_damage

s32 MONSTOR::last_hit_damage

Damage the last hit did, or -1 once a new motion starts.

Definition at line 109 of file monstorunit.hpp.

◆ last_hit_id

s32 MONSTOR::last_hit_id

Identifies the attack that last hit the monster, or -1.

Definition at line 110 of file monstorunit.hpp.

◆ hit_element

s32 MONSTOR::hit_element

Element of the attack that last hit the monster; 5 for none.

Definition at line 111 of file monstorunit.hpp.

◆ shadow_length

float MONSTOR::shadow_length

Distance the monster's shadow is cast below it.

Definition at line 112 of file monstorunit.hpp.

◆ shadow_visible

s16 MONSTOR::shadow_visible

Nonzero while the monster's shadow draws.

Definition at line 113 of file monstorunit.hpp.

◆ shadow_enabled

s16 MONSTOR::shadow_enabled

Nonzero when the script lets the monster's shadow draw.

Definition at line 114 of file monstorunit.hpp.

◆ revealed

s16 MONSTOR::revealed

0 while the monster hides in a treasure chest, 1 once opened until its appearance script runs, -1 while in play.

Definition at line 115 of file monstorunit.hpp.

◆ free_fall

s16 MONSTOR::free_fall

Nonzero lets a falling monster stay above the ground; zero keeps it on the ground.

Definition at line 116 of file monstorunit.hpp.

◆ steal_item

s16 MONSTOR::steal_item

Item the player can steal from the monster, or -1.

Definition at line 117 of file monstorunit.hpp.

◆ drops_items

s16 MONSTOR::drops_items

Nonzero when the monster can drop a key, an attachment or money.

Definition at line 118 of file monstorunit.hpp.

◆ item_damage_rate

s16 MONSTOR::item_damage_rate

Percentage of damage taken from hits no character owns.

Definition at line 119 of file monstorunit.hpp.

◆ status_chance

s16 MONSTOR::status_chance

Percentage chance that a status hit takes hold.

Definition at line 120 of file monstorunit.hpp.

◆ rare_item

s16 MONSTOR::rare_item

Item the monster sometimes drops in place of a key, or -1.

Definition at line 121 of file monstorunit.hpp.

◆ unk_0E2

u8 MONSTOR::unk_0E2[2]

Definition at line 122 of file monstorunit.hpp.

◆ invincible_blocked

s32 MONSTOR::invincible_blocked

Nonzero to refuse invincibility to a living monster; cleared at each damage check.

Definition at line 123 of file monstorunit.hpp.

◆ view_held

s32 MONSTOR::view_held

Nonzero while the view limit holds the monster out of play.

Definition at line 124 of file monstorunit.hpp.

◆ requested_motion

s16 MONSTOR::requested_motion

Motion the script asked the monster to play.

Definition at line 125 of file monstorunit.hpp.

◆ requested_motion_flags

s16 MONSTOR::requested_motion_flags

Flags of the requested motion.

Definition at line 126 of file monstorunit.hpp.

◆ requested_motion_speed

float MONSTOR::requested_motion_speed

Speed of the requested motion; below zero for the motion's own.

Definition at line 127 of file monstorunit.hpp.

◆ motion_reset_pending

s16 MONSTOR::motion_reset_pending

Nonzero while the requested motion waits to be restarted after a status ends.

Definition at line 128 of file monstorunit.hpp.

◆ event_flag2

s16 MONSTOR::event_flag2

Value returned when CheckEventFlag2 consumes the event.

Definition at line 129 of file monstorunit.hpp.

◆ event_flag2_pending

s16 MONSTOR::event_flag2_pending

Nonzero until CheckEventFlag2 consumes the event.

Definition at line 130 of file monstorunit.hpp.

◆ unk_0FA

u8 MONSTOR::unk_0FA[2]

Definition at line 131 of file monstorunit.hpp.

◆ lockon_frame

CFrame* MONSTOR::lockon_frame

Frame the lock-on cursor stands on, or zero for the monster's position.

Definition at line 132 of file monstorunit.hpp.

◆ lockon_position

sceVu0FVECTOR MONSTOR::lockon_position

World position of lockon_frame.

Definition at line 133 of file monstorunit.hpp.

◆ lockon_scale_x

float MONSTOR::lockon_scale_x

Width scale of the lock-on cursor.

Definition at line 134 of file monstorunit.hpp.

◆ lockon_scale_y

float MONSTOR::lockon_scale_y

Height scale of the lock-on cursor.

Definition at line 135 of file monstorunit.hpp.

◆ lock_range

float MONSTOR::lock_range

Distance up to which the monster can be locked on to.

Definition at line 136 of file monstorunit.hpp.

◆ lockon_enabled

s16 MONSTOR::lockon_enabled

Nonzero while the monster can be locked on to.

Definition at line 137 of file monstorunit.hpp.

◆ unk_11E

u8 MONSTOR::unk_11E[2]

Definition at line 138 of file monstorunit.hpp.

◆ palette_alpha

float MONSTOR::palette_alpha

Alpha of the monster's ambient light.

Definition at line 139 of file monstorunit.hpp.

◆ palette_alpha_step

float MONSTOR::palette_alpha_step

Amount the alpha falls by each step.

Definition at line 140 of file monstorunit.hpp.

◆ palette_delay

s32 MONSTOR::palette_delay

Steps to wait before the alpha starts falling.

Definition at line 141 of file monstorunit.hpp.

◆ unk_12C

u8 MONSTOR::unk_12C[0x04]

Definition at line 142 of file monstorunit.hpp.

◆ palette_target

sceVu0FVECTOR MONSTOR::palette_target

Colour the palette cycle blends towards.

Definition at line 143 of file monstorunit.hpp.

◆ palette_color

sceVu0FVECTOR MONSTOR::palette_color

Ambient colour the monster draws with.

Definition at line 144 of file monstorunit.hpp.

◆ palette_override

sceVu0FVECTOR MONSTOR::palette_override

Colour that replaces the ambient for one draw.

Definition at line 145 of file monstorunit.hpp.

◆ palette_override_pending

s32 MONSTOR::palette_override_pending

Nonzero while the override colour waits to be applied.

Definition at line 146 of file monstorunit.hpp.

◆ palette_cycles

s32 MONSTOR::palette_cycles

Blend cycles left towards the target colour.

Definition at line 147 of file monstorunit.hpp.

◆ palette_step

float MONSTOR::palette_step

Amount the blend moves by each step; negated at each end.

Definition at line 148 of file monstorunit.hpp.

◆ palette_blend

float MONSTOR::palette_blend

Fraction of the way from the ambient to the target colour.

Definition at line 149 of file monstorunit.hpp.

◆ knockback_direction

sceVu0FVECTOR MONSTOR::knockback_direction

Direction a hit throws the monster in.

Definition at line 150 of file monstorunit.hpp.

◆ knockback

sceVu0FVECTOR MONSTOR::knockback

Knockback speed, the amount it falls by each step, and the scale hits apply to it.

Definition at line 151 of file monstorunit.hpp.