void HUD_SW_Class::update_motion_sensor(short time_elapsed) { if (!(GET_GAME_OPTIONS() & _motion_sensor_does_not_work) && MotionSensorActive) { if (motion_sensor_has_changed() || time_elapsed == NONE) { render_motion_sensor(time_elapsed); ForceUpdate = true; screen_rectangle *r = get_interface_rectangle(_motion_sensor_rect); DrawShapeAtXY(BUILD_DESCRIPTOR(_collection_interface, _motion_sensor_mount), r->left, r->top); } } }
void mark_player_network_stats_as_dirty( short player_index) { if (GET_GAME_OPTIONS()&_live_network_stats) { struct player_data *player= get_player_data(player_index); set_current_inventory_screen(player_index, _network_statistics); SET_INVENTORY_DIRTY_STATE(player, TRUE); } return; }
static void update_motion_sensor( short time_elapsed) { if(!(GET_GAME_OPTIONS() & _motion_sensor_does_not_work)) { if (time_elapsed==NONE) { reset_motion_sensor(current_player_index); } motion_sensor_scan(time_elapsed); if (motion_sensor_has_changed()) { screen_rectangle *destination= get_interface_rectangle(_motion_sensor_rect); _draw_screen_shape_at_x_y(BUILD_DESCRIPTOR(_collection_interface, _motion_sensor_mount), destination->left, destination->top); } } return; }