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

Method load_settings

src/SB/Game/zEntPlayerOOBState.cpp:318–364  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

316} // namespace oob_state
317
318void oob_state::load_settings(xIniFile& ini)
319{
320 fixed.hand_model = xIniGetString(&ini, "player.state.out_of_bounds.hand_model", "hand");
321 fixed.out_time = xIniGetFloat(&ini, "player.state.out_of_bounds.out_time", 9.0f);
322 fixed.reset_time = xIniGetFloat(&ini, "player.state.out_of_bounds.reset_time", 3.0f);
323 fixed.cam_dist = xIniGetFloat(&ini, "player.state.out_of_bounds.cam_dist", 3.0f);
324 fixed.cam_height = xIniGetFloat(&ini, "player.state.out_of_bounds.cam_height", 1.0f);
325 fixed.cam_pitch =
326 (xIniGetFloat(&ini, "player.state.out_of_bounds.cam_pitch", 10.0f) * 0.017453292f);
327 fixed.reorient_time = xIniGetFloat(&ini, "player.state.out_of_bounds.reorient_time", 0.25f);
328 fixed.in_loc.x = xIniGetFloat(&ini, "player.state.out_of_bounds.in_loc.x", 0.2f);
329 fixed.in_loc.y = xIniGetFloat(&ini, "player.state.out_of_bounds.in_loc.y", 0.0f);
330 fixed.out_loc.x = xIniGetFloat(&ini, "player.state.out_of_bounds.out_loc.x", 1.0f);
331 fixed.out_loc.y = xIniGetFloat(&ini, "player.state.out_of_bounds.out_loc.y", 0.0f);
332 fixed.grab.in_wait_time =
333 xIniGetFloat(&ini, "player.state.out_of_bounds.grab.in_wait_time", 0.0f);
334 fixed.grab.in_vel = xIniGetFloat(&ini, "player.state.out_of_bounds.grab.in_vel", 2.0f);
335 fixed.grab.in_stop_dist =
336 xIniGetFloat(&ini, "player.state.out_of_bounds.grab.in_stop_dist", 0.05f);
337 fixed.grab.out_wait_time =
338 xIniGetFloat(&ini, "player.state.out_of_bounds.grab.out_wait_time", 0.5f);
339 fixed.grab.out_vel = xIniGetFloat(&ini, "player.state.out_of_bounds.grab.out_vel", 0.5f);
340 fixed.grab.out_start_dist =
341 xIniGetFloat(&ini, "player.state.out_of_bounds.grab.out_start_dist", 0.1f);
342 fixed.grab.fade_start_time =
343 xIniGetFloat(&ini, "player.state.out_of_bounds.grab.fade_start_time", 0.0f);
344 fixed.grab.fade_time = xIniGetFloat(&ini, "player.state.out_of_bounds.grab.fade_time", 2.0f);
345 fixed.drop.in_vel = xIniGetFloat(&ini, "player.state.out_of_bounds.drop.in_vel", 0.5f);
346 fixed.drop.in_stop_dist =
347 xIniGetFloat(&ini, "player.state.out_of_bounds.drop.in_stop_dist", 0.1f);
348 fixed.drop.out_wait_time =
349 xIniGetFloat(&ini, "player.state.out_of_bounds.drop.out_wait_time", 0.5f);
350 fixed.drop.out_vel = xIniGetFloat(&ini, "player.state.out_of_bounds.drop.out_vel", 2.0f);
351 fixed.drop.out_start_dist =
352 xIniGetFloat(&ini, "player.state.out_of_bounds.drop.out_start_dist", 0.05f);
353 fixed.drop.fade_start_time =
354 xIniGetFloat(&ini, "player.state.out_of_bounds.drop.fade_start_time", 0.0f);
355 fixed.drop.fade_time = xIniGetFloat(&ini, "player.state.out_of_bounds.drop.fade_time", 1.5f);
356 fixed.hand_size_x = xIniGetFloat(&ini, "player.state.out_of_bounds.hand_size_x", 0.4f);
357 fixed.hand_size_y = xIniGetFloat(&ini, "player.state.out_of_bounds.hand_size_y", 0.4f);
358 fixed.hand_yaw =
359 (xIniGetFloat(&ini, "player.state.out_of_bounds.hand_yaw", 0.0f) * 0.017453292f);
360 fixed.hand_pitch =
361 (xIniGetFloat(&ini, "player.state.out_of_bounds.hand_pitch", 0.0f) * 0.017453292f);
362 fixed.hand_roll =
363 (xIniGetFloat(&ini, "player.state.out_of_bounds.hand_roll", 90.0f) * 0.017453292f);
364}
365
366void oob_state::init()
367{

Callers

nothing calls this directly

Calls 2

xIniGetStringFunction · 0.85
xIniGetFloatFunction · 0.85

Tested by

no test coverage detected