Difference between revisions of "DCS enum world"

From DCS World Wiki - Hoggitworld.com
m (1 revision imported)
 
 
(One intermediate revision by the same user not shown)
Line 54: Line 54:
 
  15 = "S_EVENT_BIRTH"
 
  15 = "S_EVENT_BIRTH"
 
  16 = "S_EVENT_HUMAN_FAILURE"
 
  16 = "S_EVENT_HUMAN_FAILURE"
  17 = "S_EVENT_ENGINE_STARTUP"
+
  17 = "S_EVENT_DETAILED_FAILURE"
  18 = "S_EVENT_ENGINE_SHUTDOWN"
+
18 = "S_EVENT_ENGINE_STARTUP"
  19 = "S_EVENT_PLAYER_ENTER_UNIT"
+
  19 = "S_EVENT_ENGINE_SHUTDOWN"
  20 = "S_EVENT_PLAYER_LEAVE_UNIT"
+
  20 = "S_EVENT_PLAYER_ENTER_UNIT"
  21 = "S_EVENT_PLAYER_COMMENT"
+
  21 = "S_EVENT_PLAYER_LEAVE_UNIT"
  22 = "S_EVENT_SHOOTING_START"
+
  22 = "S_EVENT_PLAYER_COMMENT"
  23 = "S_EVENT_SHOOTING_END"
+
  23 = "S_EVENT_SHOOTING_START"
  24 = "S_EVENT_MAX'
+
  24 = "S_EVENT_SHOOTING_END"
 +
  25 = "S_EVENT_MARK_ADDED"
 +
26 = "S_EVENT_MARK_CHANGE"
 +
27 = "S_EVENT_MARK_REMOVED"
 +
28 = "S_EVENT_KILL"
 +
29 = "S_EVENT_SCORE"
 +
30 = "S_EVENT_UNIT_LOST"
 +
31 = "S_EVENT_LANDING_AFTER_EJECTION"
 +
32 = "S_EVENT_PARATROOPER_LENDING"
 +
33 = "S_EVENT_DISCARD_CHAIR_AFTER_EJECTION"
 +
34 = "S_EVENT_WEAPON_ADD"
 +
35 = "S_EVENT_TRIGGER_ZONE"
 +
36 = "S_EVENT_LANDING_QUALITY_MARK"
 +
37 = "S_EVENT_BDA"
 +
38 = "S_EVENT_MAX'
  
 
BirthPlace events are logged as.
 
BirthPlace events are logged as.

Latest revision as of 20:48, 17 June 2021

Scripting Root

Enumerator: world Added with: 1.2.0
Description: The world enumerator contains a listing of events that can occur within the simulator, birthplace that defines how an object was spawned, and the shapes used with the world.searchObjects function.

For each event see the pages for each event type

Event Types: shot, hit, takeoff, land, crash, ejection, refueling, dead, pilot_dead, base_captured, mission_start, mission_end, took_control, refueling_stop, birth, human_failure, detailed_failure, engine_startup, engine_shutdown, player_enter_unit, player_leave_unit, player_comment, shooting_start, shooting_end, mark_added, mark_change, mark_remove, kill, score, unit_lost, landing_after_ejection, discard_chair_after_ejection, weapon_add, landing_quality_mark

Uses:
Format: The world enumerator contains 3 nested tables of event, BirthPlace, and VolumeType. These tables are formatted in the following manner with indexes corresponding to their constant values.
world= {
  event= {
    S_EVENT_INVALID = 0,
    S_EVENT_SHOT = 1,
    S_EVENT_HIT = 2,
     ...
 },
  BirthPlace= {
   wsBirthPlace_Air,
   wsBirthPlace_RunWay,
   wsBirthPlace_Park,
   ...  
 },
  VolumeType= {
    SEGMENT,
    BOX,
    SPHERE,
    PYRAMID
 }, 
}
constants: Below is a full listing of the event types and their corresponding ids.
0 =  S_EVENT_INVALID"
1 = "S_EVENT_SHOT"
2 = "S_EVENT_HIT"
3 = "S_EVENT_TAKEOFF"
4 = "S_EVENT_LAND"
5 = "S_EVENT_CRASH"
6 = "S_EVENT_EJECTION"
7 = "S_EVENT_REFUELING"
8 = "S_EVENT_DEAD"
9 = "S_EVENT_PILOT_DEAD"
10 = "S_EVENT_BASE_CAPTURED"
11 = "S_EVENT_MISSION_START"
12 = "S_EVENT_MISSION_END"
13 = "S_EVENT_TOOK_CONTROL"
14 = "S_EVENT_REFUELING_STOP"
15 = "S_EVENT_BIRTH"
16 = "S_EVENT_HUMAN_FAILURE"
17 = "S_EVENT_DETAILED_FAILURE"
18 = "S_EVENT_ENGINE_STARTUP"
19 = "S_EVENT_ENGINE_SHUTDOWN"
20 = "S_EVENT_PLAYER_ENTER_UNIT"
21 = "S_EVENT_PLAYER_LEAVE_UNIT"
22 = "S_EVENT_PLAYER_COMMENT"
23 = "S_EVENT_SHOOTING_START"
24 = "S_EVENT_SHOOTING_END"
25 = "S_EVENT_MARK_ADDED"
26 = "S_EVENT_MARK_CHANGE"
27 = "S_EVENT_MARK_REMOVED"
28 = "S_EVENT_KILL"
29 = "S_EVENT_SCORE"
30 = "S_EVENT_UNIT_LOST"
31 = "S_EVENT_LANDING_AFTER_EJECTION"
32 = "S_EVENT_PARATROOPER_LENDING"
33 = "S_EVENT_DISCARD_CHAIR_AFTER_EJECTION"
34 = "S_EVENT_WEAPON_ADD"
35 = "S_EVENT_TRIGGER_ZONE"
36 = "S_EVENT_LANDING_QUALITY_MARK"
37 = "S_EVENT_BDA"
38 = "S_EVENT_MAX'

BirthPlace events are logged as.

1 = "wsBirthPlace_Air"
3 = "wsBirthPlace_Ship"
4 = "wsBirthPlace_RunWay"
5 = "wsBirthPlace_Park"
9 = "wsBirthPlace_Heliport_Hot"       
10 = "wsBirthPlace_Heliport_Cold"
11 = "wsBirthPlace_Ship_Cold"
12 = "wsBirthPlace_Ship_Hot"

VolumeType shapes are defined as:

0 = "SEGMENT"
1 = "BOX"
2 = "SPHERE"
3 = "PYRAMID"
notes: