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

Method update

src/SB/Game/zEntPlayerOOBState.cpp:841–878  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

839} // namespace oob_state
840
841U8 oob_state::update(xScene& scene, F32 dt)
842{
843 if ((shared.flags & 0x3) != 0x3)
844 {
845 return FALSE;
846 }
847
848 if (zSaveLoadGetPreAutoSave())
849 {
850 return FALSE;
851 }
852
853 if (oob_player_teleported)
854 {
855 shared.flags &= ~0x8;
856 }
857
858 if ((shared.flags & 0x8) && !(globals.player.ControlOff & 0x8000))
859 {
860 force_start();
861 }
862
863 while (true)
864 {
865 state_enum newtype = shared.state->update(scene, dt);
866 if (newtype == shared.state->type)
867 {
868 break;
869 }
870
871 shared.state->stop();
872 shared.state = shared.states[newtype];
873 shared.state->start();
874 }
875
876
877 return shared.control;
878}
879
880bool oob_state::IsPlayerInControl()
881{

Callers

nothing calls this directly

Calls 10

zSaveLoadGetPreAutoSaveFunction · 0.85
zSurfaceOutOfBoundsFunction · 0.85
update_max_out_timeFunction · 0.85
move_upFunction · 0.85
xModelEvalFunction · 0.85
zEntPlayerUpdateModelFunction · 0.85
zGameStateSwitchFunction · 0.70
move_rightFunction · 0.70
stopMethod · 0.45
startMethod · 0.45

Tested by

no test coverage detected