Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
MorsGames
GitHub Repository: MorsGames/sm64plus
Path: blob/master/src/game/behaviors/beta_bowser_anchor.inc.c
7861 views
1
/**
2
* Behavior for bhvBetaBowserAnchor.
3
* This seems to be a beta bowser anchor object. It continuously updates to be
4
* about the same distance away from Mario as Bowser is, and it is destructive.
5
*/
6
7
/**
8
* Update function for bhvBetaBowserAnchor.
9
* It continuously updates to be in front of Mario,
10
* and attacks all non-Mario objects it touches.
11
* It continuously sets its hitbox radius/height
12
* based on gDebugInfo[4].
13
*/
14
void bhv_beta_bowser_anchor_loop(void) {
15
// Set the object's position to be 30 units above Mario's feet,
16
// and 300 units in front of him.
17
cur_obj_set_pos_relative(gMarioObject, 0, 30.0f, 300.0f);
18
19
o->hitboxRadius = gDebugInfo[4][0] + 100;
20
o->hitboxHeight = gDebugInfo[4][1] + 300;
21
22
obj_attack_collided_from_other_object(o);
23
}
24
25