65enum PluginDayZCreatureAIDebugSyncMessageType
129 if (!
GetGame().IsDedicatedServer())
142 strVal = valInt.ToString();
174 strValType =
"float";
202 for (
int idxVar = 0; idxVar < toAddCount; idxVar++)
211 for (
int idxCmd = 0; idxCmd < toAddCount; idxCmd++)
256 #ifdef DIAG_DEVELOPER
257 creatureAI.DebugRestoreAIControl();
262 #ifdef DIAG_DEVELOPER
263 creatureAI.DebugDisableAIControl();
277 for (
int i=0; i < varCount; i++)
287 const int INPUT_BOX_SIZE = 35;
292 for (
int i=0; i < varCount; i++)
328 const int INPUT_BOX_SIZE = 35;
332 for (
int i=0; i < cmdCount; i++)
371 bool buttonPressed =
false;
403 const int panelMinSizeX = 350;
408 for (
int tagIdx = 0; tagIdx <
m_EntityAnimDbg.m_AnimTags.Count(); ++tagIdx)
416 string strPredictions;
417 for (
int predIdx = 0; predIdx <
m_EntityAnimDbg.m_AnimPredictions.Count(); ++predIdx)
420 strPredictions +=
", ";
441 const int evDisplayCount = 15;
444 for (
int evIdx = 0; evIdx < evToDisplayCount; ++evIdx)
501 #ifdef _DAYZ_CREATURE_DEBUG_SHADOW
502 if (!
GetGame().IsMultiplayer())
507 GUIAction_CreateShadow();
512 if (!
GetGame().IsMultiplayer())
514 const int simLODInputSize = 20;
524 if (btnReleasePressed)
585 m_TickTimer.Run(0.1,
this,
"OnGUITimer", NULL,
true);
600 const float MAX_RAYCAST_RANGE = 1000;
608 vector to = pos + (dir * MAX_RAYCAST_RANGE);
611 int contact_component;
612 set<Object> objects =
new set<Object>;
616 for (
int i = 0; i < objects.Count(); i++ )
618 Object obj = objects.Get(i);
643 #ifdef _DAYZ_CREATURE_DEBUG_SHADOW
644 void GUIAction_CreateShadow()
670 int intValue = strVal.
ToInt();
681 float floatValue = strVal.
ToFloat();
753 Param1<int> paramCount =
new Param1<int>(count);
764 if (rpc_type ==
ERPCs.DEV_RPC_PLUGIN_DZCREATURE_DEBUG)
772 Param1<int> count =
new Param1<int>(0);
776 Param1<int> type =
new Param1<int>(PluginDayZCreatureAIDebugSyncMessageType.COUNT);
777 for (
int i=0; i < count.param1; ++i)
783 case PluginDayZCreatureAIDebugSyncMessageType.INIT_DEBUG_OBJECT:
786 case PluginDayZCreatureAIDebugSyncMessageType.RELEASE_DEBUG_OBJECT:
789 case PluginDayZCreatureAIDebugSyncMessageType.SET_VALUE_INT:
792 case PluginDayZCreatureAIDebugSyncMessageType.SET_VALUE_FLOAT:
795 case PluginDayZCreatureAIDebugSyncMessageType.SET_VALUE_BOOL:
798 case PluginDayZCreatureAIDebugSyncMessageType.ACTIVATE_COMMAND:
801 case PluginDayZCreatureAIDebugSyncMessageType.ENABLE_AI:
804 case PluginDayZCreatureAIDebugSyncMessageType.DISABLE_AI:
809 type.param1 = PluginDayZCreatureAIDebugSyncMessageType.COUNT;
816 Param1<int> type =
new Param1<int>(PluginDayZCreatureAIDebugSyncMessageType.INIT_DEBUG_OBJECT);
817 Param1<Object>
object =
new Param1<Object>(obj);
825 Param1<Object>
object =
new Param1<Object>(NULL);
826 if (ctx.
Read(
object))
834 Param1<int> type =
new Param1<int>(PluginDayZCreatureAIDebugSyncMessageType.RELEASE_DEBUG_OBJECT);
846 Param1<int> type =
new Param1<int>(PluginDayZCreatureAIDebugSyncMessageType.SET_VALUE_INT);
857 if (ctx.
Read(paramValue))
865 Param1<int> type =
new Param1<int>(PluginDayZCreatureAIDebugSyncMessageType.SET_VALUE_FLOAT);
876 if (ctx.
Read(paramValue))
884 Param1<int> type =
new Param1<int>(PluginDayZCreatureAIDebugSyncMessageType.SET_VALUE_BOOL);
895 if (ctx.
Read(paramValue))
903 Param1<int> type =
new Param1<int>(PluginDayZCreatureAIDebugSyncMessageType.ACTIVATE_COMMAND);
914 if (ctx.
Read(command))
922 Param1<int> type =
new Param1<int>(PluginDayZCreatureAIDebugSyncMessageType.COUNT);
925 type.param1 = PluginDayZCreatureAIDebugSyncMessageType.ENABLE_AI;
929 type.param1 = PluginDayZCreatureAIDebugSyncMessageType.DISABLE_AI;
DayZCreatureAnimScriptDebugVarType
ref array< bool > m_SetCommandCheckStates
Param4< float, string, int, string > DayZCreatureAnimScriptDebugAnimEventData
class DayZCreatureAnimScriptDebug SET_VALUE_INT
ref DayZCreatureAnimScriptDebug m_EntityAnimDbg
string GetStrValueType(int index)
Param1< string > DayZCreatureAnimScriptDebugAnimPredictionData
class DayZCreatureAnimScriptDebug ACTIVATE_COMMAND
void SyncReceiveDisableAI(ParamsReadContext ctx)
void PluginDayZCreatureAIDebug()
class DayZCreatureAnimScriptDebug INIT_DEBUG_OBJECT
void GUIAction_ActivateCommand(int commandIdx, int userInt, float userFloat)
Param1< string > DayZCreatureAnimScriptDebugAnimTagData
void SyncSetValueBool(int index, bool value)
class DayZCreatureAnimScriptDebug SET_VALUE_BOOL
void OnRpc(PlayerBase player, int rpc_type, ParamsReadContext ctx)
string GetStrValue(int index)
class DayZCreatureAnimScriptDebug RELEASE_DEBUG_OBJECT
void SetDebugShowMode(int mode)
void SetValueInt(int index, int value)
void ActivateCommand(int commandIdx, int userInt, float userFloat)
void ~PluginDayZCreatureAIDebug()
void GUIAction_InitDebugObject(Object obj)
void SyncSetValueInt(int index, int value)
void GUIAction_SetValue(int index, string strVal)
void SetValueFloat(int index, float value)
DayZCreatureAI m_DebugEntity
void EnableAI(bool enable)
void SetValueBool(int index, bool value)
void SyncInitDebugObject(Object obj)
class DayZCreatureAnimScriptDebug SET_VALUE_FLOAT
void SyncReceiveInitDebugObject(ParamsReadContext ctx)
class DayZCreatureAnimScriptDebug ENABLE_AI
class DayZCreatureAnimScriptDebug m_iDebugMenu
DayZCreatureAnimScriptDebugVarType GetVariableType(int index)
void ReleaseDebugObject()
void SyncEnableAI(bool enable)
void SyncReceiveReleaseDebugObject(ParamsReadContext ctx)
void OnGUI_VariablesEdit()
void SyncReceiveEnableAI(ParamsReadContext ctx)
void InitDebugObject(Object obj)
void SyncActivateCommand(int commandIdx, int userInt, float userFloat)
void OnGUI_CommandsEdit()
string m_sDebugEntityName
void SyncReceiveValueInt(ParamsReadContext ctx)
void GUIAction_UpdateSimulationPrecision(int simLOD)
void GUIAction_ReleaseDebugObject()
void OnGUI_AIControlEdit()
void SyncReceiveValueFloat(ParamsReadContext ctx)
void SyncReceiveMessage(ParamsReadContext ctx)
void SyncReleaseDebugObject()
ref array< ref Param > m_SyncMessages
ref array< bool > m_SetVariableCheckStates
void SyncReceiveValueBool(ParamsReadContext ctx)
void SyncReceiveActivateCommand(ParamsReadContext ctx)
void GUIAction_EnableAI(bool enable)
void SyncSetValueFloat(int index, float value)
class DayZCreatureAnimScriptDebug DISABLE_AI
class PresenceNotifierNoiseEvents windowPosX
dbgUI settings
proto native Object CreateObject(string type, vector pos, bool create_local=false, bool init_ai=false, bool create_physics=true)
Creates object of certain type.
proto native vector GetPointerDirection()
Returns the direction where the mouse points, from the camera view.
proto native DayZPlayer GetPlayer()
proto native vector GetCurrentCameraPosition()
do not process rotations !
proto native int GetVariableType(int index)
proto native owned string GetVariableName(int index)
proto native float GetVariableFloat(int index)
void OnAnimationTag(string tagName)
void OnAnimationEventsStart()
proto native int GetVariableInt(int index)
ref array< ref DayZCreatureAnimScriptDebugAnimEventData > m_AnimEvents
proto native bool SetVariableBool(int index, bool value)
proto native int SetVariableInt(int index, int value)
proto native owned string GetCommandName(int index)
proto native int GetCommandCount()
ref array< ref DayZCreatureAnimScriptDebugAnimTagData > m_AnimTags
proto native void ActivateCommand(int index, int userInt, float userFloat)
ref array< string > m_EventsFilter
void OnAnimationPrediction(string predName)
proto native void SetCreature(DayZCreature creature)
const int m_iMaxAnimEventsCount
proto native bool GetVariableBool(int index)
proto native int GetCommandID(int index)
void OnAnimationEvent(string evType, int userInt, string userString)
proto native float SetVariableFloat(int index, float value)
ref array< ref DayZCreatureAnimScriptDebugAnimPredictionData > m_AnimPredictions
proto native int GetVariableCount()
static proto bool RaycastRV(vector begPos, vector endPos, out vector contactPos, out vector contactDir, out int contactComponent, set< Object > results=NULL, Object with=NULL, Object ignore=NULL, bool sorted=false, bool ground_only=false, int iType=ObjIntersectView, float radius=0.0, CollisionFlags flags=CollisionFlags.NEARESTCONTACT)
Raycasts world by given parameters.
proto bool Read(void value_in)
Result for an object found in CGame.IsBoxCollidingGeometryProxy.
proto string ToString(bool simple=true)
Serializer ParamsReadContext
proto native CGame GetGame()
static proto native void Panel(string label, int width, int height, int color=0xaa555555)
static proto native void End()
static proto native void Begin(string windowTitle, float x=0, float y=0)
static proto native void PopID()
static proto native bool Button(string txt, int minWidth=0)
static proto native void Text(string label)
static proto void InputText(string txt, out string value, int pxWidth=150)
static proto native void SameLine()
static proto void InputInt(string txt, out int value, int pxWidth=150)
static proto void BeginCleanupScope()
static proto native void PushID_Int(int int_id)
static proto native void Spacer(int height)
static proto native void PushID_Str(string str_id)
static proto void Check(string label, out bool checked)
static proto native void EndCleanupScope()
static proto float Min(float x, float y)
Returns smaller of two given values.
proto native int ToInt()
Converts string to integer.
bool Contains(string sample)
Returns true if sample is substring of string.
proto native float ToFloat()
Converts string to float.
void Split(string sample, out array< string > output)
Splits string into array of strings separated by 'sample'.
proto int ToLower()
Changes string to lowercase. Returns length.
proto native float GetWorldTime()