MCPcopy Create free account
hub / github.com/bfbbdecomp/bfbb / InitFX

Method InitFX

src/SB/Game/zNPCTypeBossSandy.cpp:761–868  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

759}
760
761void zNPCBSandy::InitFX()
762{
763 this->timeToNextBolt[0] = 0.0f;
764 this->timeToNextBolt[1] = 0.0f;
765 this->maxLightningWait[0] = 0.0f;
766 this->maxLightningWait[1] = 0.0f;
767
768 xMat4x3Copy((xMat4x3*)&this->sparkTransform[0][0], (xMat4x3*)&this->hangingScoreboard->model->Mat);
769 xMat4x3Copy((xMat4x3*)&this->sparkTransform[0][1], (xMat4x3*)&this->hangingScoreboard->model->Mat);
770 xMat4x3Copy((xMat4x3*)&this->sparkTransform[1][0], (xMat4x3*)&this->crashedScoreboard->model->Mat);
771 xVec3SMul((xVec3*)&this->sparkTransform[1][1], (xVec3*)&this->crashedScoreboard->model->Mat, 0.8f);
772 xVec3SMul((xVec3*)&this->sparkTransform[1][1].up, (xVec3*)&this->crashedScoreboard->model->Mat->at, -0.8f);
773 xVec3SMul((xVec3*)&this->sparkTransform[1][1].at, (xVec3*)&this->crashedScoreboard->model->Mat->up, 0.8f);
774 xVec3Copy((xVec3*)&this->sparkTransform[1][1].pos, (xVec3*)&this->crashedScoreboard->model->Mat->pos);
775 xVec3AddScaled((xVec3*)&this->sparkTransform[1][1].pos, (xVec3*)&this->crashedScoreboard->model->Mat->up, 4.5f);
776 xVec3AddScaled((xVec3*)&this->sparkTransform[1][1].pos, (xVec3*)&this->crashedScoreboard->model->Mat->at, 5.0f);
777 xVec3Init((xVec3*)&this->endPoints[0][0], -2.0f, 2.0f, 0.0f);
778 xVec3Init((xVec3*)&this->endPoints[0][1], 2.0f, 2.0f, 0.0f);
779
780 this->sparks[0].type = 0x3;
781 this->sparks[0].setup_degrees = 66.0f;
782 this->sparks[0].move_degrees = 66.0f;
783 this->sparks[0].rot_radius = 66.0f;
784 this->sparks[0].total_points = 0x10;
785 this->sparks[0].end_points = 0;
786 this->sparks[0].time = 0.25f;
787 this->sparks[0].arc_height = -1.5f;
788 this->sparks[0].thickness = 1.0f;
789 this->sparks[0].color.r = 0xa0;
790 this->sparks[0].color.g = 0xa0;
791 this->sparks[0].color.b = 0xff;
792 this->sparks[0].color.a = 0xc8;
793 this->sparks[0].rand_radius = 13.0f;
794 this->sparks[0].flags = 0x1c28;
795
796 xVec3Init((xVec3*)&this->endPoints[0][2], -2.0f, 2.0f, 0.0f);
797 xVec3Init((xVec3*)&this->endPoints[0][3], 2.0f, 2.0f, 0.0f);
798
799 this->sparks[1].type = 0x3;
800 this->sparks[1].setup_degrees = 66.0f;
801 this->sparks[1].move_degrees = 66.0f;
802 this->sparks[1].rot_radius = 66.0f;
803 this->sparks[1].total_points = 0x10;
804 this->sparks[1].end_points = 0;
805 this->sparks[1].time = 0.25f;
806 this->sparks[1].arc_height = -1.5f;
807 this->sparks[1].thickness = 1.0f;
808 this->sparks[1].color.r = 0xc8;
809 this->sparks[1].color.g = 0xc8;
810 this->sparks[1].color.b = 0x37;
811 this->sparks[1].color.a = 0xc8;
812 this->sparks[1].rand_radius = 13.0f;
813 this->sparks[1].flags = 0x1c28;
814
815 xVec3Init((xVec3*)&this->endPoints[1][0], 0.0f, 2.0f, 0.0f);
816 xVec3Init((xVec3*)&this->endPoints[1][1], 3.5f, 2.0f, 0.0f);
817
818 this->sparks[2].type = 0x3;

Callers

nothing calls this directly

Calls 5

xMat4x3CopyFunction · 0.85
xVec3SMulFunction · 0.85
xVec3CopyFunction · 0.85
xVec3AddScaledFunction · 0.85
xVec3InitFunction · 0.85

Tested by

no test coverage detected