2003 {
2004 if (!IsAlive())
2005 {
2007 {
2009 }
2010 return;
2011 }
2012
2013 HumanInputController hic = GetInputController();
2014
2016
2018 {
2020 {
2021 camChange = false;
2022 }
2023 }
2024
2026 if (
g_Game.GetWorld().Is3rdPersonDisabled())
2027 {
2029 }
2030 else if (camChange)
2031 {
2033 }
2034
2035
2038
2040 {
2043 }
2045 {
2048 }
2049
2051 {
2054 {
2056 }
2058 {
2059 float pSpeed;
2060 vector pLocalDirection;
2062
2064 {
2066 }
2067 }
2068 }
2069 else
2070 {
2072 }
2073
2075 {
2076 float headingAngle = MiscGameplayFunctions.GetHeadingAngle(this);
2079 float headingAngleDiff = 0.0;
2080
2082 {
2084 }
2085 else
2086 {
2088 }
2089
2090 if (headingAngleDiff > 0.2)
2091 {
2092 int time =
g_Game.GetTime();
2093
2094 float timefilterconstant = 400 - (headingAngleDiff * 100);
2095
2097 {
2098 float volume = headingAngleDiff / 0.5;
2099 if (volume > 1)
2100 {
2101 volume = 1;
2102 }
2103 if (volume < 0.25)
2104 {
2105 volume = 0.25;
2106 }
2107
2110 {
2112 }
2113
2114 string soundSetName = "Cloth_Body_longmove_TShirt_Soundset";
2115
2116 string bodyClothName = "";
2117 EntityAI attachment = GetInventory().FindAttachment(InventorySlots.BODY);
2118 if (attachment)
2119 {
2120 bodyClothName = attachment.GetAttachmentSoundType();
2121 }
2122
2123 if (bodyClothName != "")
2124 {
2125 string path =
"CfgSoundTables CfgAttachmentSoundTables Cloth_Body_Longmove_LookupTable";
2126 int soundCount =
g_Game.ConfigGetChildrenCount(
path);
2127
2128 for (int i = 0; i < soundCount; i++)
2129 {
2132
2133 if (
name == bodyClothName)
2134 {
2136 g_Game.ConfigGetTextArray(
path +
" " +
name +
" soundSets", stringArray);
2137 soundSetName = stringArray.Get(0);
2138
2139 delete stringArray;
2140 }
2141 }
2142 }
2143
2146
2147 if (soundObjectBuilder != NULL)
2148 {
2149 SoundObject soundObject = soundObjectBuilder.BuildSoundObject();
2150
2151 if (soundObject != NULL)
2152 {
2154
2157 wave.SetVolumeRelative(volume);
2158
2161 }
2162 }
2163 }
2164
2166 {
2167 float volume2 = headingAngleDiff * 2;
2168 if (volume2 > 1)
2169 {
2170 volume2 = 1;
2171 }
2172
2175 {
2177 }
2179 {
2181 }
2182
2183 string soundSetName2 = "walkProne_noHS_asphalt_ext_Char_SoundSet";
2185
2186 if (surfaceType != "")
2187 {
2188 string movementSurfaceType = "walkProne_" + surfaceType;
2189
2190 string path2 = "CfgSoundTables CfgStepSoundTables walkProne_noHS_Char_LookupTable";
2191 int soundCount2 =
g_Game.ConfigGetChildrenCount(path2);
2192
2193 for (int i2 = 0; i2 < soundCount2; i2++)
2194 {
2195 string name2 = "";
2196 g_Game.ConfigGetChildName(path2, i2, name2);
2197
2198 if (name2 == movementSurfaceType)
2199 {
2201 g_Game.ConfigGetTextArray(path2 +
" " + name2 +
" soundSets", stringArray2);
2202 soundSetName2 = stringArray2.Get(0);
2203
2204 delete stringArray2;
2205 }
2206 }
2207 }
2208
2211
2212 if (soundObjectBuilder2 != NULL)
2213 {
2214 SoundObject soundObject2 = soundObjectBuilder2.BuildSoundObject();
2215
2216 if (soundObject2 != NULL)
2217 {
2219
2220 AbstractWave wave2 =
g_Game.GetSoundScene().Play3D(soundObject2, soundObjectBuilder2);
2222 wave2.SetVolumeRelative(volume2);
2223
2226 }
2227 }
2228 }
2229
2231 }
2232 }
2233 }
PlayerSpawnPresetDiscreteItemSetSlotData name
one set for cargo
bool m_CameraOpticsAimOverride
bool IsWeaponObstructionBlockingADS()
string GetSurfaceType(SurfaceAnimationBone limbType)
float m_LastHeadingAngleBlock
float m_LastHeadingAngleBlock2
ref HumanMovementState m_MovementState
time step for gradual update of dead screen visibilibty up to full visbility [s]
ECameraZoomType m_CameraEyeZoomLevel
proto native void SetVerticalMinimumAimLimit(float value)
sets vertical minimum aim limit for a player
DayZPlayerConstants
defined in C++
proto native bool IsPlayerInStance(int pStanceMask)
-------------— camera additiona functions ----------------------—
array< string > TStringArray
class AbstractSoundScene SoundObjectBuilder(SoundParams soundParams)
void SoundObject(SoundParams soundParams)
vector GetPosition()
Get the world position of the Effect.
class SoundObject SoundParams(string name)
proto native void SetPosition(vector position)
Note: Sets the position locally if parented, retrieves globally with the sound offset.