RigsofRods
Soft-body Physics Simulation
Data Structures | Public Member Functions | Data Fields | Private Member Functions | Private Attributes | Friends
RoR::Actor Class Reference

Softbody object; can be anything from soda can to a space shuttle Constructed from a truck definition file, see https://docs.rigsofrods.org/vehicle-creation/fileformat-truck/ To spawn in-game, use MSG_SIM_SPAWN_ACTOR_REQUESTED, see GameContext::PushMessage(), in AngelScript use game.pushMessage(); Gameplay states are described by enum ActorState. More...

#include <Actor.h>

+ Inheritance diagram for RoR::Actor:
+ Collaboration diagram for RoR::Actor:

Data Structures

struct  NetUpdate
 
struct  VehicleForceSensors
 

Public Member Functions

 Actor (ActorInstanceID_t actor_id, unsigned int vector_index, RigDef::DocumentPtr def, ActorSpawnRequest rq)
 
virtual ~Actor () override
 
void dispose ()
 Effectively destroys the object but keeps it in memory to satisfy shared pointers. More...
 
void ForceFeedbackStep (int steps)
 
void HandleInputEvents (float dt)
 
void HandleAngelScriptEvents (float dt)
 
void UpdateCruiseControl (float dt)
 Defined in 'gameplay/CruiseControl.cpp'. More...
 
bool Intersects (ActorPtr actor, Ogre::Vector3 offset=Ogre::Vector3::ZERO)
 Slow intersection test. More...
 
void resolveCollisions (Ogre::Vector3 direction)
 Moves the actor at most 'direction.length()' meters towards 'direction' to resolve any collisions. More...
 
void resolveCollisions (float max_distance, bool consider_up)
 Auto detects an ideal collision avoidance direction (front, back, left, right, up) Then moves the actor at most 'max_distance' meters towards that direction to resolve any collisions. More...
 
float getSteeringAngle ()
 
float getMinCameraRadius ()
 
int GetNumActiveConnectedBeams (int nodeid)
 Returns the number of active (non bounded) beams connected to a node. More...
 
void NotifyActorCameraChanged ()
 Logic: sound, display; Notify this vehicle that camera changed;. More...
 
float getAvgPropedWheelRadius ()
 
void setAirbrakeIntensity (float intensity)
 
void UpdateBoundingBoxes ()
 
void calculateAveragePosition ()
 
void UpdatePhysicsOrigin ()
 
void SoftReset ()
 
void SyncReset (bool reset_position)
 this one should be called only synchronously (without physics running in background) More...
 
void WriteDiagnosticDump (std::string const &filename)
 
PerVehicleCameraContextGetCameraContext ()
 
Ogre::Vector3 GetCameraDir ()
 
Ogre::Vector3 GetCameraRoll ()
 
Ogre::Vector3 GetFFbBodyForces () const
 
GfxActorGetGfxActor ()
 
void RequestUpdateHudFeatures ()
 
Ogre::Real getMinimalCameraRadius ()
 
float GetFFbHydroForces () const
 
bool isBeingReset () const
 
void UpdatePropAnimInputEvents ()
 
Physics state
ActorState getTruckState ()
 
Ogre::Vector3 getPosition ()
 
float getRotation ()
 
Ogre::Quaternion getOrientation ()
 
float getSpeed ()
 
Ogre::Vector3 getGForces ()
 
float getTotalMass (bool withLocked=true)
 
int getNodeCount ()
 
Ogre::Vector3 getNodePosition (int nodeNumber)
 Returns world position of node. More...
 
bool isNodeWheelRim (int nodeNumber)
 Is node marked as wheel rim? Note some wheel models use only tire nodes. See https://docs.rigsofrods.org/vehicle-creation/fileformat-truck/#wheels. More...
 
bool isNodeWheelTire (int nodeNumber)
 Is node marked as wheel tire? Note some wheel models use only tire nodes. See https://docs.rigsofrods.org/vehicle-creation/fileformat-truck/#wheels. More...
 
int getWheelNodeCount () const
 
float getWheelSpeed () const
 
void reset (bool keep_position=false)
 call this one to reset a truck from any context More...
 
float getShockSpringRate (int shock_number)
 
float getShockDamping (int shock_number)
 
float getShockVelocity (int shock_number)
 
int getShockNode1 (int shock_number)
 
int getShockNode2 (int shock_number)
 
void resetPosition (Ogre::Vector3 translation, bool setInitPosition)
 Moves the actor to given world coords. More...
 
void resetPosition (float px, float pz, bool setInitPosition, float miny)
 Moves the actor to given world coords. More...
 
void requestRotation (float rotation, Ogre::Vector3 center)
 
void requestAngleSnap (int division)
 
void requestTranslation (Ogre::Vector3 translation)
 
int getShockCount ()
 
Ogre::Vector3 getVelocity () const
 
Ogre::Vector3 getDirection ()
 average actor velocity, calculated using the actor positions of the last two frames More...
 
Ogre::Vector3 getRotationCenter ()
 
float getMinHeight (bool skip_virtual_nodes=true)
 
float getMaxHeight (bool skip_virtual_nodes=true)
 
float getHeightAboveGround (bool skip_virtual_nodes=true)
 
float getHeightAboveGroundBelow (float height, bool skip_virtual_nodes=true)
 
Ogre::Vector3 getMaxGForces ()
 
bool hasSlidenodes ()
 
void updateSlideNodePositions ()
 incrementally update the position of all SlideNodes More...
 
void updateSlideNodeForces (const Ogre::Real delta_time_sec)
 calculate and apply Corrective forces More...
 
void resetSlideNodePositions ()
 Recalculate SlideNode positions. More...
 
void resetSlideNodes ()
 Reset all the SlideNodes. More...
 
Physics editing
void scaleTruck (float value)
 
void setMass (float m)
 
void applyNodeBeamScales ()
 For GUI::NodeBeamUtils. More...
 
void searchBeamDefaults ()
 Searches for more stable beam defaults. More...
 
void updateInitPosition ()
 
User interaction
void parkingbrakeToggle ()
 
void tractioncontrolToggle ()
 
void antilockbrakeToggle ()
 
void toggleCustomParticles ()
 
bool getCustomParticleMode ()
 
void mouseMove (NodeNum_t node, Ogre::Vector3 pos, float force)
 
void tieToggle (int group=-1, ActorLinkingRequestType mode=ActorLinkingRequestType::TIE_TOGGLE, ActorInstanceID_t forceunlock_filter=ACTORINSTANCEID_INVALID)
 
bool isTied ()
 
void hookToggle (int group=-1, ActorLinkingRequestType mode=ActorLinkingRequestType::HOOK_TOGGLE, NodeNum_t mousenode=NODENUM_INVALID, ActorInstanceID_t forceunlock_filter=ACTORINSTANCEID_INVALID)
 
bool isLocked ()
 Are hooks locked? More...
 
void ropeToggle (int group=-1, ActorLinkingRequestType mode=ActorLinkingRequestType::ROPE_TOGGLE, ActorInstanceID_t forceunlock_filter=ACTORINSTANCEID_INVALID)
 
void engineTriggerHelper (int engineNumber, EngineTriggerType type, float triggerValue)
 
void toggleSlideNodeLock ()
 
bool getParkingBrake ()
 
void cruisecontrolToggle ()
 Defined in 'gameplay/CruiseControl.cpp'. More...
 
void toggleAxleDiffMode ()
 
void displayAxleDiffMode ()
 Cycles through the available inter axle diff modes. More...
 
int getAxleDiffMode ()
 Writes info to console/notify box. More...
 
void toggleWheelDiffMode ()
 
void displayWheelDiffMode ()
 Cycles through the available inter wheel diff modes. More...
 
int getWheelDiffMode ()
 Writes info to console/notify box. More...
 
void toggleTransferCaseMode ()
 
TransferCasegetTransferCaseMode ()
 Toggles between 2WD and 4WD mode. More...
 
void toggleTransferCaseGearRatio ()
 
Ogre::String getTransferCaseName ()
 Toggles between Hi and Lo mode. More...
 
void displayTransferCaseMode ()
 Gets the current transfer case mode name (4WD Hi, ...) More...
 
void setSmokeEnabled (bool enabled)
 Writes info to console/notify area. More...
 
bool getSmokeEnabled () const
 
Vehicle lights
BlinkType getBlinkType ()
 
void setBlinkType (BlinkType blink)
 
void toggleBlinkType (BlinkType blink)
 
bool getCustomLightVisible (int number)
 
void setCustomLightVisible (int number, bool visible)
 
bool getBeaconMode () const
 
void beaconsToggle ()
 
bool getBrakeLightVisible () const
 
bool getReverseLightVisible () const
 
int countCustomLights (int control_number)
 
int countFlaresByType (FlareType type)
 
void toggleHeadlights ()
 
BitMask_t getLightStateMask () const
 
void setLightStateMask (BitMask_t lightmask)
 Does all the necessary toggling. More...
 
bool getSideLightsVisible () const
 
void setSideLightsVisible (bool val)
 
bool getHeadlightsVisible () const
 
void setHeadlightsVisible (bool val)
 
bool getHighBeamsVisible () const
 
void setHighBeamsVisible (bool val)
 
bool getFogLightsVisible () const
 
void setFogLightsVisible (bool val)
 
void setBeaconMode (bool val)
 
Visual state updates
void updateSkidmarks ()
 Creates or updates skidmarks. More...
 
void prepareInside (bool inside)
 Prepares vehicle for in-cabin camera use. More...
 
void updateFlareStates (float dt)
 
void updateVisual (float dt=0)
 
void updateDashBoards (float dt)
 
void forceAllFlaresOff ()
 
Audio
void updateSoundSources ()
 
void muteAllSounds ()
 
void unmuteAllSounds ()
 
Subsystems
VehicleAIPtr getVehicleAI ()
 
Ogre::MaterialPtr getManagedMaterialInstance (const std::string &orig_name)
 
std::vector< std::string > getManagedMaterialNames ()
 
ReplaygetReplay ()
 
TyrePressuregetTyrePressure ()
 
Organizational
std::string getTruckName ()
 
std::string getTruckFileName ()
 
std::string getTruckFileResourceGroup ()
 
int getTruckType ()
 
Ogre::String getSectionConfig ()
 
int getInstanceId ()
 
CacheEntryPtrgetUsedActorEntry ()
 The actor entry itself. More...
 
CacheEntryPtrgetUsedSkinEntry ()
 
TuneupDefPtrgetWorkingTuneupDef ()
 
void ensureWorkingTuneupDef ()
 Creates a working tuneup def if it doesn't exist yet. More...
 
void removeWorkingTuneupDef ()
 Deletes the working tuneup def object if it exists. More...
 
bool isPreloadedWithTerrain () const
 
std::vector< authorinfo_tgetAuthors ()
 
std::vector< std::string > getDescription ()
 
- Public Member Functions inherited from RefCountingObject< Actor >
 RefCountingObject ()
 
virtual ~RefCountingObject ()
 
void AddRef ()
 
void Release ()
 

Data Fields

node_tar_nodes = nullptr
 
int * ar_nodes_id = nullptr
 Number in truck file, -1 for nodes generated by wheels/cinecam. More...
 
std::string * ar_nodes_name = nullptr
 Name in truck file, only if defined with 'nodes2'. More...
 
int ar_nodes_name_top_length = 0
 For nicely formatted diagnostic output. More...
 
int ar_num_nodes = 0
 
std::vector< float > ar_minimass
 minimum node mass in Kg More...
 
bool ar_minimass_skip_loaded_nodes = false
 
beam_tar_beams = nullptr
 
int ar_num_beams = 0
 
std::vector< beam_t * > ar_inter_beams
 Beams connecting 2 actors. More...
 
shock_tar_shocks = nullptr
 Shock absorbers. More...
 
int ar_num_shocks = 0
 Number of shock absorbers. More...
 
bool ar_has_active_shocks = false
 Are there active stabilizer shocks? More...
 
rotator_tar_rotators = nullptr
 
int ar_num_rotators = 0
 
wing_tar_wings = nullptr
 
int ar_num_wings = 0
 
std::vector< authorinfo_tauthors
 
std::vector< exhaust_texhausts
 
std::vector< rope_tar_ropes
 
std::vector< ropable_tar_ropables
 
std::vector< tie_tar_ties
 
std::vector< hook_tar_hooks
 
std::vector< flare_tar_flares
 
std::vector< Airbrake * > ar_airbrakes
 
CmdKeyArray ar_command_key
 BEWARE: commandkeys are indexed 1-MAX_COMMANDS! More...
 
Ogre::AxisAlignedBox ar_bounding_box
 standard bounding box (surrounds all nodes of an actor) More...
 
Ogre::AxisAlignedBox ar_evboxes_bounding_box
 bounding box around nodes eligible for eventbox triggering More...
 
Ogre::AxisAlignedBox ar_predicted_bounding_box
 
float ar_initial_total_mass = 0.f
 
std::vector< float > ar_initial_node_masses
 
std::vector< Ogre::Vector3 > ar_initial_node_positions
 
std::vector< std::pair< float, float > > ar_initial_beam_defaults
 
std::vector< wheeldetacher_tar_wheeldetachers
 
std::vector< std::vector< int > > ar_node_to_node_connections
 
std::vector< std::vector< int > > ar_node_to_beam_connections
 
std::vector< Ogre::AxisAlignedBox > ar_collision_bounding_boxes
 smart bounding boxes, used for determining the state of an actor (every box surrounds only a subset of nodes) More...
 
std::vector< Ogre::AxisAlignedBox > ar_predicted_coll_bounding_boxes
 
std::map< std::string, Ogre::MaterialPtr > ar_managed_materials
 
std::vector< UniqueCommandKeyPairar_unique_commandkey_pairs
 UI helper for displaying command control keys to user (must be built at spawn). More...
 
int ar_num_contactable_nodes = 0
 Total number of nodes which can contact ground or cabs. More...
 
int ar_num_contacters = 0
 Total number of nodes which can selfcontact cabs. More...
 
wheel_t ar_wheels [MAX_WHEELS] = {}
 
int ar_num_wheels = 0
 
cparticle_t ar_custom_particles [MAX_CPARTICLES] = {}
 
int ar_num_custom_particles = 0
 
soundsource_t ar_soundsources [MAX_SOUNDSCRIPTS_PER_TRUCK] = {}
 
int ar_num_soundsources = 0
 
AeroEnginear_aeroengines [MAX_AEROENGINES] = {}
 
int ar_num_aeroengines = 0
 
Screwpropar_screwprops [MAX_SCREWPROPS] = {}
 
int ar_num_screwprops = 0
 
int ar_cabs [MAX_CABS *3] = {}
 
int ar_num_cabs = 0
 
std::vector< hydrobeam_tar_hydros
 
int ar_collcabs [MAX_CABS] = {}
 
collcab_rate_t ar_inter_collcabrate [MAX_CABS] = {}
 
collcab_rate_t ar_intra_collcabrate [MAX_CABS] = {}
 
int ar_num_collcabs = 0
 
int ar_buoycabs [MAX_CABS] = {}
 
int ar_buoycab_types [MAX_CABS] = {}
 
int ar_num_buoycabs = 0
 
NodeNum_t ar_camera_rail [MAX_CAMERARAIL] = {}
 Nodes defining camera-movement spline. More...
 
int ar_num_camera_rails = 0
 
bool ar_hide_in_actor_list = false
 Hide in list of spawned actors (available in top menubar). Useful for fixed-place machinery, i.e. cranes. More...
 
Ogre::String ar_design_name
 Name of the vehicle/machine/object this actor represents. More...
 
float ar_anim_previous_crank = 0.f
 For 'animator' with flag 'torque'. More...
 
float alb_ratio = 0.f
 Anti-lock brake attribute: Regulating force. More...
 
float alb_minspeed = 0.f
 Anti-lock brake attribute;. More...
 
bool alb_mode = false
 Anti-lock brake state; Enabled? {1/0}. More...
 
float alb_pulse_time = 0.f
 Anti-lock brake attribute;. More...
 
bool alb_pulse_state = false
 Anti-lock brake state;. More...
 
bool alb_nodash = false
 Anti-lock brake attribute: Hide the dashboard indicator? More...
 
bool alb_notoggle = false
 Anti-lock brake attribute: Disable in-game toggle? More...
 
float alb_timer = 0.f
 Anti-lock brake state;. More...
 
float tc_ratio = 0.f
 Traction control attribute: Regulating force. More...
 
bool tc_mode = false
 Traction control state; Enabled? {1/0}. More...
 
float tc_pulse_time = 0.f
 Traction control attribute;. More...
 
bool tc_pulse_state = 0.f
 Traction control state;. More...
 
bool tc_nodash = false
 Traction control attribute; Hide the dashboard indicator? More...
 
bool tc_notoggle = false
 Traction control attribute; Disable in-game toggle? More...
 
float tc_timer = 0.f
 Traction control state;. More...
 
float ar_anim_shift_timer = 0.f
 For 'animator' with flag 'shifter'. More...
 
bool cc_mode = false
 Cruise Control. More...
 
bool cc_can_brake = false
 Cruise Control. More...
 
float cc_target_rpm = 0.f
 Cruise Control. More...
 
float cc_target_speed = 0.f
 Cruise Control. More...
 
float cc_target_speed_lower_limit = 0.f
 Cruise Control. More...
 
std::deque< float > cc_accs
 Cruise Control. More...
 
bool sl_enabled = false
 Speed limiter;. More...
 
float sl_speed_limit = 0.f
 Speed limiter;. More...
 
ExtCameraMode ar_extern_camera_mode = ExtCameraMode::CLASSIC
 
NodeNum_t ar_extern_camera_node = NODENUM_INVALID
 
NodeNum_t ar_exhaust_pos_node = 0
 Old-format exhaust (one per vehicle) emitter node. More...
 
NodeNum_t ar_exhaust_dir_node = 0
 Old-format exhaust (one per vehicle) backwards direction node. More...
 
ActorInstanceID_t ar_instance_id = ACTORINSTANCEID_INVALID
 Static attr; session-unique ID. More...
 
unsigned int ar_vector_index = 0
 Sim attr; actor element index in std::vector<m_actors> More...
 
ActorType ar_driveable = NOT_DRIVEABLE
 Sim attr; marks vehicle type and features. More...
 
EngineSimar_engine = nullptr
 
NodeNum_t ar_cinecam_node [MAX_CAMERAS] = {NODENUM_INVALID}
 Sim attr; Cine-camera node indexes. More...
 
int ar_num_cinecams = 0
 Sim attr;. More...
 
Autopilotar_autopilot = nullptr
 
float ar_brake_force = 0.f
 Physics attr; filled at spawn. More...
 
Ogre::Vector3 ar_origin = Ogre::Vector3::ZERO
 Physics state; base position for softbody nodes. More...
 
int ar_num_cameras = 0
 
Ogre::Quaternion ar_main_camera_dir_corr = Ogre::Quaternion::IDENTITY
 Sim attr;. More...
 
NodeNum_t ar_main_camera_node_pos = 0
 Sim attr; ar_camera_node_pos[0] >= 0 ? ar_camera_node_pos[0] : 0. More...
 
NodeNum_t ar_main_camera_node_dir = 0
 Sim attr; ar_camera_node_dir[0] >= 0 ? ar_camera_node_dir[0] : 0. More...
 
NodeNum_t ar_main_camera_node_roll = 0
 Sim attr; ar_camera_node_roll[0] >= 0 ? ar_camera_node_roll[0] : 0. More...
 
NodeNum_t ar_camera_node_pos [MAX_CAMERAS] = {NODENUM_INVALID}
 Physics attr; 'camera' = frame of reference; origin node. More...
 
NodeNum_t ar_camera_node_dir [MAX_CAMERAS] = {NODENUM_INVALID}
 Physics attr; 'camera' = frame of reference; back node. More...
 
NodeNum_t ar_camera_node_roll [MAX_CAMERAS] = {NODENUM_INVALID}
 Physics attr; 'camera' = frame of reference; left node. More...
 
bool ar_camera_node_roll_inv [MAX_CAMERAS] = {false}
 Physics attr; 'camera' = frame of reference; indicates roll node is right instead of left. More...
 
float ar_posnode_spawn_height = 0.f
 
VehicleAIPtr ar_vehicle_ai
 
float ar_scale = 1.f
 Physics state; scale of the actor (nominal = 1.0) More...
 
Ogre::Real ar_brake = 0.f
 Physics state; braking intensity. More...
 
float ar_wheel_speed = 0.f
 Physics state; wheel speed in m/s. More...
 
float ar_wheel_spin = 0.f
 Physics state; wheel speed in radians/s. More...
 
float ar_avg_wheel_speed = 0.f
 Physics state; avg wheel speed in m/s. More...
 
float ar_hydro_dir_command = 0.f
 
float ar_hydro_dir_state = 0.f
 
Ogre::Real ar_hydro_dir_wheel_display = 0.f
 
float ar_hydro_aileron_command = 0.f
 
float ar_hydro_aileron_state = 0.f
 
float ar_hydro_rudder_command = 0.f
 
float ar_hydro_rudder_state = 0.f
 
float ar_hydro_elevator_command = 0.f
 
float ar_hydro_elevator_state = 0.f
 
float ar_sleep_counter = 0.f
 Sim state; idle time counter. More...
 
ground_model_tar_submesh_ground_model = nullptr
 
bool ar_parking_brake = false
 
bool ar_trailer_parking_brake = false
 
float ar_left_mirror_angle = 0.52f
 Sim state; rear view mirror angle. More...
 
float ar_right_mirror_angle = -0.52f
 Sim state; rear view mirror angle. More...
 
float ar_elevator = 0.f
 Sim state; aerial controller. More...
 
float ar_rudder = 0.f
 Sim state; aerial/marine controller. More...
 
float ar_aileron = 0.f
 Sim state; aerial controller. More...
 
int ar_aerial_flap = 0
 Sim state; state of aircraft flaps (values: 0-5) More...
 
Ogre::Vector3 ar_fusedrag = Ogre::Vector3::ZERO
 Physics state. More...
 
int ar_current_cinecam = -1
 Sim state; index of current CineCam (-1 if using 3rd-person camera) More...
 
NodeNum_t ar_custom_camera_node = NODENUM_INVALID
 Sim state; custom tracking node for 3rd-person camera. More...
 
std::string ar_filename
 Attribute; filled at spawn. More...
 
std::string ar_filehash
 Attribute; filled at spawn. More...
 
int ar_airbrake_intensity = 0
 Physics state; values 0-5. More...
 
int ar_net_source_id = 0
 Unique ID of remote player who spawned this actor. More...
 
int ar_net_stream_id = 0
 
std::map< int, int > ar_net_stream_results
 
Ogre::Timer ar_net_timer
 
unsigned long ar_net_last_update_time = 0
 
DashBoardManagerar_dashboard = nullptr
 
float ar_collision_range = DEFAULT_COLLISION_RANGE
 Physics attr. More...
 
float ar_top_speed = 0.f
 Sim state. More...
 
ground_model_tar_last_fuzzy_ground_model = nullptr
 GUI state. More...
 
CollisionBoxPtrVec m_potential_eventboxes
 
std::vector< std::pair< collision_box_t *, NodeNum_t > > m_active_eventboxes
 
bool ar_guisettings_use_engine_max_rpm = false
 
float ar_guisettings_speedo_max_kph = 0.f
 
float ar_guisettings_shifter_anim_time = 0.4f
 
ActorState ar_state = ActorState::LOCAL_SIMULATED
 
ActorPtrVec ar_linked_actors
 BEWARE: Includes indirect links, see DetermineLinkedActors(); Other actors linked using 'hooks/ties/ropes/slidenodes'; use MSG_SIM_ACTOR_LINKING_REQUESTED More...
 
Ogre::Vector3 m_rotation_request_center = Ogre::Vector3::ZERO
 
float m_rotation_request = 0.f
 Accumulator. More...
 
int m_anglesnap_request = 0
 Accumulator. More...
 
Ogre::Vector3 m_translation_request = Ogre::Vector3::ZERO
 Accumulator. More...
 
bool ar_nb_initialized = false
 
std::vector< float > ar_nb_optimum
 Temporary storage of the optimum search result. More...
 
std::vector< float > ar_nb_reference
 Temporary storage of the reference search result. More...
 
int ar_nb_skip_steps = 0
 Amount of physics steps to be skipped before measuring. More...
 
int ar_nb_measure_steps = 500
 Amount of physics steps to be measured. More...
 
float ar_nb_mass_scale = 1.f
 Global mass scale (affects all nodes the same way) More...
 
std::pair< float, float > ar_nb_beams_scale
 Scales for springiness & damping of regular beams. More...
 
std::pair< float, float > ar_nb_shocks_scale
 Scales for springiness & damping of shock beams. More...
 
std::pair< float, float > ar_nb_wheels_scale
 Scales for springiness & damping of wheel / rim beams. More...
 
std::pair< float, float > ar_nb_beams_d_interval
 Search interval for springiness & damping of regular beams. More...
 
std::pair< float, float > ar_nb_beams_k_interval
 Search interval for springiness & damping of regular beams. More...
 
std::pair< float, float > ar_nb_shocks_d_interval
 Search interval for springiness & damping of shock beams. More...
 
std::pair< float, float > ar_nb_shocks_k_interval
 Search interval for springiness & damping of shock beams. More...
 
std::pair< float, float > ar_nb_wheels_d_interval
 Search interval for springiness & damping of wheel / rim beams. More...
 
std::pair< float, float > ar_nb_wheels_k_interval
 Search interval for springiness & damping of wheel / rim beams. More...
 
bool ar_update_physics:1
 Physics state; Should this actor be updated (locally) in the next physics step? More...
 
bool ar_disable_aerodyn_turbulent_drag:1
 Physics state. More...
 
bool ar_engine_hydraulics_ready:1
 Sim state; does engine have enough RPM to power hydraulics? More...
 
bool ar_hydro_speed_coupling:1
 
bool ar_collision_relevant:1
 Physics state;. More...
 
bool ar_is_police:1
 Gfx/sfx attr. More...
 
bool ar_rescuer_flag:1
 Gameplay attr; defined in truckfile. TODO: Does anybody use this anymore? More...
 
bool ar_forward_commands:1
 Sim state. More...
 
bool ar_import_commands:1
 Sim state. More...
 
bool ar_toggle_ropes:1
 Sim state. More...
 
bool ar_toggle_ties:1
 Sim state. More...
 
bool ar_physics_paused:1
 Sim state. More...
 
- Data Fields inherited from RefCountingObject< Actor >
int m_refcount
 
std::mutex m_refcount_mtx
 

Private Member Functions

bool CalcForcesEulerPrepare (bool doUpdate)
 
void CalcAircraftForces (bool doUpdate)
 
void CalcForcesEulerCompute (bool doUpdate, int num_steps)
 
void CalcAnimators (hydrobeam_t const &hydrobeam, float &cstate, int &div)
 
void CalcBeams (bool trigger_hooks)
 
void CalcBeamsInterActor ()
 
void CalcBuoyance (bool doUpdate)
 
void CalcCommands (bool doUpdate)
 
void CalcCabCollisions ()
 
void CalcDifferentials ()
 
void CalcForceFeedback (bool doUpdate)
 
void CalcFuseDrag ()
 
void CalcHooks ()
 
void CalcHydros ()
 
void CalcMouse ()
 
void CalcNodes ()
 
void CalcEventBoxes ()
 
void CalcReplay ()
 
void CalcRopes ()
 
void CalcShocks (bool doUpdate, int num_steps)
 
void CalcShocks2 (int i, Ogre::Real difftoBeamL, Ogre::Real &k, Ogre::Real &d, Ogre::Real v)
 
void CalcShocks3 (int i, Ogre::Real difftoBeamL, Ogre::Real &k, Ogre::Real &d, Ogre::Real v)
 
void CalcTriggers (int i, Ogre::Real difftoBeamL, bool update_hooks)
 
void CalcTies ()
 
void CalcTruckEngine (bool doUpdate)
 
void CalcWheels (bool doUpdate, int num_steps)
 
void DetermineLinkedActors ()
 
void RecalculateNodeMasses (Ogre::Real total)
 Previously 'calc_masses2()'. More...
 
void calcNodeConnectivityGraph ()
 
void AddInterActorBeam (beam_t *beam, ActorPtr other, ActorLinkingRequestType type)
 Do not call directly - use MSG_SIM_ACTOR_LINKING_REQUESTED More...
 
void RemoveInterActorBeam (beam_t *beam, ActorLinkingRequestType type)
 Do not call directly - use MSG_SIM_ACTOR_LINKING_REQUESTED More...
 
void DisjoinInterActorBeams ()
 Helper for MSG_ handlers, do not invoke by hand. More...
 
void autoBlinkReset ()
 Resets the turn signal when the steering wheel is turned back. More...
 
void ResetAngle (float rot)
 
void calculateLocalGForces ()
 Derive the truck local g-forces from the global ones. More...
 
Ogre::Vector3 calculateCollisionOffset (Ogre::Vector3 direction)
 Virtually moves the actor at most 'direction.length()' meters towards 'direction' trying to resolve any collisions Returns a minimal offset by which the actor needs to be moved to resolve any collisions. More...
 
