121 override bool IsAreaAtDoorFree(
int currentSeat,
float maxAllowedObjHeight = 0.5,
float horizontalExtents = 0.5,
float playerHeight = 1.7 )
127 extents[0] = horizontalExtents;
128 extents[1] = playerHeight;
129 extents[2] = horizontalExtents;
133 extents[2] = extents[2] * 6;
137 return IsAreaAtDoorFree( currentSeat, maxAllowedObjHeight, extents, transform );
140 override Shape DebugFreeAreaAtDoor(
int currentSeat,
float maxAllowedObjHeight = 0.5,
float horizontalExtents = 0.5,
float playerHeight = 1.7 )
142 int color =
ARGB(20, 0, 255, 0);
148 extents[0] = horizontalExtents;
149 extents[1] = playerHeight;
150 extents[2] = horizontalExtents;
154 extents[2] = extents[2] * 6;
158 if (!
IsAreaAtDoorFree( currentSeat, maxAllowedObjHeight, extents, transform ))
160 color =
ARGB(20, 255, 0, 0);
164 shape.SetMatrix(transform);
178 for (
int wheelIdx = 0; wheelIdx < wheelCount; wheelIdx++)
214 proto native
void SetBrake(
float value,
float unused0 = 0,
bool unused1 =
false);
439 [
Obsolete(
"Use methods directly on Car")]
451 [
Obsolete(
"Use Car.SetThrottle/Car.SetTurbo/Car.SetGentle")]
452 proto native
void SetThrust(
float in,
float gentle = 0,
float turbo = 0);
493 proto
void SetThrust(
float in,
float gentle = 0,
float turbo = 0 );
@ SPEED
speed of the boat in km/h
@ ENGINE
indicates if engine is ON
enum CarGearboxType ELEVENTH
CarAutomaticGearboxMode
Enumerated automatic gearbox modes. (native, do not change or extend).
enum CarGearboxType THIRTEENTH
enum CarGearboxType EIGTH
enum CarGearboxType SECOND
enum CarGearboxType FOURTH
enum CarGearboxType NINTH
enum CarGearboxType SIXTEENTH
enum CarGearboxType FIFTH
enum CarGearboxType FIFTEENTH
CarSoundCtrl
Car's sound controller list. (native, do not change or extend).
@ DOORS
indicates if doors are open
CarWheelWaterState
Enumerated car wheel water state. (native, do not change or extend).
@ ON_LAND
if the wheel is on or above land
@ UNDER_WATER
if the wheel is under a water plane
@ IN_WATER
if the wheel is partially within some water plane
enum CarGearboxType SEVENTH
enum CarGearboxType SIXTH
CarFluid
Type of vehicle's fluid. (native, do not change or extend).
enum CarGearboxType THIRD
enum CarGearboxType REVERSE
Enumerated vehicle's gears. (native, do not change or extend).
CarGearboxType
Enumerated gearbox types. (native, do not change or extend).
@ AUTOMATIC
automatic transmission with torque converter between engine and gearbox
@ MANUAL
classic manual transmission with friction plates between engine and gearbox
enum CarGearboxType FIRST
enum CarGearboxType TENTH
enum CarGearboxType TWELFTH
enum CarGearboxType FOURTEENTH
enum CarGearboxType NEUTRAL
DEPRECATED class left for backwards compatibility, methods are available on car itself now.
proto int GetGear()
Returns index of the current gear.
proto float GetBrake()
Returns the current brake value in range <0, 1>.
proto void SetThrust(float in, float gentle=0, float turbo=0)
Sets the thrust value.
proto float GetThrustGentle()
Returns the current thrust gentle modifier value in range <0, 1>.
proto void SetSteering(float in, bool analog=false)
Sets the steering value.
proto void SetBrake(float in, float panic=0)
Sets the brake value.
proto float GetThrust()
Returns the current thrust value in range <0, 1>.
proto void ShiftTo(CarGear gear)
proto float GetSteering()
Returns the current steering value in range <-1, 1>.
proto float GetThrustTurbo()
Returns the current thrust turbo modifier value in range <0, 1>.
Base script class for cars.
static Shape DrawBox(vector pos1, vector pos2, int color=0x1fff7f7f)
Unmanaged surface info handle.
Native class for boats - handles physics simulation.
proto native float GetHandbrake()
Returns the current handbrake value in range <0, 1>.
proto native void ShiftTo(int gear)
Shifts the future gear to selected gear, triggering gearbox simulation.
proto native CarController GetController()
proto native bool WheelIsLocked(int wheelIdx)
Returns true if given wheel is locked in terms of its movement.
proto native float GetFluidFraction(CarFluid fluid)
Returns fraction value (in range <0, 1>) of the current state of the specified vehicle's fluid.
proto native vector GetEnginePos()
Get actual position of engine (model space).
proto native void SetThrottle(float value)
Sets the future throttle value.
proto native void ForceDirection(vector dir)
proto native float EngineGetRPMRedline()
Returns engine's maximal working rpm without damaging the engine.
proto native int GetCurrentGear()
Returns the index of the current gear, -1 if there is no engine.
proto native float GetSteering()
Returns the current steering value in range <-1, 1>.
override bool IsAreaAtDoorFree(int currentSeat, float maxAllowedObjHeight=0.5, float horizontalExtents=0.5, float playerHeight=1.7)
proto native int GetClutch()
Returns the value of how much the clutch is disengaged.
proto native void Leak(CarFluid fluid, float amount)
Removes from the specified fluid the specified amount.
proto native void SetClutchState(bool in)
proto native int WheelCountPresent()
Number of actually attached wheels (hubs only).
proto native int GetGearCount()
Returns the number of gears.
proto native void SetHandbrake(float value)
Sets the future handbrake value.
proto native void SetClutch(float value)
Sets the future clutch value.
proto native CarGearboxType GearboxGetType()
Returns gearbox type. See CarGearboxType enum for more info.
proto native void SetThrust(float in, float gentle=0, float turbo=0)
proto native EntityAI WheelGetEntity(int wheelIdx)
Returns the entity attached that represents the wheel.
proto native float GetThrottle()
Returns the actual throttle value in range <0, 1>.
proto native int GetNeutralGear()
Returns the index of the neutral gear.
proto native void SetBrake(float value, float unused0=0, bool unused1=false)
Sets the future brake value.
proto native int WheelCount()
How many wheel can be attached to a car (hubs only).
proto native void EngineStop()
Stops the engine.
proto native CarAutomaticGearboxMode GearboxGetMode()
Returns gearbox mode. This is useful when car has automatic gearbox.
proto native float GetSpeedometer()
Returns the current speed of the vehicle in km/h.
void OnGearChanged(int newGear, int oldGear)
Is called every time when the simulation changed gear.
override event GetOwnerStateType()
proto native bool WheelHasContact(int wheelIdx)
Returns true if given wheel is making any contact.
proto native float GetThrustGentle()
override Shape DebugFreeAreaAtDoor(int currentSeat, float maxAllowedObjHeight=0.5, float horizontalExtents=0.5, float playerHeight=1.7)
proto native float GetThrust()
proto native void SetEnginePos(vector pos)
Override the position of engine (model space).
proto native bool EngineIsOn()
Returns true when engine is running, false otherwise.
proto native CarWheelWaterState WheelGetWaterState(int wheelIdx)
Returns the state that the wheel is in with water.
proto native float EngineGetRPMIdle()
Returns engine's idle rpm before engine stalls.
proto native void SetBrakesActivateWithoutDriver(bool activate=true)
Sets if brakes should activate without a driver present.
proto native void ShiftDown()
Shifts the future gear down, triggering gearbox simulation.
proto native void ShiftUp()
Shifts the future gear up, triggering gearbox simulation.
proto native void LeakAll(CarFluid fluid)
Removes all the specified fluid from vehicle.
bool OnBeforeEngineStart()
Is called every time the game wants to start the engine.
proto native vector WheelGetDirection(int wheelIdx)
Returns the direction pointing forwards that the wheel is facing.
proto native void EngineStart()
Starts the engine.
proto native float EngineGetRPM()
Returns engine's rpm value.
void OnEngineStart()
Is called every time the engine starts.
proto native bool WheelIsAnyLocked()
Returns true if any of the wheels are locked in terms of its movement.
proto native float GetFluidCapacity(CarFluid fluid)
Returns tank capacity for the specified vehicle's fluid.
proto native float EngineGetRPMMin()
Returns engine's min operating rpm.
proto native float GetThrustTurbo()
void OnFluidChanged(CarFluid fluid, float newValue, float oldValue)
Is called every time when the specified vehicle's fluid level changes.
override event GetMoveType()
void OnEngineStop()
Is called every time the engine stops.
proto native int GetGear()
Returns the index of the future gear, -1 if there is no engine.
proto native vector WheelGetContactPosition(int wheelIdx)
Returns the position of contact in world space, only valid if there was an actual contact.
proto native void SetSteering(float value, bool unused0=false)
Sets the future steering value.
proto native vector WheelGetContactNormal(int wheelIdx)
Returns the normal of contact in world space, only valid if there was an actual contact.
float GetSpeedometerAbsolute()
Returns the current speed of the vehicle in km/h. Value is absolute.
proto native int GetGearsCount()
proto native void Fill(CarFluid fluid, float amount)
Adds to the specified fluid the specified amount.
float OnSound(CarSoundCtrl ctrl, float oldValue)
Is called every sound simulation step.
proto native SurfaceInfo WheelGetSurface(int wheelIdx)
Returns the surface that the wheel is nearby.
proto native float GetBrake()
Returns the current brake value in range <0, 1>.
proto native void ForcePosition(vector pos)
proto native float EngineGetRPMMax()
Returns engine's max rpm before engine blows up.
bool DetectFlippedUsingWheels(VehicleFlippedContext ctx, bool disallowSide)
proto native float WheelGetAngularVelocity(int wheelIdx)
Returns the raw angular velocity of the wheel, unstable value.
Base native class of all vehicles in game.
static float Dot(vector v1, vector v2)
Returns Dot product of vector v1 and vector v2.
void Obsolete(string msg="")
@ USER1
Flags for custom usage and filterings.
static proto float AbsFloat(float f)
Returns absolute value.
< h scale="0.8">< image set="dayz_gui" name="icon_pin"/> Welcome to the DayZ Stress Test Branch</h >< h scale="0.6"> This branch serves for time limited development tests that are open to the community Our goal in each of these tests is to gather performance and stability data from servers under heavy load</h ></br >< h scale="0.8">< image set="dayz_gui" name="icon_pin"/> Stress test Schedule</h >< h scale="0.6"> We ll only run the Stress Tests when our development team needs data and or specific feedback Stress Tests will be announced on our Twitter and and will usually run for a couple of hours</h ></br >< h scale="0.8">< image set="dayz_gui" name="icon_pin"/> Current Stress Test</h >< h scale="0.6"> In the first bunch of Stress we ll mostly focus on watching server performance under heavy PvP gameplay load For detailed information about an ongoing Stress please visit dayz com dev hub</h ></br >< h scale="0.8">< image set="dayz_gui" name="icon_pin"/> Important Note</h >< h scale="0.6"> Stress Tests do not represent a typical DayZ gameplay experience Spawn starting gear
int ARGB(int a, int r, int g, int b)