Hurt Boxes - MichelVGameMaker/HitBoxes_gml GitHub Wiki
Hurt Box:
Parameters for hitbox_create:
parameter | default | details |
---|---|---|
x | caller's x | x coordinate. mandatory. |
y | caller's y | y coordinate. mandatory. |
sprite_index | caller's mask | sprite is used to detect collision. mandatory. |
owner | calling instance | owning instance. |
Associated GSetters
owner_exists test if the owning instance exists. owner_get get the owning instance.
Associated Setters
owner_set (_instance, _do_offset = true)
- mask_set (_sprite) set the mask_index. Current scales, angles and positions are kept.
- angle_set (_angle) set the angle, that will refresh the attachment position so that Hurt Box is now attached like it is when calling this function.
- xscale_set (_scale) set the xscale, that will refresh the attachment position so that Hurt Box is now attached like it is when calling this function.
- yscale_set (_scale) set the yscale, that will refresh the attachment position so that Hurt Box is now attached like it is when calling this function.
- position_set (_x, _y, _do_offset) set the position, that will refresh the attachment position so that Hurt Box is now attached like it is when calling this function.
- attachment_set (_x, _y) set user-defined x-y attachment. Parameters should be passed in the owner's referential = considering owner has a default angle and scales (angle = 0, scales = 1) = how the owner'sprite appears in the Sprite editor.
- shape_set (_xfac, _yfac, _angle) set user-defined scales and angle. Parameters should be passed in the owner's referential = considering owner has a default angle and scales (angle = 0, scales = 1) = how the owner'sprite appears in the Sprite editor.
- mimic_angle_enable (_mimic) set the mimicing behavior dealing with owning instance's angle.
- mimic_xscale_enable (_mimic) set the mimicing behavior dealing with owning instance's xscale.
- mimic_yscale_enable (_mimic) set the mimicing behavior dealing with owning instance's yscale.
- mimic_image_index_enable(_mimic) set the mimicing behavior dealing with owning instance's image_index.
- follow_xy_enable (_follow) set the following behavior dealing with owning instance's coordinates.
- follow_angle_enable (_follow) set the following behavior dealing with owning instance's angle.
- follow_xscale_enable (_follow) set the following behavior dealing with owning instance's xscale.
- follow_yscale_enable (_follow) set the following behavior dealing with owning instance's yscale.