DayZ 1.26
DayZ Explorer by KGB
Загрузка...
Поиск...
Не найдено
Файл ActionPushCar.c

См. исходные тексты.

Структуры данных

class  ActionPushCarData
 
class  ActionPushCar
 
class  CAContinuousRepeatPushCar
 

Функции

void ApplyForce (ActionPushObjectData actionData)
 

Переменные

ActionPushCarData PUSH_FORCE_IMPULSE_INCREMENT = 200.0
 
ActionPushCarData m_ActionDataPushCar
 
ActionPushCar m_Car
 

Функции

◆ ApplyForce()

void ApplyForce ( ActionPushObjectData actionData)
protected
18 {
19 m_ActionDataPushCar = ActionPushCarData.Cast(m_ActionData);
20 CarScript car = CarScript.Cast(actionData.m_Object);
21
24
25 float bodyMass = dBodyGetMass(car);
26 float invBodyMass = 1.0 / bodyMass;
27 float force = bodyMass * PUSH_FORCE_IMPULSE_INCREMENT * car.GetPushForceCoefficientMultiplier();
28
29 float easedProgress = Easing.EaseInOutSine(actionData.m_ActionComponent.GetProgress());
30
36
37 actionData.m_Player.DepleteStamina(EStaminaModifiers.PUSH_CAR);
38
39 dBodyApplyImpulseAt(car, impulse, car.ModelToWorld(car.GetEnginePos()));
40 }
ActionPushCarData m_ActionDataPushCar
Definition ActionPushCar.c:15
ActionPushCarData PUSH_FORCE_IMPULSE_INCREMENT
EStaminaModifiers
Definition EStaminaModifiers.c:2
Definition ActionPushCar.c:2
float m_VerticalDirectionRandom
Definition ActionPushCar.c:5
float m_HorizontalDirectionRandom
Definition ActionPushCar.c:4
int m_PushDirection
Definition ActionPushCar.c:3
Definition CivilianSedan.c:2
Input value between 0 and 1, returns value adjusted by easing, no automatic clamping of input(do your...
Definition Easing.c:3
static float EaseInOutSine(float t)
Definition Easing.c:14
Definition EnMath.c:7
Definition EntityAI.c:95
Definition EnConvert.c:97
Definition EnConvert.c:106
static proto float RandomFloat(float min, float max)
Returns a random float number between and min[inclusive] and max[exclusive].
proto void dBodyApplyImpulseAt(notnull IEntity body, vector impulse, vector pos)
Applies impuls on a pos position in world coordinates.
proto native float dBodyGetMass(notnull IEntity ent)

Перекрестные ссылки dBodyApplyImpulseAt(), dBodyGetMass(), Easing::EaseInOutSine(), m_ActionDataPushCar, ActionPushCarData::m_HorizontalDirectionRandom, ActionPushCarData::m_PushDirection, ActionPushCarData::m_VerticalDirectionRandom, PUSH_FORCE_IMPULSE_INCREMENT и Math::RandomFloat().

Используется в ProgressActionComponent().

Переменные

◆ m_ActionDataPushCar

ActionPushCarData m_ActionDataPushCar
private

Используется в ApplyForce().

◆ m_Car

CarScript m_Car
protected

◆ PUSH_FORCE_IMPULSE_INCREMENT

ActionPushCarData PUSH_FORCE_IMPULSE_INCREMENT = 200.0

Используется в ApplyForce().