std::pair< RailGroup *, Ogre::Real > GetClosestRailOnActor (ActorPtr actor, const SlideNode &node)
 

Private Attributes

std::vector< std::shared_ptr< Task > > m_flexbody_tasks
 Gfx state. More...
 
RigDef::DocumentPtr m_definition
 
std::unique_ptr< GfxActorm_gfx_actor
 
PerVehicleCameraContext m_camera_context
 
Ogre::String m_section_config
 
std::vector< SlideNodem_slidenodes
 all the SlideNodes available on this actor More...
 
std::vector< RailGroup * > m_railgroups
 all the available RailGroups for this actor More...
 
std::vector< Ogre::Entity * > m_deletion_entities
 For unloading vehicle; filled at spawn. More...
 
std::vector< Ogre::SceneNode * > m_deletion_scene_nodes
 For unloading vehicle; filled at spawn. More...
 
int m_proped_wheel_pairs [MAX_WHEELS] = {}
 Physics attr; For inter-differential locking. More...
 
int m_num_proped_wheels = 0
 Physics attr, filled at spawn - Number of propelled wheels. More...
 
float m_avg_proped_wheel_radius = 0.f
 Physics attr, filled at spawn - Average proped wheel radius. More...
 
float m_avionic_chatter_timer = 11.f
 Sound fx state (some pseudo random number, doesn't matter) More...
 
PointColDetectorm_inter_point_col_detector = nullptr
 Physics. More...
 
PointColDetectorm_intra_point_col_detector = nullptr
 Physics. More...
 
Ogre::Vector3 m_avg_node_position = Ogre::Vector3::ZERO
 average node position More...
 
Ogre::Real m_min_camera_radius = 0.f
 
Ogre::Vector3 m_avg_node_position_prev = Ogre::Vector3::ZERO
 
Ogre::Vector3 m_avg_node_velocity = Ogre::Vector3::ZERO
 average node velocity (compared to the previous frame step) More...
 
float m_stabilizer_shock_sleep = 0.f
 Sim state. More...
 
Replaym_replay_handler = nullptr
 
float m_total_mass = 0.f
 Physics state; total mass in Kg. More...
 
NodeNum_t m_mouse_grab_node = NODENUM_INVALID
 Sim state; node currently being dragged by user. More...
 
Ogre::Vector3 m_mouse_grab_pos = Ogre::Vector3::ZERO
 
float m_mouse_grab_move_force = 0.f
 
float m_spawn_rotation = 0.f
 
Ogre::Timer m_reset_timer
 
Ogre::Vector3 m_camera_gforces_accu = Ogre::Vector3::ZERO
 Accumulator for 'camera' G-forces. More...
 
Ogre::Vector3 m_camera_gforces = Ogre::Vector3::ZERO
 Physics state (global) More...
 
Ogre::Vector3 m_camera_local_gforces_cur = Ogre::Vector3::ZERO
 Physics state (camera local) More...
 
Ogre::Vector3 m_camera_local_gforces_max = Ogre::Vector3::ZERO
 Physics state (camera local) More...
 
float m_stabilizer_shock_ratio = 0.f
 Physics state. More...
 
int m_stabilizer_shock_request = 0
 Physics state; values: { -1, 0, 1 }. More...
 
Differentialm_axle_diffs [1+MAX_WHEELS/2] = {}
 Physics. More...
 
int m_num_axle_diffs = 0
 Physics attr. More...
 
Differentialm_wheel_diffs [MAX_WHEELS/2] = {}
 Physics. More...
 
int m_num_wheel_diffs = 0
 Physics attr. More...
 
TransferCasem_transfer_case = nullptr
 Physics. More...
 
int m_wheel_node_count = 0
 Static attr; filled at spawn. More...
 
int m_previous_gear = 0
 Sim state; land vehicle shifting. More...
 
float m_handbrake_force = 0.f
 Physics attr; defined in truckfile. More...
 
Airfoilm_fusealge_airfoil = nullptr
 Physics attr; defined in truckfile. More...
 
node_tm_fusealge_front = nullptr
 Physics attr; defined in truckfile. More...
 
node_tm_fusealge_back = nullptr
 Physics attr; defined in truckfile. More...
 
float m_fusealge_width = 0.f
 Physics attr; defined in truckfile. More...
 
float m_odometer_total = 0.f
 GUI state. More...
 
float m_odometer_user = 0.f
 GUI state. More...
 
int m_num_command_beams = 0
 TODO: Remove! Spawner context only; likely unused feature. More...
 
float m_load_mass = 0.f
 Physics attr; predefined load mass in Kg. More...
 
int m_masscount = 0
 Physics attr; Number of nodes loaded with l option. More...
 
float m_dry_mass = 0.f
 Physics attr;. More...
 
std::unique_ptr< Buoyancem_buoyance
 Physics. More...
 
CacheEntryPtr m_used_actor_entry
 
CacheEntryPtr m_used_skin_entry
 Graphics. More...
 
TuneupDefPtr m_working_tuneup_def
 Each actor gets unique instance, even if loaded from .tuneup file in modcache. More...
 
Skidmarkm_skid_trails [MAX_WHEELS *2] = {}
 
bool m_antilockbrake = false
 GUI state. More...
 
bool m_tractioncontrol = false
 GUI state. More...
 
bool m_ongoing_reset = false
 Hack to prevent position/rotation creep during interactive truck reset. More...
 
bool m_has_axles_section = false
 Temporary (legacy parsing helper) until central diffs are implemented. More...
 
TyrePressure m_tyre_pressure
 
std::vector< std::string > m_description
 
std::vector< PropAnimKeyStatem_prop_anim_key_states
 
bool m_hud_features_ok:1
 Gfx state; Are HUD features matching actor's capabilities? More...
 
bool m_slidenodes_locked:1
 Physics state; Are SlideNodes locked? More...
 
bool m_net_initialized:1
 
bool m_water_contact:1
 Scripting state. More...
 
bool m_water_contact_old:1
 Scripting state. More...
 
bool m_has_command_beams:1
 Physics attr;. More...
 
bool m_custom_particles_enabled:1
 Gfx state. More...
 
bool m_preloaded_with_terrain:1
 Spawn context (TODO: remove!) More...
 
bool m_beam_break_debug_enabled:1
 Logging state. More...
 
bool m_beam_deform_debug_enabled:1
 Logging state. More...
 
bool m_trigger_debug_enabled:1
 Logging state. More...
 
bool m_disable_default_sounds:1
 Spawner context; TODO: remove. More...
 
bool m_disable_smoke:1
 Stops/starts smoke particles (i.e. exhausts, turbojets). More...
 
struct RoR::Actor::VehicleForceSensors m_force_sensors
 Data for ForceFeedback devices. More...
 
std::deque< NetUpdatem_net_updates
 Incoming stream of NetUpdates. More...
 
Light states
GfxFlaresMode m_flares_mode = GfxFlaresMode::NONE
 Snapshot of cvar 'gfx_flares_mode' on spawn. More...
 
BitMask_t m_lightmask = 0
 RoRnet::Lightmask. More...
 
bool m_blinker_autoreset = false
 When true, we're steering and blinker will turn off automatically. More...
 
bool m_blinker_left_lit = false
 Blinking state of left turn signal. More...
 
bool m_blinker_right_lit = false
 Blinking state of right turn signal. More...
 

Friends

class ActorSpawner
 
class ActorManager
 
class GfxActor
 
class OutGauge
 

Networking

size_t m_net_node_buf_size = 0
 For incoming/outgoing traffic; calculated on spawn. More...
 
size_t m_net_wheel_buf_size = 0
 For incoming/outgoing traffic; calculated on spawn. More...
 
size_t m_net_propanimkey_buf_size = 0
 For incoming/outgoing traffic; calculated on spawn. More...
 
size_t m_net_total_buffer_size = 0
 For incoming/outgoing traffic; calculated on spawn. More...
 
float m_net_node_compression = 0.f
 For incoming/outgoing traffic; calculated on spawn. More...
 
int m_net_first_wheel_node = 0
 Network attr; Determines data buffer layout; calculated on spawn. More...
 
Ogre::UTFString m_net_username
 
int m_net_color_num = 0
 
void sendStreamSetup ()
 
void sendStreamData ()
 Send outgoing data. More...
 
void pushNetwork (char *data, int size)
 Process incoming data; fills actor's data buffers and flips them. Called by the network thread.//! More...
 
void calcNetwork ()
 

Additional Inherited Members

- Static Public Member Functions inherited from RefCountingObject< Actor >
static void RegisterRefCountingObject (AS_NAMESPACE_QUALIFIER asIScriptEngine *engine, const char *name)
 

Detailed Description

Softbody object; can be anything from soda can to a space shuttle Constructed from a truck definition file, see https://docs.rigsofrods.org/vehicle-creation/fileformat-truck/ To spawn in-game, use MSG_SIM_SPAWN_ACTOR_REQUESTED, see GameContext::PushMessage(), in AngelScript use game.pushMessage(); Gameplay states are described by enum ActorState.

For additional state vars see "Gameplay state" section below.

Definition at line 49 of file Actor.h.

Constructor & Destructor Documentation

◆ Actor()

Actor::Actor ( ActorInstanceID_t  actor_id,
unsigned int  vector_index,
RigDef::DocumentPtr  def,
RoR::ActorSpawnRequest  rq 
)

Definition at line 4389 of file Actor.cpp.

◆ ~Actor()

Actor::~Actor ( )
overridevirtual

Definition at line 81 of file Actor.cpp.

Member Function Documentation

◆ AddInterActorBeam()

void Actor::AddInterActorBeam ( beam_t beam,
ActorPtr  other,
ActorLinkingRequestType  type 
)
private

Do not call directly - use MSG_SIM_ACTOR_LINKING_REQUESTED

Definition at line 3317 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ antilockbrakeToggle()

void Actor::antilockbrakeToggle ( )

Definition at line 3777 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ applyNodeBeamScales()

void Actor::applyNodeBeamScales ( )

For GUI::NodeBeamUtils.

Definition at line 1757 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ autoBlinkReset()

void Actor::autoBlinkReset ( )
private

Resets the turn signal when the steering wheel is turned back.

Definition at line 3122 of file Actor.cpp.

+ Here is the call graph for this function:

◆ beaconsToggle()

void Actor::beaconsToggle ( )

Definition at line 3795 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ CalcAircraftForces()

void Actor::CalcAircraftForces ( bool  doUpdate)
private

Definition at line 103 of file ActorForcesEuler.cpp.

◆ CalcAnimators()

void Actor::CalcAnimators ( hydrobeam_t const &  hydrobeam,
float &  cstate,
int &  div 
)
private

Definition at line 2106 of file Actor.cpp.

◆ CalcBeams()

void Actor::CalcBeams ( bool  trigger_hooks)
private

Definition at line 1140 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcBeamsInterActor()

void Actor::CalcBeamsInterActor ( )
private

Definition at line 1399 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcBuoyance()

void Actor::CalcBuoyance ( bool  doUpdate)
private

Definition at line 151 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcCabCollisions()

void Actor::CalcCabCollisions ( )
private

Definition at line 2495 of file Actor.cpp.

+ Here is the call graph for this function:

◆ CalcCommands()

void Actor::CalcCommands ( bool  doUpdate)
private

Definition at line 737 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcDifferentials()

void Actor::CalcDifferentials ( )
private

Definition at line 163 of file ActorForcesEuler.cpp.

◆ CalcEventBoxes()

void Actor::CalcEventBoxes ( )
private

Definition at line 1638 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcForceFeedback()

void Actor::CalcForceFeedback ( bool  doUpdate)
private

Definition at line 69 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcForcesEulerCompute()

void Actor::CalcForcesEulerCompute ( bool  doUpdate,
int  num_steps 
)
private

Definition at line 46 of file ActorForcesEuler.cpp.

◆ CalcForcesEulerPrepare()

bool Actor::CalcForcesEulerPrepare ( bool  doUpdate)
private

Definition at line 1099 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcFuseDrag()

void Actor::CalcFuseDrag ( )
private

Definition at line 125 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcHooks()

void Actor::CalcHooks ( )
private

Definition at line 1717 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcHydros()

void Actor::CalcHydros ( )
private

Definition at line 546 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcMouse()

void Actor::CalcMouse ( )
private

Definition at line 94 of file ActorForcesEuler.cpp.

◆ calcNetwork()

void Actor::calcNetwork ( )

Definition at line 524 of file Actor.cpp.

+ Here is the call graph for this function:

◆ calcNodeConnectivityGraph()

void Actor::calcNodeConnectivityGraph ( )
private

Definition at line 874 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ CalcNodes()

void Actor::CalcNodes ( )
private

Definition at line 1532 of file ActorForcesEuler.cpp.

+ Here is the call graph for this function:

◆ CalcReplay()

void Actor::CalcReplay ( )
private

Definition at line 1091 of file ActorForcesEuler.cpp.

◆ CalcRopes()

void Actor::CalcRopes ( )
private

Definition at line 1769 of file ActorForcesEuler.cpp.

◆ CalcShocks()

void Actor::CalcShocks ( bool  doUpdate,
int  num_steps 
)
private

Definition at line 491 of file ActorForcesEuler.cpp.

◆ CalcShocks2()

void Actor::CalcShocks2 ( int  i,
Ogre::Real  difftoBeamL,
Ogre::Real &  k,
Ogre::Real &  d,
Ogre::Real  v 
)
private

Definition at line 2516 of file Actor.cpp.

◆ CalcShocks3()

void Actor::CalcShocks3 ( int  i,
Ogre::Real  difftoBeamL,
Ogre::Real &  k,
Ogre::Real &  d,
Ogre::Real  v 
)
private

Definition at line 2627 of file Actor.cpp.

◆ CalcTies()

void Actor::CalcTies ( )
private

Definition at line 1052 of file ActorForcesEuler.cpp.

◆ CalcTriggers()

void Actor::CalcTriggers ( int  i,
Ogre::Real  difftoBeamL,
bool  update_hooks 
)
private

Definition at line 2659 of file Actor.cpp.

+ Here is the call graph for this function:

◆ CalcTruckEngine()

void Actor::CalcTruckEngine ( bool  doUpdate)
private

Definition at line 1083 of file ActorForcesEuler.cpp.

◆ calculateAveragePosition()

void Actor::calculateAveragePosition ( )

Definition at line 1133 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ calculateCollisionOffset()

Vector3 Actor::calculateCollisionOffset ( Ogre::Vector3  direction)
private

Virtually moves the actor at most 'direction.length()' meters towards 'direction' trying to resolve any collisions Returns a minimal offset by which the actor needs to be moved to resolve any collisions.

Definition at line 959 of file Actor.cpp.

+ Here is the call graph for this function:

◆ calculateLocalGForces()

void Actor::calculateLocalGForces ( )
private

Derive the truck local g-forces from the global ones.

Definition at line 4333 of file Actor.cpp.

+ Here is the call graph for this function:

◆ CalcWheels()

void Actor::CalcWheels ( bool  doUpdate,
int  num_steps 
)
private

Definition at line 262 of file ActorForcesEuler.cpp.

◆ countCustomLights()

int Actor::countCustomLights ( int  control_number)

Definition at line 4515 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ countFlaresByType()

int Actor::countFlaresByType ( FlareType  type)

Definition at line 4532 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ cruisecontrolToggle()

void Actor::cruisecontrolToggle ( )

Defined in 'gameplay/CruiseControl.cpp'.

Definition at line 31 of file CruiseControl.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ DetermineLinkedActors()

void Actor::DetermineLinkedActors ( )
private

Definition at line 828 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ DisjoinInterActorBeams()

void Actor::DisjoinInterActorBeams ( )
private

Helper for MSG_ handlers, do not invoke by hand.

Definition at line 3405 of file Actor.cpp.

+ Here is the call graph for this function:

◆ displayAxleDiffMode()

void Actor::displayAxleDiffMode ( )

Cycles through the available inter axle diff modes.

Definition at line 1366 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ displayTransferCaseMode()

void Actor::displayTransferCaseMode ( )

Gets the current transfer case mode name (4WD Hi, ...)

Definition at line 1420 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ displayWheelDiffMode()

void Actor::displayWheelDiffMode ( )

Cycles through the available inter wheel diff modes.

Definition at line 1394 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ dispose()

void Actor::dispose ( )

Effectively destroys the object but keeps it in memory to satisfy shared pointers.

Definition at line 88 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ engineTriggerHelper()

void Actor::engineTriggerHelper ( int  engineNumber,
EngineTriggerType  type,
float  triggerValue 
)

Definition at line 4355 of file Actor.cpp.

+ Here is the call graph for this function:

◆ ensureWorkingTuneupDef()

void Actor::ensureWorkingTuneupDef ( )

Creates a working tuneup def if it doesn't exist yet.

Definition at line 4724 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ forceAllFlaresOff()

void Actor::forceAllFlaresOff ( )

Definition at line 3011 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ ForceFeedbackStep()

void Actor::ForceFeedbackStep ( int  steps)

Definition at line 1787 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getAuthors()

std::vector< authorinfo_t > Actor::getAuthors ( )

Definition at line 4458 of file Actor.cpp.

◆ getAvgPropedWheelRadius()

float RoR::Actor::getAvgPropedWheelRadius ( )
inline

Definition at line 257 of file Actor.h.

+ Here is the caller graph for this function:

◆ getAxleDiffMode()

int RoR::Actor::getAxleDiffMode ( )
inline

Writes info to console/notify box.

Definition at line 154 of file Actor.h.

+ Here is the caller graph for this function:

◆ getBeaconMode()

bool RoR::Actor::getBeaconMode ( ) const
inline

Definition at line 175 of file Actor.h.

+ Here is the caller graph for this function:

◆ getBlinkType()

BlinkType Actor::getBlinkType ( )

Definition at line 4543 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getBrakeLightVisible()

bool RoR::Actor::getBrakeLightVisible ( ) const
inline

Definition at line 177 of file Actor.h.

◆ GetCameraContext()

PerVehicleCameraContext* RoR::Actor::GetCameraContext ( )
inline

Definition at line 265 of file Actor.h.

+ Here is the caller graph for this function:

◆ GetCameraDir()

Ogre::Vector3 RoR::Actor::GetCameraDir ( )
inline

Definition at line 266 of file Actor.h.

+ Here is the caller graph for this function:

◆ GetCameraRoll()

Ogre::Vector3 RoR::Actor::GetCameraRoll ( )
inline

Definition at line 267 of file Actor.h.

+ Here is the caller graph for this function:

◆ GetClosestRailOnActor()

std::pair< RailGroup *, Ogre::Real > Actor::GetClosestRailOnActor ( ActorPtr  actor,
const SlideNode node 
)
private
Parameters
actorwhich actor to retrieve the closest Rail from
nodewhich SlideNode is being checked against
Returns
a pair containing the rail, and the distant to the SlideNode

Definition at line 73 of file ActorSlideNode.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getCustomLightVisible()

bool Actor::getCustomLightVisible ( int  number)

Definition at line 4473 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getCustomParticleMode()

bool Actor::getCustomParticleMode ( )

Definition at line 4551 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getDescription()

std::vector< std::string > Actor::getDescription ( )

Definition at line 4463 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getDirection()

Vector3 Actor::getDirection ( )

average actor velocity, calculated using the actor positions of the last two frames

Definition at line 418 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ GetFFbBodyForces()

Ogre::Vector3 RoR::Actor::GetFFbBodyForces ( ) const
inline

Definition at line 268 of file Actor.h.

◆ GetFFbHydroForces()

float RoR::Actor::GetFFbHydroForces ( ) const
inline

Definition at line 272 of file Actor.h.

◆ getFogLightsVisible()

bool RoR::Actor::getFogLightsVisible ( ) const
inline

Definition at line 191 of file Actor.h.

+ Here is the caller graph for this function:

◆ getGForces()

Ogre::Vector3 RoR::Actor::getGForces ( )
inline

Definition at line 86 of file Actor.h.

+ Here is the caller graph for this function:

◆ GetGfxActor()

GfxActor* RoR::Actor::GetGfxActor ( )
inline

Definition at line 269 of file Actor.h.

+ Here is the caller graph for this function:

◆ getHeadlightsVisible()

bool RoR::Actor::getHeadlightsVisible ( ) const
inline

Definition at line 187 of file Actor.h.

+ Here is the caller graph for this function:

◆ getHeightAboveGround()

float Actor::getHeightAboveGround ( bool  skip_virtual_nodes = true)

Definition at line 1537 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getHeightAboveGroundBelow()

float Actor::getHeightAboveGroundBelow ( float  height,
bool  skip_virtual_nodes = true 
)

Definition at line 1551 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getHighBeamsVisible()

bool RoR::Actor::getHighBeamsVisible ( ) const
inline

Definition at line 189 of file Actor.h.

+ Here is the caller graph for this function:

◆ getInstanceId()

int RoR::Actor::getInstanceId ( )
inline

Definition at line 231 of file Actor.h.

+ Here is the caller graph for this function:

◆ getLightStateMask()

BitMask_t RoR::Actor::getLightStateMask ( ) const
inline

Definition at line 183 of file Actor.h.

+ Here is the caller graph for this function:

◆ getManagedMaterialInstance()

Ogre::MaterialPtr Actor::getManagedMaterialInstance ( const std::string &  orig_name)

Definition at line 4569 of file Actor.cpp.

◆ getManagedMaterialNames()

std::vector< std::string > Actor::getManagedMaterialNames ( )

Definition at line 4578 of file Actor.cpp.

◆ getMaxGForces()

Ogre::Vector3 RoR::Actor::getMaxGForces ( )
inline

Definition at line 114 of file Actor.h.

+ Here is the caller graph for this function:

◆ getMaxHeight()

float Actor::getMaxHeight ( bool  skip_virtual_nodes = true)

Definition at line 1524 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getMinCameraRadius()

float RoR::Actor::getMinCameraRadius ( )
inline

Definition at line 254 of file Actor.h.

+ Here is the caller graph for this function:

◆ getMinHeight()

float Actor::getMinHeight ( bool  skip_virtual_nodes = true)

Definition at line 1511 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getMinimalCameraRadius()

Ogre::Real Actor::getMinimalCameraRadius ( )

Definition at line 4556 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getNodeCount()

int RoR::Actor::getNodeCount ( )
inline

Definition at line 88 of file Actor.h.

◆ getNodePosition()

Vector3 Actor::getNodePosition ( int  nodeNumber)

Returns world position of node.

Definition at line 4588 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ GetNumActiveConnectedBeams()

int Actor::GetNumActiveConnectedBeams ( int  nodeid)

Returns the number of active (non bounded) beams connected to a node.

Definition at line 3859 of file Actor.cpp.

◆ getOrientation()

Ogre::Quaternion Actor::getOrientation ( )

Definition at line 428 of file Actor.cpp.

◆ getParkingBrake()

bool RoR::Actor::getParkingBrake ( )
inline

Definition at line 150 of file Actor.h.

+ Here is the caller graph for this function:

◆ getPosition()

Vector3 Actor::getPosition ( )

Definition at line 423 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getReplay()

Replay * Actor::getReplay ( )

Definition at line 4561 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ getReverseLightVisible()

bool RoR::Actor::getReverseLightVisible ( ) const
inline

Definition at line 178 of file Actor.h.

◆ getRotation()

float Actor::getRotation ( )

Definition at line 408 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getRotationCenter()

Ogre::Vector3 Actor::getRotationCenter ( )

Definition at line 1493 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getSectionConfig()

Ogre::String RoR::Actor::getSectionConfig ( )
inline

Definition at line 230 of file Actor.h.

+ Here is the caller graph for this function:

◆ getShockCount()

int RoR::Actor::getShockCount ( )
inline

Definition at line 106 of file Actor.h.

◆ getShockDamping()

float Actor::getShockDamping ( int  shock_number)

Definition at line 4747 of file Actor.cpp.

◆ getShockNode1()

int Actor::getShockNode1 ( int  shock_number)

Definition at line 4765 of file Actor.cpp.

◆ getShockNode2()

int Actor::getShockNode2 ( int  shock_number)

Definition at line 4774 of file Actor.cpp.

◆ getShockSpringRate()

float Actor::getShockSpringRate ( int  shock_number)

Definition at line 4738 of file Actor.cpp.

◆ getShockVelocity()

float Actor::getShockVelocity ( int  shock_number)

Definition at line 4756 of file Actor.cpp.

◆ getSideLightsVisible()

bool RoR::Actor::getSideLightsVisible ( ) const
inline

Definition at line 185 of file Actor.h.

+ Here is the caller graph for this function:

◆ getSmokeEnabled()

bool RoR::Actor::getSmokeEnabled ( ) const
inline

Definition at line 164 of file Actor.h.

◆ getSpeed()

float RoR::Actor::getSpeed ( )
inline

Definition at line 85 of file Actor.h.

+ Here is the caller graph for this function:

◆ getSteeringAngle()

float Actor::getSteeringAngle ( )

Definition at line 4453 of file Actor.cpp.

◆ getTotalMass()

float Actor::getTotalMass ( bool  withLocked = true)

Definition at line 810 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getTransferCaseMode()

TransferCase* RoR::Actor::getTransferCaseMode ( )
inline

Toggles between 2WD and 4WD mode.

Definition at line 159 of file Actor.h.

+ Here is the caller graph for this function:

◆ getTransferCaseName()

String Actor::getTransferCaseName ( )

Toggles between Hi and Lo mode.

Definition at line 1479 of file Actor.cpp.

◆ getTruckFileName()

std::string RoR::Actor::getTruckFileName ( )
inline

Definition at line 227 of file Actor.h.

+ Here is the caller graph for this function:

◆ getTruckFileResourceGroup()

std::string Actor::getTruckFileResourceGroup ( )

Definition at line 4704 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getTruckName()

std::string RoR::Actor::getTruckName ( )
inline

Definition at line 226 of file Actor.h.

+ Here is the caller graph for this function:

◆ getTruckState()

ActorState RoR::Actor::getTruckState ( )
inline

Definition at line 79 of file Actor.h.

◆ getTruckType()

int RoR::Actor::getTruckType ( )
inline

Definition at line 229 of file Actor.h.

+ Here is the caller graph for this function:

◆ getTyrePressure()

TyrePressure& RoR::Actor::getTyrePressure ( )
inline

Definition at line 220 of file Actor.h.

+ Here is the caller graph for this function:

◆ getUsedActorEntry()

CacheEntryPtr & Actor::getUsedActorEntry ( )

The actor entry itself.

Definition at line 4709 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getUsedSkinEntry()

CacheEntryPtr & Actor::getUsedSkinEntry ( )

Definition at line 4714 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getVehicleAI()

VehicleAIPtr RoR::Actor::getVehicleAI ( )
inline

Definition at line 215 of file Actor.h.

◆ getVelocity()

Ogre::Vector3 RoR::Actor::getVelocity ( ) const
inline

Definition at line 107 of file Actor.h.

◆ getWheelDiffMode()

int RoR::Actor::getWheelDiffMode ( )
inline

Writes info to console/notify box.

Definition at line 157 of file Actor.h.

+ Here is the caller graph for this function:

◆ getWheelNodeCount()

int Actor::getWheelNodeCount ( ) const

Definition at line 869 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ getWheelSpeed()

float RoR::Actor::getWheelSpeed ( ) const
inline

Definition at line 93 of file Actor.h.

+ Here is the caller graph for this function:

◆ getWorkingTuneupDef()

TuneupDefPtr & Actor::getWorkingTuneupDef ( )

Definition at line 4719 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ HandleAngelScriptEvents()

void Actor::HandleAngelScriptEvents ( float  dt)

Definition at line 1796 of file Actor.cpp.

+ Here is the call graph for this function:

◆ HandleInputEvents()

void Actor::HandleInputEvents ( float  dt)

Definition at line 1899 of file Actor.cpp.

◆ hasSlidenodes()

bool RoR::Actor::hasSlidenodes ( )
inline

Definition at line 115 of file Actor.h.

+ Here is the caller graph for this function:

◆ hookToggle()

void Actor::hookToggle ( int  group = -1,
ActorLinkingRequestType  mode = ActorLinkingRequestType::HOOK_TOGGLE,
NodeNum_t  mousenode = NODENUM_INVALID,
ActorInstanceID_t  forceunlock_filter = ACTORINSTANCEID_INVALID 
)

Definition at line 3624 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ Intersects()

bool Actor::Intersects ( ActorPtr  actor,
Ogre::Vector3  offset = Ogre::Vector3::ZERO 
)

Slow intersection test.

Definition at line 893 of file Actor.cpp.

◆ isBeingReset()

bool RoR::Actor::isBeingReset ( ) const
inline

Definition at line 273 of file Actor.h.

+ Here is the caller graph for this function:

◆ isLocked()

bool Actor::isLocked ( )

Are hooks locked?

Definition at line 3878 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ isNodeWheelRim()

bool Actor::isNodeWheelRim ( int  nodeNumber)

Is node marked as wheel rim? Note some wheel models use only tire nodes. See https://docs.rigsofrods.org/vehicle-creation/fileformat-truck/#wheels.

Definition at line 4600 of file Actor.cpp.

◆ isNodeWheelTire()

bool Actor::isNodeWheelTire ( int  nodeNumber)

Is node marked as wheel tire? Note some wheel models use only tire nodes. See https://docs.rigsofrods.org/vehicle-creation/fileformat-truck/#wheels.

Definition at line 4612 of file Actor.cpp.

◆ isPreloadedWithTerrain()

bool RoR::Actor::isPreloadedWithTerrain ( ) const
inline

Definition at line 238 of file Actor.h.

+ Here is the caller graph for this function:

◆ isTied()

bool Actor::isTied ( )

Definition at line 3870 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ mouseMove()

void Actor::mouseMove ( NodeNum_t  node,
Ogre::Vector3  pos,
float  force 
)

Definition at line 1343 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ muteAllSounds()

void Actor::muteAllSounds ( )

Definition at line 3811 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ NotifyActorCameraChanged()

void Actor::NotifyActorCameraChanged ( )

Logic: sound, display; Notify this vehicle that camera changed;.

Definition at line 3839 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ parkingbrakeToggle()

void Actor::parkingbrakeToggle ( )

Definition at line 3762 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ prepareInside()

void Actor::prepareInside ( bool  inside)

Prepares vehicle for in-cabin camera use.

Definition at line 2950 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ pushNetwork()

void Actor::pushNetwork ( char *  data,
int  size 
)

Process incoming data; fills actor's data buffers and flips them. Called by the network thread.//!

Definition at line 436 of file Actor.cpp.

+ Here is the call graph for this function:

◆ RecalculateNodeMasses()

void Actor::RecalculateNodeMasses ( Ogre::Real  total)
private

Previously 'calc_masses2()'.

Definition at line 718 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ RemoveInterActorBeam()

void Actor::RemoveInterActorBeam ( beam_t beam,
ActorLinkingRequestType  type 
)
private

Do not call directly - use MSG_SIM_ACTOR_LINKING_REQUESTED

Definition at line 3358 of file Actor.cpp.

+ Here is the call graph for this function:

◆ removeWorkingTuneupDef()

void Actor::removeWorkingTuneupDef ( )

Deletes the working tuneup def object if it exists.

Definition at line 4733 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ requestAngleSnap()

void RoR::Actor::requestAngleSnap ( int  division)
inline

Definition at line 104 of file Actor.h.

+ Here is the caller graph for this function:

◆ requestRotation()

void RoR::Actor::requestRotation ( float  rotation,
Ogre::Vector3  center 
)
inline

Definition at line 103 of file Actor.h.

+ Here is the caller graph for this function:

◆ requestTranslation()

void RoR::Actor::requestTranslation ( Ogre::Vector3  translation)
inline

Definition at line 105 of file Actor.h.

+ Here is the caller graph for this function:

◆ RequestUpdateHudFeatures()

void RoR::Actor::RequestUpdateHudFeatures ( )
inline

Definition at line 270 of file Actor.h.

+ Here is the caller graph for this function:

◆ reset()

void Actor::reset ( bool  keep_position = false)

call this one to reset a truck from any context

Definition at line 1565 of file Actor.cpp.

+ Here is the call graph for this function:

◆ ResetAngle()

void Actor::ResetAngle ( float  rot)
private

Definition at line 1230 of file Actor.cpp.

◆ resetPosition() [1/2]

void Actor::resetPosition ( float  px,
float  pz,
bool  setInitPosition,
float  miny 
)

Moves the actor to given world coords.

Definition at line 1260 of file Actor.cpp.

+ Here is the call graph for this function:

◆ resetPosition() [2/2]

void Actor::resetPosition ( Ogre::Vector3  translation,
bool  setInitPosition 
)

Moves the actor to given world coords.

Definition at line 1318 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ resetSlideNodePositions()

void Actor::resetSlideNodePositions ( )

Recalculate SlideNode positions.

Definition at line 112 of file ActorSlideNode.cpp.

◆ resetSlideNodes()

void Actor::resetSlideNodes ( )

Reset all the SlideNodes.

Definition at line 122 of file ActorSlideNode.cpp.

+ Here is the caller graph for this function:

◆ resolveCollisions() [1/2]

void Actor::resolveCollisions ( float  max_distance,
bool  consider_up 
)

Auto detects an ideal collision avoidance direction (front, back, left, right, up) Then moves the actor at most 'max_distance' meters towards that direction to resolve any collisions.

Definition at line 1094 of file Actor.cpp.

◆ resolveCollisions() [2/2]

void Actor::resolveCollisions ( Ogre::Vector3  direction)

Moves the actor at most 'direction.length()' meters towards 'direction' to resolve any collisions.

Definition at line 1075 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ ropeToggle()

void Actor::ropeToggle ( int  group = -1,
ActorLinkingRequestType  mode = ActorLinkingRequestType::ROPE_TOGGLE,
ActorInstanceID_t  forceunlock_filter = ACTORINSTANCEID_INVALID 
)

Definition at line 3547 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ scaleTruck()

void Actor::scaleTruck ( float  value)

Definition at line 368 of file Actor.cpp.

◆ searchBeamDefaults()

void Actor::searchBeamDefaults ( )

Searches for more stable beam defaults.

Definition at line 1808 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ sendStreamData()

void Actor::sendStreamData ( )

Send outgoing data.

Definition at line 1968 of file Actor.cpp.

+ Here is the call graph for this function:

◆ sendStreamSetup()

void Actor::sendStreamSetup ( )

Definition at line 1946 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setAirbrakeIntensity()

void Actor::setAirbrakeIntensity ( float  intensity)

Definition at line 2916 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ setBeaconMode()

void RoR::Actor::setBeaconMode ( bool  val)
inline

Definition at line 193 of file Actor.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setBlinkType()

void Actor::setBlinkType ( BlinkType  blink)

Definition at line 3088 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ setCustomLightVisible()

void Actor::setCustomLightVisible ( int  number,
bool  visible 
)

Definition at line 4495 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setFogLightsVisible()

void RoR::Actor::setFogLightsVisible ( bool  val)
inline

Definition at line 192 of file Actor.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setHeadlightsVisible()

void RoR::Actor::setHeadlightsVisible ( bool  val)
inline

Definition at line 188 of file Actor.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setHighBeamsVisible()

void RoR::Actor::setHighBeamsVisible ( bool  val)
inline

Definition at line 190 of file Actor.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setLightStateMask()

void Actor::setLightStateMask ( BitMask_t  lightmask)

Does all the necessary toggling.

Definition at line 3151 of file Actor.cpp.

◆ setMass()

void Actor::setMass ( float  m)

Definition at line 4468 of file Actor.cpp.

◆ setSideLightsVisible()

void RoR::Actor::setSideLightsVisible ( bool  val)
inline

Definition at line 186 of file Actor.h.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setSmokeEnabled()

void RoR::Actor::setSmokeEnabled ( bool  enabled)
inline

Writes info to console/notify area.

Definition at line 163 of file Actor.h.

+ Here is the caller graph for this function:

◆ SoftReset()

void Actor::SoftReset ( )

Definition at line 1576 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ SyncReset()

void Actor::SyncReset ( bool  reset_position)

this one should be called only synchronously (without physics running in background)

Definition at line 1600 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ tieToggle()

void Actor::tieToggle ( int  group = -1,
ActorLinkingRequestType  mode = ActorLinkingRequestType::TIE_TOGGLE,
ActorInstanceID_t  forceunlock_filter = ACTORINSTANCEID_INVALID 
)

Definition at line 3430 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ toggleAxleDiffMode()

void Actor::toggleAxleDiffMode ( )

Definition at line 1358 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ toggleBlinkType()

void Actor::toggleBlinkType ( BlinkType  blink)

Definition at line 3080 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ toggleCustomParticles()

void Actor::toggleCustomParticles ( )

Definition at line 3174 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ toggleHeadlights()

void Actor::toggleHeadlights ( )

Definition at line 2989 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ toggleSlideNodeLock()

void Actor::toggleSlideNodeLock ( )

Definition at line 34 of file ActorSlideNode.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ toggleTransferCaseGearRatio()

void Actor::toggleTransferCaseGearRatio ( )

Definition at line 1465 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ toggleTransferCaseMode()

void Actor::toggleTransferCaseMode ( )

Definition at line 1434 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ toggleWheelDiffMode()

void Actor::toggleWheelDiffMode ( )

Definition at line 1350 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ tractioncontrolToggle()

void Actor::tractioncontrolToggle ( )

Definition at line 3786 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ unmuteAllSounds()

void Actor::unmuteAllSounds ( )

Definition at line 3825 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ UpdateBoundingBoxes()

void Actor::UpdateBoundingBoxes ( )

Definition at line 1168 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ UpdateCruiseControl()

void Actor::UpdateCruiseControl ( float  dt)

Defined in 'gameplay/CruiseControl.cpp'.

Definition at line 48 of file CruiseControl.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ updateDashBoards()

void Actor::updateDashBoards ( float  dt)

Definition at line 3886 of file Actor.cpp.

+ Here is the call graph for this function:

◆ updateFlareStates()

void Actor::updateFlareStates ( float  dt)

Definition at line 3019 of file Actor.cpp.

◆ updateInitPosition()

void Actor::updateInitPosition ( )

Definition at line 1252 of file Actor.cpp.

+ Here is the caller graph for this function:

◆ UpdatePhysicsOrigin()

void Actor::UpdatePhysicsOrigin ( )

Definition at line 1217 of file Actor.cpp.

◆ UpdatePropAnimInputEvents()

void Actor::UpdatePropAnimInputEvents ( )

Definition at line 4682 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ updateSkidmarks()

void Actor::updateSkidmarks ( )

Creates or updates skidmarks.

Definition at line 2926 of file Actor.cpp.

◆ updateSlideNodeForces()

void Actor::updateSlideNodeForces ( const Ogre::Real  delta_time_sec)

calculate and apply Corrective forces

Definition at line 103 of file ActorSlideNode.cpp.

◆ updateSlideNodePositions()

void Actor::updateSlideNodePositions ( )

incrementally update the position of all SlideNodes

Definition at line 130 of file ActorSlideNode.cpp.

◆ updateSoundSources()

void Actor::updateSoundSources ( )

Definition at line 3193 of file Actor.cpp.

+ Here is the call graph for this function:

◆ updateVisual()

void Actor::updateVisual ( float  dt = 0)

Definition at line 3210 of file Actor.cpp.

+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ WriteDiagnosticDump()

void Actor::WriteDiagnosticDump ( std::string const &  filename)

Definition at line 4624 of file Actor.cpp.

+ Here is the caller graph for this function:

Friends And Related Function Documentation

◆ ActorManager

friend class ActorManager
friend

Definition at line 52 of file Actor.h.

◆ ActorSpawner

friend class ActorSpawner
friend

Definition at line 51 of file Actor.h.

◆ GfxActor

friend class GfxActor
friend

Definition at line 53 of file Actor.h.

◆ OutGauge

friend class OutGauge
friend

Definition at line 54 of file Actor.h.

Field Documentation

◆ alb_minspeed

float RoR::Actor::alb_minspeed = 0.f

Anti-lock brake attribute;.

Definition at line 349 of file Actor.h.

◆ alb_mode

bool RoR::Actor::alb_mode = false

Anti-lock brake state; Enabled? {1/0}.

Definition at line 350 of file Actor.h.

◆ alb_nodash

bool RoR::Actor::alb_nodash = false

Anti-lock brake attribute: Hide the dashboard indicator?

Definition at line 353 of file Actor.h.

◆ alb_notoggle

bool RoR::Actor::alb_notoggle = false

Anti-lock brake attribute: Disable in-game toggle?

Definition at line 354 of file Actor.h.

◆ alb_pulse_state

bool RoR::Actor::alb_pulse_state = false

Anti-lock brake state;.

Definition at line 352 of file Actor.h.

◆ alb_pulse_time

float RoR::Actor::alb_pulse_time = 0.f

Anti-lock brake attribute;.

Definition at line 351 of file Actor.h.

◆ alb_ratio

float RoR::Actor::alb_ratio = 0.f

Anti-lock brake attribute: Regulating force.

Definition at line 348 of file Actor.h.

◆ alb_timer

float RoR::Actor::alb_timer = 0.f

Anti-lock brake state;.

Definition at line 355 of file Actor.h.

◆ ar_aerial_flap

int RoR::Actor::ar_aerial_flap = 0

Sim state; state of aircraft flaps (values: 0-5)

Definition at line 421 of file Actor.h.

◆ ar_aeroengines

AeroEngine* RoR::Actor::ar_aeroengines[MAX_AEROENGINES] = {}

Definition at line 329 of file Actor.h.

◆ ar_aileron

float RoR::Actor::ar_aileron = 0.f

Sim state; aerial controller.

Definition at line 420 of file Actor.h.

◆ ar_airbrake_intensity

int RoR::Actor::ar_airbrake_intensity = 0

Physics state; values 0-5.

Definition at line 427 of file Actor.h.

◆ ar_airbrakes

std::vector<Airbrake*> RoR::Actor::ar_airbrakes

Definition at line 304 of file Actor.h.

◆ ar_anim_previous_crank

float RoR::Actor::ar_anim_previous_crank = 0.f

For 'animator' with flag 'torque'.

Definition at line 347 of file Actor.h.

◆ ar_anim_shift_timer

float RoR::Actor::ar_anim_shift_timer = 0.f

For 'animator' with flag 'shifter'.

Definition at line 363 of file Actor.h.

◆ ar_autopilot

Autopilot* RoR::Actor::ar_autopilot = nullptr

Definition at line 382 of file Actor.h.

◆ ar_avg_wheel_speed

float RoR::Actor::ar_avg_wheel_speed = 0.f

Physics state; avg wheel speed in m/s.

Definition at line 402 of file Actor.h.

◆ ar_beams

beam_t* RoR::Actor::ar_beams = nullptr

Definition at line 287 of file Actor.h.

◆ ar_bounding_box

Ogre::AxisAlignedBox RoR::Actor::ar_bounding_box

standard bounding box (surrounds all nodes of an actor)

Definition at line 306 of file Actor.h.

◆ ar_brake

Ogre::Real RoR::Actor::ar_brake = 0.f

Physics state; braking intensity.

Definition at line 399 of file Actor.h.

◆ ar_brake_force

float RoR::Actor::ar_brake_force = 0.f

Physics attr; filled at spawn.

Definition at line 383 of file Actor.h.

◆ ar_buoycab_types

int RoR::Actor::ar_buoycab_types[MAX_CABS] = {}

Definition at line 341 of file Actor.h.

◆ ar_buoycabs

int RoR::Actor::ar_buoycabs[MAX_CABS] = {}

Definition at line 340 of file Actor.h.

◆ ar_cabs

int RoR::Actor::ar_cabs[MAX_CABS *3] = {}

Definition at line 333 of file Actor.h.

◆ ar_camera_node_dir

NodeNum_t RoR::Actor::ar_camera_node_dir[MAX_CAMERAS] = {NODENUM_INVALID}

Physics attr; 'camera' = frame of reference; back node.

Definition at line 392 of file Actor.h.

◆ ar_camera_node_pos

NodeNum_t RoR::Actor::ar_camera_node_pos[MAX_CAMERAS] = {NODENUM_INVALID}

Physics attr; 'camera' = frame of reference; origin node.

Definition at line 391 of file Actor.h.

◆ ar_camera_node_roll

NodeNum_t RoR::Actor::ar_camera_node_roll[MAX_CAMERAS] = {NODENUM_INVALID}

Physics attr; 'camera' = frame of reference; left node.

Definition at line 393 of file Actor.h.

◆ ar_camera_node_roll_inv

bool RoR::Actor::ar_camera_node_roll_inv[MAX_CAMERAS] = {false}

Physics attr; 'camera' = frame of reference; indicates roll node is right instead of left.

Definition at line 394 of file Actor.h.

◆ ar_camera_rail

NodeNum_t RoR::Actor::ar_camera_rail[MAX_CAMERARAIL] = {}

Nodes defining camera-movement spline.

Definition at line 343 of file Actor.h.

◆ ar_cinecam_node

NodeNum_t RoR::Actor::ar_cinecam_node[MAX_CAMERAS] = {NODENUM_INVALID}

Sim attr; Cine-camera node indexes.

Definition at line 380 of file Actor.h.

◆ ar_collcabs

int RoR::Actor::ar_collcabs[MAX_CABS] = {}

Definition at line 336 of file Actor.h.

◆ ar_collision_bounding_boxes

std::vector<Ogre::AxisAlignedBox> RoR::Actor::ar_collision_bounding_boxes

smart bounding boxes, used for determining the state of an actor (every box surrounds only a subset of nodes)

Definition at line 316 of file Actor.h.

◆ ar_collision_range

float RoR::Actor::ar_collision_range = DEFAULT_COLLISION_RANGE

Physics attr.

Definition at line 434 of file Actor.h.

◆ ar_collision_relevant

bool RoR::Actor::ar_collision_relevant

Physics state;.

Definition at line 477 of file Actor.h.

◆ ar_command_key

CmdKeyArray RoR::Actor::ar_command_key

BEWARE: commandkeys are indexed 1-MAX_COMMANDS!

Definition at line 305 of file Actor.h.

◆ ar_current_cinecam

int RoR::Actor::ar_current_cinecam = -1

Sim state; index of current CineCam (-1 if using 3rd-person camera)

Definition at line 423 of file Actor.h.

◆ ar_custom_camera_node

NodeNum_t RoR::Actor::ar_custom_camera_node = NODENUM_INVALID

Sim state; custom tracking node for 3rd-person camera.

Definition at line 424 of file Actor.h.

◆ ar_custom_particles

cparticle_t RoR::Actor::ar_custom_particles[MAX_CPARTICLES] = {}

Definition at line 325 of file Actor.h.

◆ ar_dashboard

DashBoardManager* RoR::Actor::ar_dashboard = nullptr

Definition at line 433 of file Actor.h.

◆ ar_design_name

Ogre::String RoR::Actor::ar_design_name

Name of the vehicle/machine/object this actor represents.

Definition at line 346 of file Actor.h.

◆ ar_disable_aerodyn_turbulent_drag

bool RoR::Actor::ar_disable_aerodyn_turbulent_drag

Physics state.

Definition at line 474 of file Actor.h.

◆ ar_driveable

ActorType RoR::Actor::ar_driveable = NOT_DRIVEABLE

Sim attr; marks vehicle type and features.

Definition at line 378 of file Actor.h.

◆ ar_elevator

float RoR::Actor::ar_elevator = 0.f

Sim state; aerial controller.

Definition at line 418 of file Actor.h.

◆ ar_engine

EngineSim* RoR::Actor::ar_engine = nullptr

Definition at line 379 of file Actor.h.

◆ ar_engine_hydraulics_ready

bool RoR::Actor::ar_engine_hydraulics_ready

Sim state; does engine have enough RPM to power hydraulics?

Definition at line 475 of file Actor.h.

◆ ar_evboxes_bounding_box

Ogre::AxisAlignedBox RoR::Actor::ar_evboxes_bounding_box

bounding box around nodes eligible for eventbox triggering

Definition at line 307 of file Actor.h.

◆ ar_exhaust_dir_node

NodeNum_t RoR::Actor::ar_exhaust_dir_node = 0

Old-format exhaust (one per vehicle) backwards direction node.

Definition at line 375 of file Actor.h.

◆ ar_exhaust_pos_node

NodeNum_t RoR::Actor::ar_exhaust_pos_node = 0

Old-format exhaust (one per vehicle) emitter node.

Definition at line 374 of file Actor.h.

◆ ar_extern_camera_mode

ExtCameraMode RoR::Actor::ar_extern_camera_mode = ExtCameraMode::CLASSIC

Definition at line 372 of file Actor.h.

◆ ar_extern_camera_node

NodeNum_t RoR::Actor::ar_extern_camera_node = NODENUM_INVALID

Definition at line 373 of file Actor.h.

◆ ar_filehash

std::string RoR::Actor::ar_filehash

Attribute; filled at spawn.

Definition at line 426 of file Actor.h.

◆ ar_filename

std::string RoR::Actor::ar_filename

Attribute; filled at spawn.

Definition at line 425 of file Actor.h.

◆ ar_flares

std::vector<flare_t> RoR::Actor::ar_flares

Definition at line 303 of file Actor.h.

◆ ar_forward_commands

bool RoR::Actor::ar_forward_commands

Sim state.

Definition at line 480 of file Actor.h.

◆ ar_fusedrag

Ogre::Vector3 RoR::Actor::ar_fusedrag = Ogre::Vector3::ZERO

Physics state.

Definition at line 422 of file Actor.h.

◆ ar_guisettings_shifter_anim_time

float RoR::Actor::ar_guisettings_shifter_anim_time = 0.4f

Definition at line 443 of file Actor.h.

◆ ar_guisettings_speedo_max_kph

float RoR::Actor::ar_guisettings_speedo_max_kph = 0.f

Definition at line 442 of file Actor.h.

◆ ar_guisettings_use_engine_max_rpm

bool RoR::Actor::ar_guisettings_use_engine_max_rpm = false

Definition at line 441 of file Actor.h.

◆ ar_has_active_shocks

bool RoR::Actor::ar_has_active_shocks = false

Are there active stabilizer shocks?

Definition at line 292 of file Actor.h.

◆ ar_hide_in_actor_list

bool RoR::Actor::ar_hide_in_actor_list = false

Hide in list of spawned actors (available in top menubar). Useful for fixed-place machinery, i.e. cranes.

Definition at line 345 of file Actor.h.

◆ ar_hooks

std::vector<hook_t> RoR::Actor::ar_hooks

Definition at line 302 of file Actor.h.

◆ ar_hydro_aileron_command

float RoR::Actor::ar_hydro_aileron_command = 0.f

Definition at line 406 of file Actor.h.

◆ ar_hydro_aileron_state

float RoR::Actor::ar_hydro_aileron_state = 0.f

Definition at line 407 of file Actor.h.

◆ ar_hydro_dir_command

float RoR::Actor::ar_hydro_dir_command = 0.f

Definition at line 403 of file Actor.h.

◆ ar_hydro_dir_state

float RoR::Actor::ar_hydro_dir_state = 0.f

Definition at line 404 of file Actor.h.

◆ ar_hydro_dir_wheel_display

Ogre::Real RoR::Actor::ar_hydro_dir_wheel_display = 0.f

Definition at line 405 of file Actor.h.

◆ ar_hydro_elevator_command

float RoR::Actor::ar_hydro_elevator_command = 0.f

Definition at line 410 of file Actor.h.

◆ ar_hydro_elevator_state

float RoR::Actor::ar_hydro_elevator_state = 0.f

Definition at line 411 of file Actor.h.

◆ ar_hydro_rudder_command

float RoR::Actor::ar_hydro_rudder_command = 0.f

Definition at line 408 of file Actor.h.

◆ ar_hydro_rudder_state

float RoR::Actor::ar_hydro_rudder_state = 0.f

Definition at line 409 of file Actor.h.

◆ ar_hydro_speed_coupling

bool RoR::Actor::ar_hydro_speed_coupling

Definition at line 476 of file Actor.h.

◆ ar_hydros

std::vector<hydrobeam_t> RoR::Actor::ar_hydros

Definition at line 335 of file Actor.h.

◆ ar_import_commands

bool RoR::Actor::ar_import_commands

Sim state.

Definition at line 481 of file Actor.h.

◆ ar_initial_beam_defaults

std::vector<std::pair<float, float> > RoR::Actor::ar_initial_beam_defaults

Definition at line 312 of file Actor.h.

◆ ar_initial_node_masses

std::vector<float> RoR::Actor::ar_initial_node_masses

Definition at line 310 of file Actor.h.

◆ ar_initial_node_positions

std::vector<Ogre::Vector3> RoR::Actor::ar_initial_node_positions

Definition at line 311 of file Actor.h.

◆ ar_initial_total_mass

float RoR::Actor::ar_initial_total_mass = 0.f

Definition at line 309 of file Actor.h.

◆ ar_instance_id

ActorInstanceID_t RoR::Actor::ar_instance_id = ACTORINSTANCEID_INVALID

Static attr; session-unique ID.

Definition at line 376 of file Actor.h.

◆ ar_inter_beams

std::vector<beam_t*> RoR::Actor::ar_inter_beams

Beams connecting 2 actors.

Definition at line 289 of file Actor.h.

◆ ar_inter_collcabrate

collcab_rate_t RoR::Actor::ar_inter_collcabrate[MAX_CABS] = {}

Definition at line 337 of file Actor.h.

◆ ar_intra_collcabrate

collcab_rate_t RoR::Actor::ar_intra_collcabrate[MAX_CABS] = {}

Definition at line 338 of file Actor.h.

◆ ar_is_police

bool RoR::Actor::ar_is_police

Gfx/sfx attr.

Definition at line 478 of file Actor.h.

◆ ar_last_fuzzy_ground_model

ground_model_t* RoR::Actor::ar_last_fuzzy_ground_model = nullptr

GUI state.

Definition at line 436 of file Actor.h.

◆ ar_left_mirror_angle

float RoR::Actor::ar_left_mirror_angle = 0.52f

Sim state; rear view mirror angle.

Definition at line 416 of file Actor.h.

◆ ar_linked_actors

ActorPtrVec RoR::Actor::ar_linked_actors

BEWARE: Includes indirect links, see DetermineLinkedActors(); Other actors linked using 'hooks/ties/ropes/slidenodes'; use MSG_SIM_ACTOR_LINKING_REQUESTED

Definition at line 447 of file Actor.h.

◆ ar_main_camera_dir_corr

Ogre::Quaternion RoR::Actor::ar_main_camera_dir_corr = Ogre::Quaternion::IDENTITY

Sim attr;.

Definition at line 387 of file Actor.h.

◆ ar_main_camera_node_dir

NodeNum_t RoR::Actor::ar_main_camera_node_dir = 0

Sim attr; ar_camera_node_dir[0] >= 0 ? ar_camera_node_dir[0] : 0.

Definition at line 389 of file Actor.h.

◆ ar_main_camera_node_pos

NodeNum_t RoR::Actor::ar_main_camera_node_pos = 0

Sim attr; ar_camera_node_pos[0] >= 0 ? ar_camera_node_pos[0] : 0.

Definition at line 388 of file Actor.h.

◆ ar_main_camera_node_roll

NodeNum_t RoR::Actor::ar_main_camera_node_roll = 0

Sim attr; ar_camera_node_roll[0] >= 0 ? ar_camera_node_roll[0] : 0.

Definition at line 390 of file Actor.h.

◆ ar_managed_materials

std::map<std::string, Ogre::MaterialPtr> RoR::Actor::ar_managed_materials

Definition at line 318 of file Actor.h.

◆ ar_minimass

std::vector<float> RoR::Actor::ar_minimass

minimum node mass in Kg

Definition at line 284 of file Actor.h.

◆ ar_minimass_skip_loaded_nodes

bool RoR::Actor::ar_minimass_skip_loaded_nodes = false

Definition at line 285 of file Actor.h.

◆ ar_nb_beams_d_interval

std::pair<float, float> RoR::Actor::ar_nb_beams_d_interval

Search interval for springiness & damping of regular beams.

Definition at line 465 of file Actor.h.

◆ ar_nb_beams_k_interval

std::pair<float, float> RoR::Actor::ar_nb_beams_k_interval

Search interval for springiness & damping of regular beams.

Definition at line 466 of file Actor.h.

◆ ar_nb_beams_scale

std::pair<float, float> RoR::Actor::ar_nb_beams_scale

Scales for springiness & damping of regular beams.

Definition at line 462 of file Actor.h.

◆ ar_nb_initialized

bool RoR::Actor::ar_nb_initialized = false

Definition at line 456 of file Actor.h.

◆ ar_nb_mass_scale

float RoR::Actor::ar_nb_mass_scale = 1.f

Global mass scale (affects all nodes the same way)

Definition at line 461 of file Actor.h.

◆ ar_nb_measure_steps

int RoR::Actor::ar_nb_measure_steps = 500

Amount of physics steps to be measured.

Definition at line 460 of file Actor.h.

◆ ar_nb_optimum

std::vector<float> RoR::Actor::ar_nb_optimum

Temporary storage of the optimum search result.

Definition at line 457 of file Actor.h.

◆ ar_nb_reference

std::vector<float> RoR::Actor::ar_nb_reference

Temporary storage of the reference search result.

Definition at line 458 of file Actor.h.

◆ ar_nb_shocks_d_interval

std::pair<float, float> RoR::Actor::ar_nb_shocks_d_interval

Search interval for springiness & damping of shock beams.

Definition at line 467 of file Actor.h.

◆ ar_nb_shocks_k_interval

std::pair<float, float> RoR::Actor::ar_nb_shocks_k_interval

Search interval for springiness & damping of shock beams.

Definition at line 468 of file Actor.h.

◆ ar_nb_shocks_scale

std::pair<float, float> RoR::Actor::ar_nb_shocks_scale

Scales for springiness & damping of shock beams.

Definition at line 463 of file Actor.h.

◆ ar_nb_skip_steps

int RoR::Actor::ar_nb_skip_steps = 0

Amount of physics steps to be skipped before measuring.

Definition at line 459 of file Actor.h.

◆ ar_nb_wheels_d_interval

std::pair<float, float> RoR::Actor::ar_nb_wheels_d_interval

Search interval for springiness & damping of wheel / rim beams.

Definition at line 469 of file Actor.h.

◆ ar_nb_wheels_k_interval

std::pair<float, float> RoR::Actor::ar_nb_wheels_k_interval

Search interval for springiness & damping of wheel / rim beams.

Definition at line 470 of file Actor.h.

◆ ar_nb_wheels_scale

std::pair<float, float> RoR::Actor::ar_nb_wheels_scale

Scales for springiness & damping of wheel / rim beams.

Definition at line 464 of file Actor.h.

◆ ar_net_last_update_time

unsigned long RoR::Actor::ar_net_last_update_time = 0

Definition at line 432 of file Actor.h.

◆ ar_net_source_id

int RoR::Actor::ar_net_source_id = 0

Unique ID of remote player who spawned this actor.

Definition at line 428 of file Actor.h.

◆ ar_net_stream_id

int RoR::Actor::ar_net_stream_id = 0

Definition at line 429 of file Actor.h.

◆ ar_net_stream_results

std::map<int,int> RoR::Actor::ar_net_stream_results

Definition at line 430 of file Actor.h.

◆ ar_net_timer

Ogre::Timer RoR::Actor::ar_net_timer

Definition at line 431 of file Actor.h.

◆ ar_node_to_beam_connections

std::vector<std::vector<int> > RoR::Actor::ar_node_to_beam_connections

Definition at line 315 of file Actor.h.

◆ ar_node_to_node_connections

std::vector<std::vector<int> > RoR::Actor::ar_node_to_node_connections

Definition at line 314 of file Actor.h.

◆ ar_nodes

node_t* RoR::Actor::ar_nodes = nullptr

Definition at line 279 of file Actor.h.

◆ ar_nodes_id

int* RoR::Actor::ar_nodes_id = nullptr

Number in truck file, -1 for nodes generated by wheels/cinecam.

Definition at line 280 of file Actor.h.

◆ ar_nodes_name

std::string* RoR::Actor::ar_nodes_name = nullptr

Name in truck file, only if defined with 'nodes2'.

Definition at line 281 of file Actor.h.

◆ ar_nodes_name_top_length

int RoR::Actor::ar_nodes_name_top_length = 0

For nicely formatted diagnostic output.

Definition at line 282 of file Actor.h.

◆ ar_num_aeroengines

int RoR::Actor::ar_num_aeroengines = 0

Definition at line 330 of file Actor.h.

◆ ar_num_beams

int RoR::Actor::ar_num_beams = 0

Definition at line 288 of file Actor.h.

◆ ar_num_buoycabs

int RoR::Actor::ar_num_buoycabs = 0

Definition at line 342 of file Actor.h.

◆ ar_num_cabs

int RoR::Actor::ar_num_cabs = 0

Definition at line 334 of file Actor.h.

◆ ar_num_camera_rails

int RoR::Actor::ar_num_camera_rails = 0

Definition at line 344 of file Actor.h.

◆ ar_num_cameras

int RoR::Actor::ar_num_cameras = 0

Definition at line 386 of file Actor.h.

◆ ar_num_cinecams

int RoR::Actor::ar_num_cinecams = 0

Sim attr;.

Definition at line 381 of file Actor.h.

◆ ar_num_collcabs

int RoR::Actor::ar_num_collcabs = 0

Definition at line 339 of file Actor.h.

◆ ar_num_contactable_nodes

int RoR::Actor::ar_num_contactable_nodes = 0

Total number of nodes which can contact ground or cabs.

Definition at line 321 of file Actor.h.

◆ ar_num_contacters

int RoR::Actor::ar_num_contacters = 0

Total number of nodes which can selfcontact cabs.

Definition at line 322 of file Actor.h.

◆ ar_num_custom_particles

int RoR::Actor::ar_num_custom_particles = 0

Definition at line 326 of file Actor.h.

◆ ar_num_nodes

int RoR::Actor::ar_num_nodes = 0

Definition at line 283 of file Actor.h.

◆ ar_num_rotators

int RoR::Actor::ar_num_rotators = 0

Definition at line 294 of file Actor.h.

◆ ar_num_screwprops

int RoR::Actor::ar_num_screwprops = 0

Definition at line 332 of file Actor.h.

◆ ar_num_shocks

int RoR::Actor::ar_num_shocks = 0

Number of shock absorbers.

Definition at line 291 of file Actor.h.

◆ ar_num_soundsources

int RoR::Actor::ar_num_soundsources = 0

Definition at line 328 of file Actor.h.

◆ ar_num_wheels

int RoR::Actor::ar_num_wheels = 0

Definition at line 324 of file Actor.h.

◆ ar_num_wings

int RoR::Actor::ar_num_wings = 0

Definition at line 296 of file Actor.h.

◆ ar_origin

Ogre::Vector3 RoR::Actor::ar_origin = Ogre::Vector3::ZERO

Physics state; base position for softbody nodes.

Definition at line 385 of file Actor.h.

◆ ar_parking_brake

bool RoR::Actor::ar_parking_brake = false

Definition at line 414 of file Actor.h.

◆ ar_physics_paused

bool RoR::Actor::ar_physics_paused

Sim state.

Definition at line 484 of file Actor.h.

◆ ar_posnode_spawn_height

float RoR::Actor::ar_posnode_spawn_height = 0.f

Definition at line 396 of file Actor.h.

◆ ar_predicted_bounding_box

Ogre::AxisAlignedBox RoR::Actor::ar_predicted_bounding_box

Definition at line 308 of file Actor.h.

◆ ar_predicted_coll_bounding_boxes

std::vector<Ogre::AxisAlignedBox> RoR::Actor::ar_predicted_coll_bounding_boxes

Definition at line 317 of file Actor.h.

◆ ar_rescuer_flag

bool RoR::Actor::ar_rescuer_flag

Gameplay attr; defined in truckfile. TODO: Does anybody use this anymore?

Definition at line 479 of file Actor.h.

◆ ar_right_mirror_angle

float RoR::Actor::ar_right_mirror_angle = -0.52f

Sim state; rear view mirror angle.

Definition at line 417 of file Actor.h.

◆ ar_ropables

std::vector<ropable_t> RoR::Actor::ar_ropables

Definition at line 300 of file Actor.h.

◆ ar_ropes

std::vector<rope_t> RoR::Actor::ar_ropes

Definition at line 299 of file Actor.h.

◆ ar_rotators

rotator_t* RoR::Actor::ar_rotators = nullptr

Definition at line 293 of file Actor.h.

◆ ar_rudder

float RoR::Actor::ar_rudder = 0.f

Sim state; aerial/marine controller.

Definition at line 419 of file Actor.h.

◆ ar_scale

float RoR::Actor::ar_scale = 1.f

Physics state; scale of the actor (nominal = 1.0)

Definition at line 398 of file Actor.h.

◆ ar_screwprops

Screwprop* RoR::Actor::ar_screwprops[MAX_SCREWPROPS] = {}

Definition at line 331 of file Actor.h.

◆ ar_shocks

shock_t* RoR::Actor::ar_shocks = nullptr

Shock absorbers.

Definition at line 290 of file Actor.h.

◆ ar_sleep_counter

float RoR::Actor::ar_sleep_counter = 0.f

Sim state; idle time counter.

Definition at line 412 of file Actor.h.

◆ ar_soundsources

soundsource_t RoR::Actor::ar_soundsources[MAX_SOUNDSCRIPTS_PER_TRUCK] = {}

Definition at line 327 of file Actor.h.

◆ ar_state

ActorState RoR::Actor::ar_state = ActorState::LOCAL_SIMULATED

Definition at line 446 of file Actor.h.

◆ ar_submesh_ground_model

ground_model_t* RoR::Actor::ar_submesh_ground_model = nullptr

Definition at line 413 of file Actor.h.

◆ ar_ties

std::vector<tie_t> RoR::Actor::ar_ties

Definition at line 301 of file Actor.h.

◆ ar_toggle_ropes

bool RoR::Actor::ar_toggle_ropes

Sim state.

Definition at line 482 of file Actor.h.

◆ ar_toggle_ties

bool RoR::Actor::ar_toggle_ties

Sim state.

Definition at line 483 of file Actor.h.

◆ ar_top_speed

float RoR::Actor::ar_top_speed = 0.f

Sim state.

Definition at line 435 of file Actor.h.

◆ ar_trailer_parking_brake

bool RoR::Actor::ar_trailer_parking_brake = false

Definition at line 415 of file Actor.h.

◆ ar_unique_commandkey_pairs

std::vector<UniqueCommandKeyPair> RoR::Actor::ar_unique_commandkey_pairs

UI helper for displaying command control keys to user (must be built at spawn).

Definition at line 319 of file Actor.h.

◆ ar_update_physics

bool RoR::Actor::ar_update_physics

Physics state; Should this actor be updated (locally) in the next physics step?

Definition at line 473 of file Actor.h.

◆ ar_vector_index

unsigned int RoR::Actor::ar_vector_index = 0

Sim attr; actor element index in std::vector<m_actors>

Definition at line 377 of file Actor.h.

◆ ar_vehicle_ai

VehicleAIPtr RoR::Actor::ar_vehicle_ai

Definition at line 397 of file Actor.h.

◆ ar_wheel_speed

float RoR::Actor::ar_wheel_speed = 0.f

Physics state; wheel speed in m/s.

Definition at line 400 of file Actor.h.

◆ ar_wheel_spin

float RoR::Actor::ar_wheel_spin = 0.f

Physics state; wheel speed in radians/s.

Definition at line 401 of file Actor.h.

◆ ar_wheeldetachers

std::vector<wheeldetacher_t> RoR::Actor::ar_wheeldetachers

Definition at line 313 of file Actor.h.

◆ ar_wheels

wheel_t RoR::Actor::ar_wheels[MAX_WHEELS] = {}

Definition at line 323 of file Actor.h.

◆ ar_wings

wing_t* RoR::Actor::ar_wings = nullptr

Definition at line 295 of file Actor.h.

◆ authors

std::vector<authorinfo_t> RoR::Actor::authors

Definition at line 297 of file Actor.h.

◆ cc_accs

std::deque<float> RoR::Actor::cc_accs

Cruise Control.

Definition at line 369 of file Actor.h.

◆ cc_can_brake

bool RoR::Actor::cc_can_brake = false

Cruise Control.

Definition at line 365 of file Actor.h.

◆ cc_mode

bool RoR::Actor::cc_mode = false

Cruise Control.

Definition at line 364 of file Actor.h.

◆ cc_target_rpm

float RoR::Actor::cc_target_rpm = 0.f

Cruise Control.

Definition at line 366 of file Actor.h.

◆ cc_target_speed

float RoR::Actor::cc_target_speed = 0.f

Cruise Control.

Definition at line 367 of file Actor.h.

◆ cc_target_speed_lower_limit

float RoR::Actor::cc_target_speed_lower_limit = 0.f

Cruise Control.

Definition at line 368 of file Actor.h.

◆ exhausts

std::vector<exhaust_t> RoR::Actor::exhausts

Definition at line 298 of file Actor.h.

◆ m_active_eventboxes

std::vector<std::pair<collision_box_t*, NodeNum_t> > RoR::Actor::m_active_eventboxes

Definition at line 438 of file Actor.h.

◆ m_anglesnap_request

int RoR::Actor::m_anglesnap_request = 0

Accumulator.

Definition at line 452 of file Actor.h.

◆ m_antilockbrake

bool RoR::Actor::m_antilockbrake = false
private

GUI state.

Definition at line 592 of file Actor.h.

◆ m_avg_node_position

Ogre::Vector3 RoR::Actor::m_avg_node_position = Ogre::Vector3::ZERO
private

average node position

Definition at line 551 of file Actor.h.

◆ m_avg_node_position_prev

Ogre::Vector3 RoR::Actor::m_avg_node_position_prev = Ogre::Vector3::ZERO
private

Definition at line 553 of file Actor.h.

◆ m_avg_node_velocity

Ogre::Vector3 RoR::Actor::m_avg_node_velocity = Ogre::Vector3::ZERO
private

average node velocity (compared to the previous frame step)

Definition at line 554 of file Actor.h.

◆ m_avg_proped_wheel_radius

float RoR::Actor::m_avg_proped_wheel_radius = 0.f
private

Physics attr, filled at spawn - Average proped wheel radius.

Definition at line 546 of file Actor.h.

◆ m_avionic_chatter_timer

float RoR::Actor::m_avionic_chatter_timer = 11.f
private

Sound fx state (some pseudo random number, doesn't matter)

Definition at line 547 of file Actor.h.

◆ m_axle_diffs

Differential* RoR::Actor::m_axle_diffs[1+MAX_WHEELS/2] = {}
private

Physics.

Definition at line 569 of file Actor.h.

◆ m_beam_break_debug_enabled

bool RoR::Actor::m_beam_break_debug_enabled
private

Logging state.

Definition at line 630 of file Actor.h.

◆ m_beam_deform_debug_enabled

bool RoR::Actor::m_beam_deform_debug_enabled
private

Logging state.

Definition at line 631 of file Actor.h.

◆ m_blinker_autoreset

bool RoR::Actor::m_blinker_autoreset = false
private

When true, we're steering and blinker will turn off automatically.

Definition at line 617 of file Actor.h.

◆ m_blinker_left_lit

bool RoR::Actor::m_blinker_left_lit = false
private

Blinking state of left turn signal.

Definition at line 618 of file Actor.h.

◆ m_blinker_right_lit

bool RoR::Actor::m_blinker_right_lit = false
private

Blinking state of right turn signal.

Definition at line 619 of file Actor.h.

◆ m_buoyance

std::unique_ptr<Buoyance> RoR::Actor::m_buoyance
private

Physics.

Definition at line 587 of file Actor.h.

◆ m_camera_context

PerVehicleCameraContext RoR::Actor::m_camera_context
private

Definition at line 538 of file Actor.h.

◆ m_camera_gforces

Ogre::Vector3 RoR::Actor::m_camera_gforces = Ogre::Vector3::ZERO
private

Physics state (global)

Definition at line 564 of file Actor.h.

◆ m_camera_gforces_accu

Ogre::Vector3 RoR::Actor::m_camera_gforces_accu = Ogre::Vector3::ZERO
private

Accumulator for 'camera' G-forces.

Definition at line 563 of file Actor.h.

◆ m_camera_local_gforces_cur

Ogre::Vector3 RoR::Actor::m_camera_local_gforces_cur = Ogre::Vector3::ZERO
private

Physics state (camera local)

Definition at line 565 of file Actor.h.

◆ m_camera_local_gforces_max

Ogre::Vector3 RoR::Actor::m_camera_local_gforces_max = Ogre::Vector3::ZERO
private

Physics state (camera local)

Definition at line 566 of file Actor.h.

◆ m_custom_particles_enabled

bool RoR::Actor::m_custom_particles_enabled
private

Gfx state.

Definition at line 628 of file Actor.h.

◆ m_definition

RigDef::DocumentPtr RoR::Actor::m_definition
private

Definition at line 536 of file Actor.h.

◆ m_deletion_entities

std::vector<Ogre::Entity*> RoR::Actor::m_deletion_entities
private

For unloading vehicle; filled at spawn.

Definition at line 542 of file Actor.h.

◆ m_deletion_scene_nodes

std::vector<Ogre::SceneNode*> RoR::Actor::m_deletion_scene_nodes
private

For unloading vehicle; filled at spawn.

Definition at line 543 of file Actor.h.

◆ m_description

std::vector<std::string> RoR::Actor::m_description
private

Definition at line 597 of file Actor.h.

◆ m_disable_default_sounds

bool RoR::Actor::m_disable_default_sounds
private

Spawner context; TODO: remove.

Definition at line 633 of file Actor.h.

◆ m_disable_smoke

bool RoR::Actor::m_disable_smoke
private

Stops/starts smoke particles (i.e. exhausts, turbojets).

Definition at line 634 of file Actor.h.

◆ m_dry_mass

float RoR::Actor::m_dry_mass = 0.f
private

Physics attr;.

Definition at line 586 of file Actor.h.

◆ m_flares_mode

GfxFlaresMode RoR::Actor::m_flares_mode = GfxFlaresMode::NONE
private

Snapshot of cvar 'gfx_flares_mode' on spawn.

Definition at line 615 of file Actor.h.

◆ m_flexbody_tasks

std::vector<std::shared_ptr<Task> > RoR::Actor::m_flexbody_tasks
private

Gfx state.

Definition at line 535 of file Actor.h.

◆ m_force_sensors

struct RoR::Actor::VehicleForceSensors RoR::Actor::m_force_sensors
private

Data for ForceFeedback devices.

◆ m_fusealge_airfoil

Airfoil* RoR::Actor::m_fusealge_airfoil = nullptr
private

Physics attr; defined in truckfile.

Definition at line 577 of file Actor.h.

◆ m_fusealge_back

node_t* RoR::Actor::m_fusealge_back = nullptr
private

Physics attr; defined in truckfile.

Definition at line 579 of file Actor.h.

◆ m_fusealge_front

node_t* RoR::Actor::m_fusealge_front = nullptr
private

Physics attr; defined in truckfile.

Definition at line 578 of file Actor.h.

◆ m_fusealge_width

float RoR::Actor::m_fusealge_width = 0.f
private

Physics attr; defined in truckfile.

Definition at line 580 of file Actor.h.

◆ m_gfx_actor

std::unique_ptr<GfxActor> RoR::Actor::m_gfx_actor
private

Definition at line 537 of file Actor.h.

◆ m_handbrake_force

float RoR::Actor::m_handbrake_force = 0.f
private

Physics attr; defined in truckfile.

Definition at line 576 of file Actor.h.

◆ m_has_axles_section

bool RoR::Actor::m_has_axles_section = false
private

Temporary (legacy parsing helper) until central diffs are implemented.

Definition at line 595 of file Actor.h.

◆ m_has_command_beams

bool RoR::Actor::m_has_command_beams
private

Physics attr;.

Definition at line 627 of file Actor.h.

◆ m_hud_features_ok

bool RoR::Actor::m_hud_features_ok
private

Gfx state; Are HUD features matching actor's capabilities?

Definition at line 622 of file Actor.h.

◆ m_inter_point_col_detector

PointColDetector* RoR::Actor::m_inter_point_col_detector = nullptr
private

Physics.

Definition at line 548 of file Actor.h.

◆ m_intra_point_col_detector

PointColDetector* RoR::Actor::m_intra_point_col_detector = nullptr
private

Physics.

Definition at line 549 of file Actor.h.

◆ m_lightmask

BitMask_t RoR::Actor::m_lightmask = 0
private

RoRnet::Lightmask.

Definition at line 616 of file Actor.h.

◆ m_load_mass

float RoR::Actor::m_load_mass = 0.f
private

Physics attr; predefined load mass in Kg.

Definition at line 584 of file Actor.h.

◆ m_masscount

int RoR::Actor::m_masscount = 0
private

Physics attr; Number of nodes loaded with l option.

Definition at line 585 of file Actor.h.

◆ m_min_camera_radius

Ogre::Real RoR::Actor::m_min_camera_radius = 0.f
private

Definition at line 552 of file Actor.h.

◆ m_mouse_grab_move_force

float RoR::Actor::m_mouse_grab_move_force = 0.f
private

Definition at line 560 of file Actor.h.

◆ m_mouse_grab_node

NodeNum_t RoR::Actor::m_mouse_grab_node = NODENUM_INVALID
private

Sim state; node currently being dragged by user.

Definition at line 558 of file Actor.h.

◆ m_mouse_grab_pos

Ogre::Vector3 RoR::Actor::m_mouse_grab_pos = Ogre::Vector3::ZERO
private

Definition at line 559 of file Actor.h.

◆ m_net_color_num

int RoR::Actor::m_net_color_num = 0
private

Definition at line 610 of file Actor.h.

◆ m_net_first_wheel_node

int RoR::Actor::m_net_first_wheel_node = 0
private

Network attr; Determines data buffer layout; calculated on spawn.

Definition at line 607 of file Actor.h.

◆ m_net_initialized

bool RoR::Actor::m_net_initialized
private

Definition at line 624 of file Actor.h.

◆ m_net_node_buf_size

size_t RoR::Actor::m_net_node_buf_size = 0
private

For incoming/outgoing traffic; calculated on spawn.

Definition at line 602 of file Actor.h.

◆ m_net_node_compression

float RoR::Actor::m_net_node_compression = 0.f
private

For incoming/outgoing traffic; calculated on spawn.

Definition at line 606 of file Actor.h.

◆ m_net_propanimkey_buf_size

size_t RoR::Actor::m_net_propanimkey_buf_size = 0
private

For incoming/outgoing traffic; calculated on spawn.

Definition at line 604 of file Actor.h.

◆ m_net_total_buffer_size

size_t RoR::Actor::m_net_total_buffer_size = 0
private

For incoming/outgoing traffic; calculated on spawn.

Definition at line 605 of file Actor.h.

◆ m_net_updates

std::deque<NetUpdate> RoR::Actor::m_net_updates
private

Incoming stream of NetUpdates.

Definition at line 659 of file Actor.h.

◆ m_net_username

Ogre::UTFString RoR::Actor::m_net_username
private

Definition at line 609 of file Actor.h.

◆ m_net_wheel_buf_size

size_t RoR::Actor::m_net_wheel_buf_size = 0
private

For incoming/outgoing traffic; calculated on spawn.

Definition at line 603 of file Actor.h.

◆ m_num_axle_diffs

int RoR::Actor::m_num_axle_diffs = 0
private

Physics attr.

Definition at line 570 of file Actor.h.

◆ m_num_command_beams

int RoR::Actor::m_num_command_beams = 0
private

TODO: Remove! Spawner context only; likely unused feature.

Definition at line 583 of file Actor.h.

◆ m_num_proped_wheels

int RoR::Actor::m_num_proped_wheels = 0
private

Physics attr, filled at spawn - Number of propelled wheels.

Definition at line 545 of file Actor.h.

◆ m_num_wheel_diffs

int RoR::Actor::m_num_wheel_diffs = 0
private

Physics attr.

Definition at line 572 of file Actor.h.

◆ m_odometer_total

float RoR::Actor::m_odometer_total = 0.f
private

GUI state.

Definition at line 581 of file Actor.h.

◆ m_odometer_user

float RoR::Actor::m_odometer_user = 0.f
private

GUI state.

Definition at line 582 of file Actor.h.

◆ m_ongoing_reset

bool RoR::Actor::m_ongoing_reset = false
private

Hack to prevent position/rotation creep during interactive truck reset.

Definition at line 594 of file Actor.h.

◆ m_potential_eventboxes

CollisionBoxPtrVec RoR::Actor::m_potential_eventboxes

Definition at line 437 of file Actor.h.

◆ m_preloaded_with_terrain

bool RoR::Actor::m_preloaded_with_terrain
private

Spawn context (TODO: remove!)

Definition at line 629 of file Actor.h.

◆ m_previous_gear

int RoR::Actor::m_previous_gear = 0
private

Sim state; land vehicle shifting.

Definition at line 575 of file Actor.h.

◆ m_prop_anim_key_states

std::vector<PropAnimKeyState> RoR::Actor::m_prop_anim_key_states
private

Definition at line 598 of file Actor.h.

◆ m_proped_wheel_pairs

int RoR::Actor::m_proped_wheel_pairs[MAX_WHEELS] = {}
private

Physics attr; For inter-differential locking.

Definition at line 544 of file Actor.h.

◆ m_railgroups

std::vector<RailGroup*> RoR::Actor::m_railgroups
private

all the available RailGroups for this actor

Definition at line 541 of file Actor.h.

◆ m_replay_handler

Replay* RoR::Actor::m_replay_handler = nullptr
private

Definition at line 556 of file Actor.h.

◆ m_reset_timer

Ogre::Timer RoR::Actor::m_reset_timer
private

Definition at line 562 of file Actor.h.

◆ m_rotation_request

float RoR::Actor::m_rotation_request = 0.f

Accumulator.

Definition at line 451 of file Actor.h.

◆ m_rotation_request_center

Ogre::Vector3 RoR::Actor::m_rotation_request_center = Ogre::Vector3::ZERO

Definition at line 450 of file Actor.h.

◆ m_section_config

Ogre::String RoR::Actor::m_section_config
private

Definition at line 539 of file Actor.h.

◆ m_skid_trails

Skidmark* RoR::Actor::m_skid_trails[MAX_WHEELS *2] = {}
private

Definition at line 591 of file Actor.h.

◆ m_slidenodes

std::vector<SlideNode> RoR::Actor::m_slidenodes
private

all the SlideNodes available on this actor

Definition at line 540 of file Actor.h.

◆ m_slidenodes_locked

bool RoR::Actor::m_slidenodes_locked
private

Physics state; Are SlideNodes locked?

Definition at line 623 of file Actor.h.

◆ m_spawn_rotation

float RoR::Actor::m_spawn_rotation = 0.f
private

Definition at line 561 of file Actor.h.

◆ m_stabilizer_shock_ratio

float RoR::Actor::m_stabilizer_shock_ratio = 0.f
private

Physics state.

Definition at line 567 of file Actor.h.

◆ m_stabilizer_shock_request

int RoR::Actor::m_stabilizer_shock_request = 0
private

Physics state; values: { -1, 0, 1 }.

Definition at line 568 of file Actor.h.

◆ m_stabilizer_shock_sleep

float RoR::Actor::m_stabilizer_shock_sleep = 0.f
private

Sim state.

Definition at line 555 of file Actor.h.

◆ m_total_mass

float RoR::Actor::m_total_mass = 0.f
private

Physics state; total mass in Kg.

Definition at line 557 of file Actor.h.

◆ m_tractioncontrol

bool RoR::Actor::m_tractioncontrol = false
private

GUI state.

Definition at line 593 of file Actor.h.

◆ m_transfer_case

TransferCase* RoR::Actor::m_transfer_case = nullptr
private

Physics.

Definition at line 573 of file Actor.h.

◆ m_translation_request

Ogre::Vector3 RoR::Actor::m_translation_request = Ogre::Vector3::ZERO

Accumulator.

Definition at line 453 of file Actor.h.

◆ m_trigger_debug_enabled

bool RoR::Actor::m_trigger_debug_enabled
private

Logging state.

Definition at line 632 of file Actor.h.

◆ m_tyre_pressure

TyrePressure RoR::Actor::m_tyre_pressure
private

Definition at line 596 of file Actor.h.

◆ m_used_actor_entry

CacheEntryPtr RoR::Actor::m_used_actor_entry
private

Definition at line 588 of file Actor.h.

◆ m_used_skin_entry

CacheEntryPtr RoR::Actor::m_used_skin_entry
private

Graphics.

Definition at line 589 of file Actor.h.

◆ m_water_contact

bool RoR::Actor::m_water_contact
private

Scripting state.

Definition at line 625 of file Actor.h.

◆ m_water_contact_old

bool RoR::Actor::m_water_contact_old
private

Scripting state.

Definition at line 626 of file Actor.h.

◆ m_wheel_diffs

Differential* RoR::Actor::m_wheel_diffs[MAX_WHEELS/2] = {}
private

Physics.

Definition at line 571 of file Actor.h.

◆ m_wheel_node_count

int RoR::Actor::m_wheel_node_count = 0
private

Static attr; filled at spawn.

Definition at line 574 of file Actor.h.

◆ m_working_tuneup_def

TuneupDefPtr RoR::Actor::m_working_tuneup_def
private

Each actor gets unique instance, even if loaded from .tuneup file in modcache.

Definition at line 590 of file Actor.h.

◆ sl_enabled

bool RoR::Actor::sl_enabled = false

Speed limiter;.

Definition at line 370 of file Actor.h.

◆ sl_speed_limit

float RoR::Actor::sl_speed_limit = 0.f

Speed limiter;.

Definition at line 371 of file Actor.h.

◆ tc_mode

bool RoR::Actor::tc_mode = false

Traction control state; Enabled? {1/0}.

Definition at line 357 of file Actor.h.

◆ tc_nodash

bool RoR::Actor::tc_nodash = false

Traction control attribute; Hide the dashboard indicator?

Definition at line 360 of file Actor.h.

◆ tc_notoggle

bool RoR::Actor::tc_notoggle = false

Traction control attribute; Disable in-game toggle?

Definition at line 361 of file Actor.h.

◆ tc_pulse_state

bool RoR::Actor::tc_pulse_state = 0.f

Traction control state;.

Definition at line 359 of file Actor.h.

◆ tc_pulse_time

float RoR::Actor::tc_pulse_time = 0.f

Traction control attribute;.

Definition at line 358 of file Actor.h.

◆ tc_ratio

float RoR::Actor::tc_ratio = 0.f

Traction control attribute: Regulating force.

Definition at line 356 of file Actor.h.

◆ tc_timer

float RoR::Actor::tc_timer = 0.f

Traction control state;.

Definition at line 362 of file Actor.h.


The documentation for this class was generated from the following files: