DayZ 1.30
DayZ Explorer by KGB
 
Загрузка...
Поиск...
Не найдено

◆ PlayEffectData()

void VehicleVFXComponent::PlayEffectData ( notnull VehicleVFXData data,
EntityAI parent )
inlineprotected

cooldown guard - refuse to (re)start until the window elapses

do not play - mostly for dynamicaly created/placed particles

stamp the playback time so the cooldown guard starts counting

created only - start playback

stamp on restart too

См. определение в файле VehicleVFXComponent.c строка 171

172 {
174 if (!data.CanPlay())
175 return;
176
177 SurfaceInfo surfaceInfo = m_SurfaceInfo;
179 {
180 SurfaceDetectionParameters surfaceParams = new SurfaceDetectionParameters();
181 surfaceParams.syncMode = UseObjectsMode.NoLock;
182 SurfaceDetectionResult surfaceResult = new SurfaceDetectionResult();
183 surfaceParams.position = parent.GetPosition();
184 g_Game.GetSurface(surfaceParams, surfaceResult);
185 surfaceInfo = surfaceResult.surface;
186 }
187
188
189 if(data.m_EffectId == -1)
190 {
192 if (data.m_Position == "-1 -1 -1")
193 return;
194
195 data.m_Effect.ParticleParamsOverride(data.m_ParticleParamsData);
196 data.m_EffectId = SEffectManager.PlayOnObject(data.m_Effect, parent, data.m_Position, data.m_Orientation);
197
199 data.MarkPlayed();
200 }
201 else
202 {
204 if (!data.m_Effect.IsPlaying())
205 {
206 data.m_Effect.Start();
207 data.m_ParticleParamsData.ClearAll();
208
210 data.MarkPlayed();
211 }
212
213 data.m_Effect.SelectFromSurface(surfaceInfo);
214
215 Particle particle = Particle.Cast(data.m_Effect.GetParticle());
216 if (particle)
217 {
218 data.m_Effect.ParticleParamsOverride(data.m_ParticleParamsData);
219 }
220 }
221 }
DayZGame g_Game
Определения DayZGame.c:4074
UseObjectsMode
Определения SurfaceInfo.c:74
int[] SurfaceInfo
Определения SurfaceInfo.c:1
vector position
3D position to trace the surface from
Определения SurfaceInfo.c:100
UseObjectsMode syncMode
See UseObjectsMode, SurfaceTraceType.Roadway only.
Определения SurfaceInfo.c:106
SurfaceInfo surface
Returned SurfaceInfo, plain pointer.
Определения SurfaceInfo.c:134
SurfaceInfo m_SurfaceInfo
Определения VehicleVFXComponent.c:100
bool m_SurfaceInfoOverriden
Определения VehicleVFXComponent.c:98

Перекрестные ссылки g_Game, m_SurfaceInfo, m_SurfaceInfoOverriden, SEffectManager::PlayOnObject(), SurfaceDetectionParameters::position, SurfaceDetectionResult::surface и SurfaceDetectionParameters::syncMode.

Используется в PlayEffect() и PlayEffectGroup().