DayZ 1.27
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено
UndergroundHandlerClient.c
См. документацию.
2{
3 NONE,//player is not interacting with underground at any level
4 OUTER,//player is on the outskirts of the underdound, some effects are already in effect, while others might not be
5 TRANSITIONING,//player has entered underground and is in the process of screen darkening transition
6 FULL//the player is now fully entered underground
7}
8
10{
11 const float LIGHT_BLEND_SPEED_IN = 5;
12 const float LIGHT_BLEND_SPEED_OUT = 1.75;
13 const float MAX_RATIO = 0.9;//how much max ratio between 0..1 can a single breadcrumb occupy
14 const float RATIO_CUTOFF = 0;//what's the minimum ratio a breadcrumb needs to have to be considered when calculatiing accommodation
15 const float DISTANCE_CUTOFF = 5;//we ignore breadcrumbs further than this distance
16 const float ACCO_MODIFIER = 1;//when we calculate eye accommodation between 0..1 based on the breadcrumbs values and distances, we multiply the result by this modifier to get the final eye accommodation value
18 const string UNDERGROUND_LIGHTING = "dz\\data\\lighting\\lighting_underground.txt";
20
22 protected PPERUndergroundAcco m_Requester;
23 protected PPERequester_CameraNV m_NVRequester;
24 protected ref set<UndergroundTrigger> m_InsideTriggers = new set<UndergroundTrigger>();
25
26 protected float m_EyeAccoTarget = 1;
27 protected float m_AccoInterpolationSpeed;
28 protected float m_EyeAcco = 1;
29 protected float m_LightingLerpTarget;
30 protected float m_LightingLerp;
31 protected string m_AmbientController; // active sound controlelr for ambient
33
34 protected UndergroundTrigger m_TransitionalTrigger;
35
37 {
39 m_Player = player;
40 m_NVRequester = PPERequester_CameraNV.Cast(PPERequesterBank.GetRequester( PPERequesterBank.REQ_CAMERANV));
41 }
42
54
55 protected PPERUndergroundAcco GetRequester()
56 {
57 if (!m_Requester)
58 {
59 m_Requester = PPERUndergroundAcco.Cast(PPERequesterBank.GetRequester( PPERequesterBank.REQ_UNDERGROUND));
60 m_Requester.Start();
61 }
62 return m_Requester;
63 }
64
65 void OnTriggerEnter(UndergroundTrigger trigger)
66 {
67 m_InsideTriggers.Insert(trigger);
69
70 }
71
72 void OnTriggerLeave(UndergroundTrigger trigger)
73 {
74 int index = m_InsideTriggers.Find(trigger);
75 if (index != -1)
76 {
77 m_InsideTriggers.Remove(index);
78 }
80 }
81
82 protected void CalculateEyeAccoTarget()
83 {
85 return;
86
87 if (m_TransitionalTrigger.m_Data.UseLinePointFade && m_TransitionalTrigger.m_Data.Breadcrumbs.Count() >= 2)
88 {
90 }
91 else if (m_TransitionalTrigger.m_Data.Breadcrumbs.Count() >= 2)
92 {
94 }
95 }
96
97 protected void CalculateBreadCrumbs()
98 {
99 float closestDist = float.MAX;
100 array<float> distances = new array<float>();
101 array<float> distancesInverted = new array<float>();
102
103 int excludeMask = 0;
104 foreach (int indx, auto crumb:m_TransitionalTrigger.m_Data.Breadcrumbs)
105 {
106 if (indx > 32)//error handling for exceeding this limit is handled elsewhere
107 break;
108
109 float dist = vector.Distance(m_Player.GetPosition(), crumb.GetPosition());
110 float crumbRadius = m_TransitionalTrigger.m_Data.Breadcrumbs[indx].Radius;
111 float maxRadiusAllowed = DISTANCE_CUTOFF;
112
113 if (crumbRadius != -1)
114 maxRadiusAllowed = crumbRadius;
115 if (dist > maxRadiusAllowed)
116 excludeMask = (excludeMask | (1 << indx));
117 else if (m_TransitionalTrigger.m_Data.Breadcrumbs[indx].UseRaycast)
118 {
119 int idx = m_Player.GetBoneIndexByName("Head");
120 vector rayStart = m_Player.GetBonePositionWS(idx);
121 vector rayEnd = crumb.GetPosition();
122 vector hitPos, hitNormal;
123 float hitFraction;
124 Object hitObj;
125
126 if (DayZPhysics.RayCastBullet(rayStart, rayEnd,PhxInteractionLayers.TERRAIN | PhxInteractionLayers.ROADWAY| PhxInteractionLayers.BUILDING, null, hitObj, hitPos, hitNormal, hitFraction))
127 {
128 excludeMask = (excludeMask | (1 << indx));
129 }
130 }
131
132 distances.Insert(dist);
133
134 #ifdef DIAG_DEVELOPER
135 if ( DiagMenu.GetBool(DiagMenuIDs.UNDERGROUND_SHOW_BREADCRUMB) )
136 Debug.DrawSphere(crumb.GetPosition(),0.1, COLOR_RED, ShapeFlags.ONCE);
137 #endif
138 }
139
140 float baseDst = distances[0];
141 float sum = 0;
142
143 foreach (float dst:distances)
144 {
145 if (dst == 0)
146 dst = 0.1;
147 float dstInv = (baseDst / dst) * baseDst;
148 sum += dstInv;
149 distancesInverted.Insert(dstInv);
150 }
151
152 float sumCheck = 0;
153 float eyeAcco = 0;
154 foreach (int i, float dstInvert:distancesInverted)
155 {
156 if ((1 << i) & excludeMask)
157 continue;
158
159 float ratio = dstInvert / sum;
160 if (ratio > MAX_RATIO)
161 ratio = MAX_RATIO;
162
163 if (ratio > RATIO_CUTOFF)
164 {
165 #ifdef DIAG_DEVELOPER
166 if (DiagMenu.GetBool(DiagMenuIDs.UNDERGROUND_SHOW_BREADCRUMB) )
167 {
168 float intensity = (1-ratio) * 255;
169 Debug.DrawLine(GetGame().GetPlayer().GetPosition() + "0 1 0", m_TransitionalTrigger.m_Data.Breadcrumbs[i].GetPosition(),ARGB(0,255,intensity,intensity),ShapeFlags.ONCE);
170 }
171 #endif
172
173 eyeAcco += ratio * m_TransitionalTrigger.m_Data.Breadcrumbs[i].EyeAccommodation;
174 }
175 }
176
177 m_EyeAccoTarget = eyeAcco * ACCO_MODIFIER;
178 }
179
180 protected void CalculateLinePointFade()
181 {
183 JsonUndergroundAreaBreadcrumb startPoint = points[0];
184 JsonUndergroundAreaBreadcrumb endPoint = points[points.Count() - 1];
185 vector playerPos = m_Player.GetPosition();
186
187 bool forceAcco;
188 float acco;
189 float accoMax = m_TransitionalTrigger.m_Data.Breadcrumbs[0].EyeAccommodation;
190 float accoMin = endPoint.EyeAccommodation;
191 JsonUndergroundAreaBreadcrumb closestPoint;
192 JsonUndergroundAreaBreadcrumb secondaryPoint;
193 float distanceToClosest;
194 float distanceToSecondary;
195 float distanceBetweenPoints;
196
197 foreach (JsonUndergroundAreaBreadcrumb point : points) //identify closest segment
198 {
199 float dist = vector.DistanceSq(playerPos, point.GetPosition());
200 if (!closestPoint || dist < distanceToClosest)
201 {
202 if (closestPoint)
203 {
204 secondaryPoint = closestPoint;
205 distanceToSecondary = distanceToClosest;
206 }
207 closestPoint = point;
208 distanceToClosest = dist;
209 }
210 else if (!secondaryPoint || dist < secondaryPoint)
211 {
212 secondaryPoint = point;
213 distanceToSecondary = dist;
214 }
215
216 #ifdef DIAG_DEVELOPER
217 if (DiagMenu.GetBool(DiagMenuIDs.UNDERGROUND_SHOW_BREADCRUMB))
218 Debug.DrawSphere(point.GetPosition(),0.1, COLOR_RED, ShapeFlags.ONCE);
219 #endif
220 }
221
222 distanceBetweenPoints = vector.DistanceSq(closestPoint.GetPosition(), secondaryPoint.GetPosition());
223
224 if (closestPoint == startPoint && secondaryPoint == points[1] && distanceToSecondary > distanceBetweenPoints) // before first point, do nothing
225 acco = accoMax;
226 else if (closestPoint == endPoint && secondaryPoint == points[points.Count() - 2] && distanceToSecondary > distanceBetweenPoints) // past second point, do nothing
227 acco = accoMin;
228 else // between the two points, lerp
229 {
230 if (closestPoint == endPoint)
231 secondaryPoint = points[points.Count() - 2];
232 else if (closestPoint == startPoint)
233 secondaryPoint = points[1];
234 else if (distanceBetweenPoints < distanceToClosest || distanceBetweenPoints < distanceToSecondary)
235 {
236 JsonUndergroundAreaBreadcrumb nexPoint = points[points.Find(closestPoint) + 1];
237 if (vector.DistanceSq(playerPos, nexPoint.GetPosition()) < vector.DistanceSq(closestPoint.GetPosition(), nexPoint.GetPosition()))
238 secondaryPoint = nexPoint;
239 else
240 {
241 acco = closestPoint.EyeAccommodation;
242 forceAcco = true;
243 }
244 }
245
246 if (!forceAcco)
247 {
248 distanceToSecondary = vector.DistanceSq(playerPos, secondaryPoint.GetPosition());
249
250 acco = distanceToSecondary / (distanceToClosest + distanceToSecondary); // progress
251 acco = Math.Lerp(secondaryPoint.EyeAccommodation, closestPoint.EyeAccommodation, acco);
252
253 if (points.Find(closestPoint) > points.Find(secondaryPoint))
254 m_LightingLerpTarget = closestPoint.LightLerp;
255 else
256 m_LightingLerpTarget = secondaryPoint.LightLerp;
257
258 }
259 }
260
262
264 {
265 if (m_LightingLerpTarget == 1)
266 {
268 m_AnimTimerLightBlend.Run(1, this, "OnUpdateTimerIn", "OnUpdateTimerEnd",0, false, LIGHT_BLEND_SPEED_IN);
269 }
270 else
271 {
273 m_AnimTimerLightBlend.Run(0, this, "OnUpdateTimerOut", "OnUpdateTimerEnd",m_LightingLerp, false, LIGHT_BLEND_SPEED_OUT);
274 }
275 }
276
277 #ifdef DIAG_DEVELOPER
278 if (DiagMenu.GetBool(DiagMenuIDs.UNDERGROUND_SHOW_BREADCRUMB))
279 {
280 Debug.DrawLine(m_Player.GetPosition() + "0 1 0", closestPoint.GetPosition(), COLOR_YELLOW, ShapeFlags.ONCE);
281 if (acco != accoMin && acco != accoMax)
282 Debug.DrawLine(closestPoint.GetPosition(), secondaryPoint.GetPosition(), COLOR_RED, ShapeFlags.ONCE);
283
284 DbgUI.Begin(String("Underground Areas"), 20, 20);
285 DbgUI.Text(String("Closest point id: " + points.Find(closestPoint)));
286 DbgUI.Text(String("Second closest id: " + points.Find(secondaryPoint)));
287 DbgUI.End();
288 }
289 #endif
290 }
291
292 protected void ProcessEyeAcco(float timeSlice)
293 {
295 bool reachedTarget = CalculateEyeAcco(timeSlice);
296 ApplyEyeAcco();
297 if(reachedTarget && !m_Player.m_UndergroundPresence)
298 {
299 GetRequester().Stop();
301 //m_NVRequester.SetUndergroundExposureCoef(1.0);
302 m_Player.KillUndergroundHandler();
303 }
304
305 }
306
307 protected void ProcessLighting(float timeSlice)
308 {
309 #ifdef DEVELOPER
310 if (!DiagMenu.GetBool(DiagMenuIDs.UNDERGROUND_DISABLE_DARKENING) )
311 {
313 }
314 else
315 {
317 }
318 #else
320 #endif
321 }
322
323 protected void ProcessSound(float timeSlice)
324 {
326 if (m_AmbientSound)
327 {
328 if (m_TransitionalTrigger && m_TransitionalTrigger.m_Data.Breadcrumbs.Count() >= 2)
329 m_AmbientSound.SetSoundVolume(1-m_EyeAcco);
330 }
331 }
332
333 void Tick(float timeSlice)
334 {
335 if (!m_Player.IsAlive())
336 return;
337
338 ProcessEyeAcco(timeSlice);
339 ProcessLighting(timeSlice);
340 ProcessSound(timeSlice);
341
342 #ifdef DIAG_DEVELOPER
343 if ( DiagMenu.GetBool(DiagMenuIDs.UNDERGROUND_SHOW_BREADCRUMB) )
344 {
345 DisplayDebugInfo(GetGame().GetWorld().GetEyeAccom(), m_LightingLerp);
346 }
347 #endif
348
349 }
350
351 protected void ApplyEyeAcco()
352 {
353 #ifdef DIAG_DEVELOPER
354 if (!DiagMenu.GetBool(DiagMenuIDs.UNDERGROUND_DISABLE_DARKENING) )
355 {
356 GetRequester().SetEyeAccommodation(m_EyeAcco);
357 }
358 else
359 {
360 GetRequester().SetEyeAccommodation(1);
361 }
362 #else
363 GetRequester().SetEyeAccommodation(m_EyeAcco);
364 #endif
365
366 float undergrounNVExposureCoef = m_EyeAcco;
367 if (m_LightingLerp >= 1.0 || GetDayZGame().GetWorld().IsNight())
368 {
369 undergrounNVExposureCoef = 1.0;
370 }
371 //m_NVRequester.SetUndergroundExposureCoef(undergrounNVExposureCoef);
372 UpdateNVGRequester(undergrounNVExposureCoef);
373 }
374
375 protected void UpdateNVGRequester(float value)
376 {
377 m_NVRequester.SetUndergroundExposureCoef(value);
378 }
379
380 protected bool CalculateEyeAcco(float timeSlice)
381 {
382 if (m_TransitionalTrigger || !m_Player.m_UndergroundPresence || (m_EyeAccoTarget == 1))
383 {
384 float accoDiff = m_EyeAccoTarget - m_EyeAcco;
385 float increase = accoDiff * m_AccoInterpolationSpeed * timeSlice;
386 m_EyeAcco += increase;
387 if (Math.AbsFloat(accoDiff) < 0.01)
388 {
390 return true;
391 }
392 }
393 else
394 {
396 }
397 return false;
398 }
399
400
401
402 protected void OnTriggerInsiderUpdate()
403 {
404 EUndergroundTriggerType bestType = EUndergroundTriggerType.UNDEFINED;
406 UndergroundTrigger bestTrigger;
407 m_EyeAccoTarget = 1;
409
410 foreach (auto t:m_InsideTriggers)
411 {
412 if (t.m_Type > bestType)
413 {
414 bestTrigger = t;
415 bestType = t.m_Type;
416 }
417 }
418 //Print(m_InsideTriggers.Count());
419 //Print(bestType);
420 if (bestTrigger)
421 {
422 if (bestTrigger.m_Type == EUndergroundTriggerType.TRANSITIONING)
423 {
424 m_TransitionalTrigger = bestTrigger;
425 }
426 m_EyeAccoTarget = bestTrigger.m_Accommodation;
427 if (bestTrigger.m_InterpolationSpeed != -1 && bestTrigger.m_InterpolationSpeed != 0)
428 m_AccoInterpolationSpeed = bestTrigger.m_InterpolationSpeed;
429 }
430
431 SetUndergroundPresence(bestTrigger);
432 }
433
434
435 protected void SetUndergroundPresence(UndergroundTrigger trigger)
436 {
438 EUndergroundPresence oldPresence = m_Player.m_UndergroundPresence;
439
440 if (trigger)
441 {
442 if (trigger.m_Type == EUndergroundTriggerType.OUTER)
443 {
444 newPresence = EUndergroundPresence.OUTER;
445 }
446 else if (trigger.m_Type == EUndergroundTriggerType.TRANSITIONING)
447 {
448 newPresence = EUndergroundPresence.TRANSITIONING;
449 }
450 else if (trigger.m_Type == EUndergroundTriggerType.INNER)
451 {
452 newPresence = EUndergroundPresence.FULL;
453 }
454 }
455
456 if (newPresence != oldPresence)//was there a change ?
457 {
458 OnUndergroundPresenceUpdate(newPresence,oldPresence);
459 m_Player.SetUnderground(newPresence);
460 }
461
462
463 }
464
465 protected void EnableLights(bool enable)
466 {
467 foreach (ScriptedLightBase light:ScriptedLightBase.m_NightTimeOnlyLights)
468 {
469 light.SetVisibleDuringDaylight(enable);
470 }
471 }
472
474
476 {
478 return;
479 float value01 = m_AnimTimerLightBlend.GetValue();
480 float result = Easing.EaseInQuint(value01);
481 m_LightingLerp = result;
482
483 }
484
486 {
488 return;
489 float value01 = m_AnimTimerLightBlend.GetValue();
490 float result = Easing.EaseOutCubic(value01);
491 m_LightingLerp = result;
492 }
493
494 protected void PlayAmbientSound()
495 {
496 if (m_TransitionalTrigger && m_TransitionalTrigger.m_Data.AmbientSoundType != string.Empty)
497 {
498 m_AmbientController = m_TransitionalTrigger.m_Data.AmbientSoundType;
499 SetSoundControllerOverride(m_AmbientController, 1.0, SoundControllerAction.Overwrite);
500 }
501 else
502 m_Player.PlaySoundSetLoop(m_AmbientSound, "Underground_SoundSet",3,3);
503 }
504
505 protected void StopAmbientSound()
506 {
507 if (m_AmbientController != string.Empty)
508 {
509 SetSoundControllerOverride(m_AmbientController, 0, SoundControllerAction.None);
510 m_AmbientController = string.Empty;
511 }
512 else if (m_AmbientSound)
513 m_Player.StopSoundSet(m_AmbientSound);
514 }
515
517 {
518 //Print("-----> On Undeground Presence update " + EnumTools.EnumToString(EUndergroundPresence, newPresence) + " " + EnumTools.EnumToString(EUndergroundPresence, oldPresence));
519 if (newPresence > EUndergroundPresence.NONE)
520 {
521 if (oldPresence == EUndergroundPresence.NONE)
522 {
523 EnableLights(true);
524 }
525 if (newPresence > EUndergroundPresence.OUTER && oldPresence <= EUndergroundPresence.OUTER)
526 {
529 }
530 if (newPresence == EUndergroundPresence.FULL)
531 {
533 m_AnimTimerLightBlend.Run(1, this, "OnUpdateTimerIn", "OnUpdateTimerEnd",0, false, LIGHT_BLEND_SPEED_IN);
534 }
535 }
536 if (newPresence < EUndergroundPresence.FULL && oldPresence == EUndergroundPresence.FULL)
537 {
539 m_AnimTimerLightBlend.Run(0, this, "OnUpdateTimerOut", "OnUpdateTimerEnd",m_LightingLerp, false, LIGHT_BLEND_SPEED_OUT);
540 }
541 if (newPresence <= EUndergroundPresence.OUTER && oldPresence > EUndergroundPresence.OUTER)
542 {
544 }
545 if (newPresence == EUndergroundPresence.NONE)
546 {
548
549 if (oldPresence >= EUndergroundPresence.OUTER)
550 {
552 EnableLights(false);
553 }
554 }
555 }
556
557 #ifdef DIAG_DEVELOPER
558 protected void DisplayDebugInfo(float acco, float lighting)
559 {
560 if (acco < 0.0001)
561 acco = 0;
562 DbgUI.Begin(String("Underground Areas"), 20, 20);
563 DbgUI.Text(String("Eye Accomodation: " + acco.ToString()));
564 DbgUI.Text(String("Lighting lerp: " + lighting.ToString()));
565 DbgUI.End();
566 }
567 #endif
568}
enum EWetnessLevel FULL
DayZGame GetDayZGame()
Определения DayZGame.c:3870
PhxInteractionLayers
Определения DayZPhysics.c:2
DiagMenuIDs
Определения EDiagMenuIDs.c:2
DayZPlayer m_Player
Определения Hand_Events.c:42
Empty
Определения Hand_States.c:14
void ProcessSound()
Определения HungerSoundHandler.c:28
PlayerBase GetPlayer()
Определения ModifierBase.c:51
void Tick()
Определения SoundEvents.c:107
bool CalculateEyeAcco(float timeSlice)
Определения UndergroundHandlerClient.c:380
void ApplyEyeAcco()
Определения UndergroundHandlerClient.c:351
void StopAmbientSound()
Определения UndergroundHandlerClient.c:505
void UndergroundHandlerClient(PlayerBase player)
Определения UndergroundHandlerClient.c:36
ref AnimationTimer m_AnimTimerLightBlend
Определения UndergroundHandlerClient.c:19
const float DEFAULT_INTERPOLATION_SPEED
Определения UndergroundHandlerClient.c:17
const float DISTANCE_CUTOFF
Определения UndergroundHandlerClient.c:15
void OnTriggerLeave(UndergroundTrigger trigger)
Определения UndergroundHandlerClient.c:72
string m_AmbientController
Определения UndergroundHandlerClient.c:31
UndergroundTrigger m_TransitionalTrigger
Определения UndergroundHandlerClient.c:34
PPERUndergroundAcco m_Requester
Определения UndergroundHandlerClient.c:22
void UpdateNVGRequester(float value)
Определения UndergroundHandlerClient.c:375
const float ACCO_MODIFIER
Определения UndergroundHandlerClient.c:16
void CalculateEyeAccoTarget()
Определения UndergroundHandlerClient.c:82
ref set< UndergroundTrigger > m_InsideTriggers
Определения UndergroundHandlerClient.c:24
enum EUndergroundPresence LIGHT_BLEND_SPEED_IN
PPERUndergroundAcco GetRequester()
Определения UndergroundHandlerClient.c:55
EffectSound m_AmbientSound
Определения UndergroundHandlerClient.c:32
void CalculateLinePointFade()
Определения UndergroundHandlerClient.c:180
void OnTriggerInsiderUpdate()
Определения UndergroundHandlerClient.c:402
void OnUpdateTimerEnd()
const float RATIO_CUTOFF
Определения UndergroundHandlerClient.c:14
float m_EyeAcco
Определения UndergroundHandlerClient.c:28
void CalculateBreadCrumbs()
Определения UndergroundHandlerClient.c:97
void ProcessLighting(float timeSlice)
Определения UndergroundHandlerClient.c:307
void EnableLights(bool enable)
Определения UndergroundHandlerClient.c:465
float m_LightingLerpTarget
Определения UndergroundHandlerClient.c:29
const float LIGHT_BLEND_SPEED_OUT
Определения UndergroundHandlerClient.c:12
void ~UndergroundHandlerClient()
Определения UndergroundHandlerClient.c:43
void OnUndergroundPresenceUpdate(EUndergroundPresence newPresence, EUndergroundPresence oldPresence)
Определения UndergroundHandlerClient.c:516
float m_EyeAccoTarget
Определения UndergroundHandlerClient.c:26
PPERequester_CameraNV m_NVRequester
Определения UndergroundHandlerClient.c:23
float m_AccoInterpolationSpeed
Определения UndergroundHandlerClient.c:27
void OnTriggerEnter(UndergroundTrigger trigger)
Определения UndergroundHandlerClient.c:65
void OnUpdateTimerIn()
Определения UndergroundHandlerClient.c:475
void OnUpdateTimerOut()
Определения UndergroundHandlerClient.c:485
void ProcessEyeAcco(float timeSlice)
Определения UndergroundHandlerClient.c:292
float m_LightingLerp
Определения UndergroundHandlerClient.c:30
const string UNDERGROUND_LIGHTING
Определения UndergroundHandlerClient.c:18
EUndergroundPresence
Определения UndergroundHandlerClient.c:2
@ TRANSITIONING
Определения UndergroundHandlerClient.c:5
@ OUTER
Определения UndergroundHandlerClient.c:4
void SetUndergroundPresence(UndergroundTrigger trigger)
Определения UndergroundHandlerClient.c:435
const float MAX_RATIO
Определения UndergroundHandlerClient.c:13
void PlayAmbientSound()
Определения UndergroundHandlerClient.c:494
AnimationTimer class. This timer is for animating float value. usage:
Определения tools.c:653
proto native World GetWorld()
proto native Weather GetWeather()
Returns weather controller object.
static proto bool RayCastBullet(vector begPos, vector endPos, PhxInteractionLayers layerMask, Object ignoreObj, out Object hitObject, out vector hitPosition, out vector hitNormal, out float hitFraction)
Определения DayZPhysics.c:124
Определения DbgUI.c:60
static Shape DrawSphere(vector pos, float size=1, int color=0x1fff7f7f, ShapeFlags flags=ShapeFlags.TRANSP|ShapeFlags.NOOUTLINE)
Определения Debug.c:319
static Shape DrawLine(vector from, vector to, int color=0xFFFFFFFF, int flags=0)
Определения Debug.c:382
Определения Debug.c:2
Определения EnDebug.c:233
static float EaseInQuint(float t)
Определения Easing.c:78
static float EaseOutCubic(float t)
Определения Easing.c:42
Input value between 0 and 1, returns value adjusted by easing, no automatic clamping of input(do your...
Определения Easing.c:3
Wrapper class for managing sound through SEffectManager.
Определения EffectSound.c:5
Определения EnMath.c:7
Определения ObjectTyped.c:2
Определения PlayerBaseClient.c:2
proto native void SuppressLightningSimulation(bool state)
enables/disables thunderbolt simulation on client (together with sounds)
proto native void SetExplicitVolumeFactor_EnvSounds2D(float factor, float fadeTime)
proto native void LoadUserLightingCfg(string path, string name)
proto native void SetUserLightingLerp(float val)
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
proto string ToString(bool simple=true)
static proto native float DistanceSq(vector v1, vector v2)
Returns the square distance between tips of two 3D vectors.
static proto native float Distance(vector v1, vector v2)
Returns the distance between tips of two 3D vectors.
Определения EnConvert.c:106
proto native CGame GetGame()
const int COLOR_RED
Определения constants.c:64
const int COLOR_YELLOW
Определения constants.c:67
ShapeFlags
Определения EnDebug.c:126
static proto native void End()
static proto native void Begin(string windowTitle, float x=0, float y=0)
static proto native void Text(string label)
static proto bool GetBool(int id, bool reverse=false)
Get value as bool from the given script id.
string String(string s)
Helper for passing string expression to functions with void parameter. Example: Print(String("Hello "...
Определения EnScript.c:339
static proto float Lerp(float a, float b, float time)
Linearly interpolates between 'a' and 'b' given 'time'.
static proto float AbsFloat(float f)
Returns absolute value.
@ NONE
No flags.
Определения EnProfiler.c:11
SetSoundControllerOverride(string controllerName, float value, SoundControllerAction action)
class JsonUndergroundAreaTriggerData GetPosition
Определения UndergroundAreaLoader.c:9
int ARGB(int a, int r, int g, int b)
Определения proto.c:322