warscript 0.0.1-dev.d1328b7 → 0.0.1-dev.d1499df
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/attributes.d.ts +6 -0
- package/attributes.lua +17 -1
- package/config.d.ts +5 -0
- package/config.lua +10 -0
- package/core/types/effect.d.ts +14 -6
- package/core/types/effect.lua +131 -35
- package/core/types/frame.d.ts +3 -0
- package/core/types/frame.lua +83 -21
- package/core/types/player.d.ts +15 -0
- package/core/types/player.lua +56 -14
- package/core/types/playerCamera.d.ts +2 -0
- package/core/types/playerCamera.lua +123 -5
- package/core/types/sound.d.ts +17 -24
- package/core/types/sound.lua +99 -24
- package/core/types/tileCell.d.ts +11 -1
- package/core/types/tileCell.lua +97 -0
- package/core/types/timer.d.ts +9 -8
- package/core/types/timer.lua +45 -23
- package/core/util.d.ts +1 -1
- package/core/util.lua +12 -1
- package/decl/native.d.ts +846 -790
- package/engine/behavior.d.ts +5 -0
- package/engine/behavior.lua +106 -27
- package/engine/behaviour/ability/always-enabled.d.ts +7 -0
- package/engine/behaviour/ability/always-enabled.lua +31 -0
- package/engine/behaviour/ability/apply-buff.d.ts +5 -0
- package/engine/behaviour/ability/apply-buff.lua +32 -0
- package/engine/behaviour/ability/apply-unit-behavior.lua +1 -0
- package/engine/behaviour/ability/damage.d.ts +9 -3
- package/engine/behaviour/ability/damage.lua +26 -38
- package/engine/behaviour/ability/emulate-impact.d.ts +6 -0
- package/engine/behaviour/ability/emulate-impact.lua +43 -0
- package/engine/behaviour/ability/instant-impact.d.ts +2 -2
- package/engine/behaviour/ability/instant-impact.lua +4 -19
- package/engine/behaviour/ability/on-command-impact.d.ts +8 -0
- package/engine/behaviour/ability/on-command-impact.lua +25 -0
- package/engine/behaviour/ability/remove-buffs.d.ts +25 -0
- package/engine/behaviour/ability/remove-buffs.lua +49 -0
- package/engine/behaviour/ability/restore-mana.d.ts +1 -1
- package/engine/behaviour/ability/restore-mana.lua +6 -6
- package/engine/behaviour/ability.d.ts +20 -4
- package/engine/behaviour/ability.lua +111 -47
- package/engine/behaviour/unit/stun-immunity.d.ts +7 -3
- package/engine/behaviour/unit/stun-immunity.lua +52 -27
- package/engine/behaviour/unit.d.ts +34 -0
- package/engine/behaviour/unit.lua +190 -4
- package/engine/buff.d.ts +72 -45
- package/engine/buff.lua +357 -241
- package/engine/internal/ability.d.ts +20 -3
- package/engine/internal/ability.lua +126 -13
- package/engine/internal/item/ability.lua +162 -4
- package/engine/internal/item+owner.lua +12 -6
- package/engine/internal/item.d.ts +20 -19
- package/engine/internal/item.lua +191 -74
- package/engine/internal/mechanics/ability-duration.lua +1 -1
- package/engine/internal/misc/ability-disable-counter.d.ts +2 -0
- package/engine/internal/misc/ability-disable-counter.lua +13 -0
- package/engine/internal/misc/damage-metadata-by-target.d.ts +2 -0
- package/engine/internal/misc/damage-metadata-by-target.lua +5 -0
- package/engine/internal/misc/frame-coordinates.d.ts +2 -0
- package/engine/internal/misc/frame-coordinates.lua +21 -0
- package/engine/internal/misc/get-terrain-z.d.ts +2 -0
- package/engine/internal/misc/get-terrain-z.lua +11 -0
- package/engine/internal/misc/player-local-handle.d.ts +2 -0
- package/engine/internal/misc/player-local-handle.lua +5 -0
- package/engine/internal/object-data/auto-attack-speed-increase.d.ts +1 -1
- package/engine/internal/object-data/auto-attack-speed-increase.lua +2 -0
- package/engine/internal/object-data/evasion-probability.d.ts +2 -0
- package/engine/internal/object-data/evasion-probability.lua +16 -0
- package/engine/internal/unit/ability.d.ts +45 -1
- package/engine/internal/unit/ability.lua +128 -17
- package/engine/internal/unit/add-item-to-slot-init.d.ts +2 -0
- package/engine/internal/unit/add-item-to-slot-init.lua +23 -0
- package/engine/internal/unit/add-item-to-slot.d.ts +2 -0
- package/engine/internal/unit/add-item-to-slot.lua +52 -0
- package/engine/internal/unit/allowed-targets.d.ts +1 -1
- package/engine/internal/unit/allowed-targets.lua +9 -1
- package/engine/internal/unit/bonus.d.ts +2 -0
- package/engine/internal/unit/bonus.lua +17 -0
- package/engine/internal/unit/fly-height.d.ts +7 -0
- package/engine/internal/unit/fly-height.lua +20 -0
- package/engine/internal/unit/ignore-events-items.d.ts +2 -0
- package/engine/internal/unit/ignore-events-items.lua +5 -0
- package/engine/internal/unit/item.d.ts +1 -0
- package/engine/internal/unit/item.lua +8 -4
- package/engine/internal/unit/main-selected.d.ts +6 -0
- package/engine/internal/unit/main-selected.lua +18 -22
- package/engine/internal/unit/order.d.ts +20 -0
- package/engine/internal/unit/order.lua +136 -0
- package/engine/internal/unit+ability.lua +10 -1
- package/engine/internal/unit+damage.d.ts +2 -11
- package/engine/internal/unit+damage.lua +10 -14
- package/engine/internal/unit+spellSteal.lua +1 -2
- package/engine/internal/unit-missile-launch.lua +45 -14
- package/engine/internal/unit.d.ts +50 -15
- package/engine/internal/unit.lua +413 -170
- package/engine/internal/utility.lua +12 -0
- package/engine/lightning.d.ts +12 -5
- package/engine/lightning.lua +48 -14
- package/engine/local-client.d.ts +2 -0
- package/engine/local-client.lua +30 -0
- package/engine/object-data/auxiliary/animation-name.d.ts +1 -0
- package/engine/object-data/auxiliary/animation-name.lua +16 -0
- package/engine/object-data/auxiliary/armor-type.d.ts +11 -0
- package/engine/object-data/auxiliary/armor-type.lua +46 -0
- package/engine/object-data/auxiliary/attachment-preset.d.ts +7 -2
- package/engine/object-data/auxiliary/attachment-preset.lua +4 -3
- package/engine/object-data/auxiliary/attack-type.d.ts +7 -8
- package/engine/object-data/auxiliary/attack-type.lua +42 -0
- package/engine/object-data/auxiliary/movement-type.d.ts +7 -7
- package/engine/object-data/auxiliary/movement-type.lua +22 -0
- package/engine/object-data/auxiliary/sound-eax.d.ts +10 -0
- package/engine/object-data/auxiliary/sound-eax.lua +2 -0
- package/engine/object-data/auxiliary/sound-preset-name.d.ts +5 -1
- package/engine/object-data/auxiliary/tech-tree-dependency.d.ts +1 -1
- package/engine/object-data/auxiliary/unit-attribute.d.ts +6 -0
- package/engine/object-data/auxiliary/unit-attribute.lua +9 -0
- package/engine/object-data/entry/ability-type/berserk.d.ts +2 -0
- package/engine/object-data/entry/ability-type/berserk.lua +13 -0
- package/engine/object-data/entry/ability-type/blank-configurable.lua +12 -1
- package/engine/object-data/entry/ability-type/carrion-swarm.d.ts +14 -0
- package/engine/object-data/entry/ability-type/carrion-swarm.lua +65 -0
- package/engine/object-data/entry/ability-type/disease-cloud.lua +2 -2
- package/engine/object-data/entry/ability-type/engineering-upgrade.lua +2 -2
- package/engine/object-data/entry/ability-type/ensnare.d.ts +12 -0
- package/engine/object-data/entry/ability-type/ensnare.lua +52 -0
- package/engine/object-data/entry/ability-type/feral-spirit.lua +2 -2
- package/engine/object-data/entry/ability-type/permanent-invisibility.d.ts +8 -0
- package/engine/object-data/entry/ability-type/permanent-invisibility.lua +26 -0
- package/engine/object-data/entry/ability-type/phase-shift.d.ts +10 -0
- package/engine/object-data/entry/ability-type/phase-shift.lua +39 -0
- package/engine/object-data/entry/ability-type/phoenix-morph.lua +4 -4
- package/engine/object-data/entry/ability-type/raise-dead.d.ts +17 -0
- package/engine/object-data/entry/ability-type/raise-dead.lua +78 -0
- package/engine/object-data/entry/ability-type/shock-wave.d.ts +4 -0
- package/engine/object-data/entry/ability-type/shock-wave.lua +26 -0
- package/engine/object-data/entry/ability-type/slow-poison.d.ts +10 -0
- package/engine/object-data/entry/ability-type/slow-poison.lua +58 -0
- package/engine/object-data/entry/ability-type/summon-quilbeast.lua +2 -2
- package/engine/object-data/entry/ability-type/summon-water-elemental.lua +2 -2
- package/engine/object-data/entry/ability-type/web.d.ts +12 -0
- package/engine/object-data/entry/ability-type/web.lua +52 -0
- package/engine/object-data/entry/ability-type.d.ts +19 -17
- package/engine/object-data/entry/ability-type.lua +93 -36
- package/engine/object-data/entry/buff-type/applicable.lua +18 -37
- package/engine/object-data/entry/buff-type.d.ts +6 -12
- package/engine/object-data/entry/buff-type.lua +13 -29
- package/engine/object-data/entry/destructible-type.d.ts +1 -1
- package/engine/object-data/entry/item-type.d.ts +3 -1
- package/engine/object-data/entry/item-type.lua +15 -2
- package/engine/object-data/entry/lightning-type.d.ts +1 -1
- package/engine/object-data/entry/sound-preset.d.ts +33 -0
- package/engine/object-data/entry/sound-preset.lua +140 -0
- package/engine/object-data/entry/unit-type.d.ts +21 -5
- package/engine/object-data/entry/unit-type.lua +214 -93
- package/engine/object-data/entry/upgrade.d.ts +1 -1
- package/engine/object-data/entry/upgrade.lua +4 -4
- package/engine/object-data/entry.d.ts +16 -14
- package/engine/object-data/entry.lua +60 -32
- package/engine/object-data/utility/object-data-entry-id-generator.lua +7 -0
- package/engine/object-field/ability.d.ts +12 -6
- package/engine/object-field/ability.lua +8 -4
- package/engine/object-field/unit.d.ts +61 -3
- package/engine/object-field/unit.lua +220 -7
- package/engine/object-field.d.ts +23 -6
- package/engine/object-field.lua +303 -114
- package/engine/random.d.ts +9 -0
- package/engine/random.lua +13 -0
- package/engine/standard/entries/buff-type.d.ts +3 -0
- package/engine/standard/entries/buff-type.lua +3 -0
- package/engine/standard/entries/sound-preset.d.ts +10 -0
- package/engine/standard/entries/sound-preset.lua +10 -0
- package/engine/standard/fields/ability.d.ts +2 -0
- package/engine/standard/fields/ability.lua +2 -0
- package/engine/standard/fields/unit.d.ts +5 -0
- package/engine/standard/fields/unit.lua +9 -0
- package/engine/synchronization.d.ts +11 -0
- package/engine/synchronization.lua +77 -0
- package/engine/text-tag.d.ts +36 -2
- package/engine/text-tag.lua +250 -10
- package/engine/unit.d.ts +3 -0
- package/engine/unit.lua +3 -0
- package/net/socket.lua +1 -1
- package/objutil/buff.lua +2 -3
- package/objutil/unit.lua +8 -0
- package/package.json +2 -2
- package/patch-lualib.lua +1 -1
- package/utility/arrays.d.ts +10 -1
- package/utility/arrays.lua +45 -3
- package/utility/callback-array.d.ts +17 -0
- package/utility/callback-array.lua +61 -0
- package/utility/functions.d.ts +8 -0
- package/utility/functions.lua +13 -0
- package/utility/lazy.d.ts +2 -0
- package/utility/lazy.lua +14 -0
- package/utility/linked-set.d.ts +2 -0
- package/utility/linked-set.lua +22 -1
- package/utility/lua-maps.d.ts +15 -2
- package/utility/lua-maps.lua +53 -2
- package/utility/lua-sets.d.ts +2 -0
- package/utility/lua-sets.lua +7 -0
- package/utility/reflection.lua +11 -7
- package/utility/types.d.ts +3 -0
- package/core/types/order.d.ts +0 -25
- package/core/types/order.lua +0 -55
package/engine/object-field.lua
CHANGED
|
@@ -20,6 +20,15 @@ local extractObjectDataEntryLevelFieldValue = ____entry.extractObjectDataEntryLe
|
|
|
20
20
|
local ObjectDataEntry = ____entry.ObjectDataEntry
|
|
21
21
|
local ____object_2Ddata_2Dentry_2Did_2Dgenerator = require("engine.object-data.utility.object-data-entry-id-generator")
|
|
22
22
|
local ObjectDataEntryIdGenerator = ____object_2Ddata_2Dentry_2Did_2Dgenerator.ObjectDataEntryIdGenerator
|
|
23
|
+
local ____linked_2Dset = require("utility.linked-set")
|
|
24
|
+
local mutableLinkedSet = ____linked_2Dset.mutableLinkedSet
|
|
25
|
+
local ____lua_2Dmaps = require("utility.lua-maps")
|
|
26
|
+
local emptyLuaMap = ____lua_2Dmaps.emptyLuaMap
|
|
27
|
+
local getOrPut = ____lua_2Dmaps.getOrPut
|
|
28
|
+
local mutableLuaMap = ____lua_2Dmaps.mutableLuaMap
|
|
29
|
+
local mutableWeakLuaMap = ____lua_2Dmaps.mutableWeakLuaMap
|
|
30
|
+
local ____arrays = require("utility.arrays")
|
|
31
|
+
local emptyArray = ____arrays.emptyArray
|
|
23
32
|
local compiletimeDefaultValueByObjectDataEntryIdByObjectFieldId = {}
|
|
24
33
|
local defaultValueByObjectDataEntryIdByObjectFieldId = postcompile(function() return compiletimeDefaultValueByObjectDataEntryIdByObjectFieldId end)
|
|
25
34
|
local objectFieldById = {}
|
|
@@ -29,7 +38,11 @@ local idGenerator = __TS__New(
|
|
|
29
38
|
)
|
|
30
39
|
local ObjectFieldBase = __TS__Class()
|
|
31
40
|
ObjectFieldBase.name = "ObjectFieldBase"
|
|
32
|
-
function ObjectFieldBase.prototype.____constructor(self, id)
|
|
41
|
+
function ObjectFieldBase.prototype.____constructor(self, id, isGlobal)
|
|
42
|
+
if isGlobal == nil then
|
|
43
|
+
isGlobal = false
|
|
44
|
+
end
|
|
45
|
+
self.isGlobal = isGlobal
|
|
33
46
|
self.valueByInstance = setmetatable({}, {__mode = "k"})
|
|
34
47
|
if objectFieldById[id] ~= nil then
|
|
35
48
|
error(
|
|
@@ -46,10 +59,15 @@ end
|
|
|
46
59
|
function ObjectFieldBase.prototype.supports(self, instance)
|
|
47
60
|
return __TS__InstanceOf(instance, self.instanceClass)
|
|
48
61
|
end
|
|
49
|
-
function ObjectFieldBase.
|
|
62
|
+
function ObjectFieldBase.prototype.hasValue(self, objectDataEntryId)
|
|
63
|
+
local defaultValueByObjectDataEntryId = defaultValueByObjectDataEntryIdByObjectFieldId[self.id]
|
|
64
|
+
return self.isGlobal or defaultValueByObjectDataEntryId ~= nil and defaultValueByObjectDataEntryId[objectDataEntryId] ~= nil or self:hasNativeFieldValue(objectDataEntryId)
|
|
65
|
+
end
|
|
66
|
+
function ObjectFieldBase.create(self, id, isGlobal)
|
|
50
67
|
return __TS__New(
|
|
51
68
|
self,
|
|
52
|
-
id or idGenerator:next()
|
|
69
|
+
id or idGenerator:next(),
|
|
70
|
+
isGlobal
|
|
53
71
|
)
|
|
54
72
|
end
|
|
55
73
|
function ObjectFieldBase.of(self, id)
|
|
@@ -71,7 +89,7 @@ ____exports.ObjectField = __TS__Class()
|
|
|
71
89
|
local ObjectField = ____exports.ObjectField
|
|
72
90
|
ObjectField.name = "ObjectField"
|
|
73
91
|
__TS__ClassExtends(ObjectField, ObjectFieldBase)
|
|
74
|
-
function ObjectField.prototype.getValue(self, entry)
|
|
92
|
+
function ObjectField.prototype.getValue(self, entry, includeModifiers)
|
|
75
93
|
if __TS__InstanceOf(entry, ObjectDataEntry) then
|
|
76
94
|
local defaultValueByObjectDataEntryId = (warpack.compiletime and compiletimeDefaultValueByObjectDataEntryIdByObjectFieldId or defaultValueByObjectDataEntryIdByObjectFieldId)[self.id]
|
|
77
95
|
if defaultValueByObjectDataEntryId ~= nil then
|
|
@@ -82,22 +100,16 @@ function ObjectField.prototype.getValue(self, entry)
|
|
|
82
100
|
end
|
|
83
101
|
return self.defaultValue
|
|
84
102
|
end
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
____self_valueByInstance_entry_0 = defaultValue
|
|
103
|
+
if includeModifiers == false then
|
|
104
|
+
local originalValueByInstance = self.originalValueByInstance
|
|
105
|
+
if originalValueByInstance ~= nil then
|
|
106
|
+
local originalValue = originalValueByInstance[entry]
|
|
107
|
+
if originalValue ~= nil then
|
|
108
|
+
return originalValue
|
|
92
109
|
end
|
|
93
|
-
return ____self_valueByInstance_entry_0
|
|
94
110
|
end
|
|
95
111
|
end
|
|
96
|
-
|
|
97
|
-
if ____temp_1 == nil then
|
|
98
|
-
____temp_1 = self.defaultValue
|
|
99
|
-
end
|
|
100
|
-
return ____temp_1
|
|
112
|
+
return self:getActualValue(entry)
|
|
101
113
|
end
|
|
102
114
|
function ObjectField.prototype.setValue(self, entry, value)
|
|
103
115
|
if __TS__InstanceOf(entry, ObjectDataEntry) then
|
|
@@ -112,37 +124,59 @@ function ObjectField.prototype.setValue(self, entry, value)
|
|
|
112
124
|
defaultValueByObjectDataEntryId[entry.id] = value
|
|
113
125
|
return true
|
|
114
126
|
end
|
|
115
|
-
local
|
|
116
|
-
if
|
|
117
|
-
local
|
|
118
|
-
if
|
|
119
|
-
local
|
|
120
|
-
if
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
local ____self_valueByInstance_entry_2_3 = ____self_valueByInstance_entry_2
|
|
124
|
-
if ____self_valueByInstance_entry_2_3 == nil then
|
|
125
|
-
____self_valueByInstance_entry_2_3 = self.defaultValue
|
|
126
|
-
end
|
|
127
|
-
local previousValue = ____self_valueByInstance_entry_2_3
|
|
128
|
-
if value ~= previousValue then
|
|
129
|
-
self.valueByInstance[entry] = value
|
|
130
|
-
self:invokeValueChangeEvent(entry, self, previousValue, value)
|
|
127
|
+
local modifiersByInstance = self.modifiersByInstance
|
|
128
|
+
if modifiersByInstance ~= nil then
|
|
129
|
+
local modifiers = modifiersByInstance[entry]
|
|
130
|
+
if modifiers ~= nil and modifiers.size ~= 0 then
|
|
131
|
+
local originalValueByInstance = self.originalValueByInstance
|
|
132
|
+
if originalValueByInstance == nil then
|
|
133
|
+
originalValueByInstance = mutableWeakLuaMap()
|
|
134
|
+
self.originalValueByInstance = originalValueByInstance
|
|
131
135
|
end
|
|
132
|
-
|
|
136
|
+
originalValueByInstance[entry] = value
|
|
137
|
+
value = self:calculateActualValue(entry)
|
|
133
138
|
end
|
|
134
139
|
end
|
|
135
|
-
|
|
136
|
-
|
|
140
|
+
return self:setActualValue(entry, value)
|
|
141
|
+
end
|
|
142
|
+
function ObjectField.prototype.applyModifier(self, instance, modifier)
|
|
143
|
+
local modifiersByInstance = self.modifiersByInstance
|
|
144
|
+
if modifiersByInstance == nil then
|
|
145
|
+
modifiersByInstance = mutableWeakLuaMap()
|
|
146
|
+
self.modifiersByInstance = modifiersByInstance
|
|
147
|
+
end
|
|
148
|
+
if getOrPut(modifiersByInstance, instance, mutableLinkedSet):add(modifier) then
|
|
149
|
+
local originalValueByInstance = self.originalValueByInstance
|
|
150
|
+
if originalValueByInstance == nil then
|
|
151
|
+
originalValueByInstance = mutableWeakLuaMap()
|
|
152
|
+
self.originalValueByInstance = originalValueByInstance
|
|
153
|
+
end
|
|
154
|
+
local ____originalValueByInstance_1 = originalValueByInstance
|
|
155
|
+
local ____instance_2 = instance
|
|
156
|
+
local ____originalValueByInstance_instance_0 = originalValueByInstance[instance]
|
|
157
|
+
if ____originalValueByInstance_instance_0 == nil then
|
|
158
|
+
____originalValueByInstance_instance_0 = self:getActualValue(instance)
|
|
159
|
+
end
|
|
160
|
+
____originalValueByInstance_1[____instance_2] = ____originalValueByInstance_instance_0
|
|
161
|
+
self:setActualValue(
|
|
162
|
+
instance,
|
|
163
|
+
self:calculateActualValue(instance)
|
|
164
|
+
)
|
|
137
165
|
end
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
166
|
+
end
|
|
167
|
+
function ObjectField.prototype.removeModifier(self, instance, modifier)
|
|
168
|
+
local modifiersByInstance = self.modifiersByInstance
|
|
169
|
+
if modifiersByInstance ~= nil then
|
|
170
|
+
local modifiers = modifiersByInstance[instance]
|
|
171
|
+
if modifiers ~= nil and modifiers:remove(modifier) then
|
|
172
|
+
self:setActualValue(
|
|
173
|
+
instance,
|
|
174
|
+
self:calculateActualValue(instance)
|
|
175
|
+
)
|
|
176
|
+
return true
|
|
142
177
|
end
|
|
143
|
-
self:invokeValueChangeEvent(entry, self, previousValue, value)
|
|
144
178
|
end
|
|
145
|
-
return
|
|
179
|
+
return false
|
|
146
180
|
end
|
|
147
181
|
function ObjectField.prototype.removeValue(self, entry)
|
|
148
182
|
if not warpack.compiletime then
|
|
@@ -164,6 +198,78 @@ function ObjectField.prototype.trySetValue(self, entry, value)
|
|
|
164
198
|
end
|
|
165
199
|
return self:setValue(entry, value)
|
|
166
200
|
end
|
|
201
|
+
function ObjectField.prototype.getActualValue(self, instance)
|
|
202
|
+
local defaultValueByObjectDataEntryId = defaultValueByObjectDataEntryIdByObjectFieldId[self.id]
|
|
203
|
+
if defaultValueByObjectDataEntryId ~= nil or self.isGlobal then
|
|
204
|
+
local defaultValue = (defaultValueByObjectDataEntryId or emptyLuaMap())[self:getObjectDataEntryId(instance)]
|
|
205
|
+
if defaultValue ~= nil or self.isGlobal then
|
|
206
|
+
local ____self_valueByInstance_instance_3 = self.valueByInstance[instance]
|
|
207
|
+
if ____self_valueByInstance_instance_3 == nil then
|
|
208
|
+
____self_valueByInstance_instance_3 = defaultValue
|
|
209
|
+
end
|
|
210
|
+
local ____self_valueByInstance_instance_3_4 = ____self_valueByInstance_instance_3
|
|
211
|
+
if ____self_valueByInstance_instance_3_4 == nil then
|
|
212
|
+
____self_valueByInstance_instance_3_4 = self.defaultValue
|
|
213
|
+
end
|
|
214
|
+
return ____self_valueByInstance_instance_3_4
|
|
215
|
+
end
|
|
216
|
+
end
|
|
217
|
+
local ____temp_5 = self:getNativeFieldValue(instance)
|
|
218
|
+
if ____temp_5 == nil then
|
|
219
|
+
____temp_5 = self.defaultValue
|
|
220
|
+
end
|
|
221
|
+
return ____temp_5
|
|
222
|
+
end
|
|
223
|
+
function ObjectField.prototype.setActualValue(self, instance, value)
|
|
224
|
+
local defaultValueByObjectDataEntryId = defaultValueByObjectDataEntryIdByObjectFieldId[self.id]
|
|
225
|
+
local objectDataEntryId = self:getObjectDataEntryId(instance)
|
|
226
|
+
if defaultValueByObjectDataEntryId ~= nil or self.isGlobal then
|
|
227
|
+
local defaultValue = (defaultValueByObjectDataEntryId or emptyLuaMap())[objectDataEntryId]
|
|
228
|
+
if defaultValue ~= nil or self.isGlobal then
|
|
229
|
+
local ____self_valueByInstance_instance_6 = self.valueByInstance[instance]
|
|
230
|
+
if ____self_valueByInstance_instance_6 == nil then
|
|
231
|
+
____self_valueByInstance_instance_6 = defaultValue
|
|
232
|
+
end
|
|
233
|
+
local ____self_valueByInstance_instance_6_7 = ____self_valueByInstance_instance_6
|
|
234
|
+
if ____self_valueByInstance_instance_6_7 == nil then
|
|
235
|
+
____self_valueByInstance_instance_6_7 = self.defaultValue
|
|
236
|
+
end
|
|
237
|
+
local previousValue = ____self_valueByInstance_instance_6_7
|
|
238
|
+
if value ~= previousValue then
|
|
239
|
+
self.valueByInstance[instance] = value
|
|
240
|
+
self:invokeValueChangeEvent(instance, self, previousValue, value)
|
|
241
|
+
end
|
|
242
|
+
return true
|
|
243
|
+
end
|
|
244
|
+
end
|
|
245
|
+
if not self:hasNativeFieldValue(objectDataEntryId) then
|
|
246
|
+
return false
|
|
247
|
+
end
|
|
248
|
+
local previousValue = self:getNativeFieldValue(instance)
|
|
249
|
+
if value ~= previousValue then
|
|
250
|
+
if not self:setNativeFieldValue(instance, value) then
|
|
251
|
+
return false
|
|
252
|
+
end
|
|
253
|
+
self:invokeValueChangeEvent(instance, self, previousValue, value)
|
|
254
|
+
end
|
|
255
|
+
return true
|
|
256
|
+
end
|
|
257
|
+
function ObjectField.prototype.calculateActualValue(self, instance)
|
|
258
|
+
local ____opt_8 = self.originalValueByInstance
|
|
259
|
+
local originalValue = ____opt_8 and ____opt_8[instance]
|
|
260
|
+
local ____opt_10 = self.modifiersByInstance
|
|
261
|
+
local modifiers = ____opt_10 and ____opt_10[instance]
|
|
262
|
+
if originalValue ~= nil then
|
|
263
|
+
local value = originalValue
|
|
264
|
+
if modifiers ~= nil then
|
|
265
|
+
for modifier in pairs(modifiers) do
|
|
266
|
+
value = modifier(instance, value, originalValue)
|
|
267
|
+
end
|
|
268
|
+
end
|
|
269
|
+
return value
|
|
270
|
+
end
|
|
271
|
+
return self.defaultValue
|
|
272
|
+
end
|
|
167
273
|
function ObjectField.prototype.invokeValueChangeEvent(self, ...)
|
|
168
274
|
self:invokeValueChangeEventRecursive(
|
|
169
275
|
getClass(self),
|
|
@@ -217,37 +323,37 @@ function ObjectArrayField.prototype.getValue(self, entry, index)
|
|
|
217
323
|
if defaultValueByObjectDataEntryId ~= nil then
|
|
218
324
|
local value = defaultValueByObjectDataEntryId[entry.id]
|
|
219
325
|
if value ~= nil then
|
|
220
|
-
local
|
|
326
|
+
local ____temp_13
|
|
221
327
|
if index == nil then
|
|
222
|
-
|
|
328
|
+
____temp_13 = value
|
|
223
329
|
else
|
|
224
|
-
local
|
|
225
|
-
if
|
|
226
|
-
|
|
330
|
+
local ____value_index_12 = value[index + 1]
|
|
331
|
+
if ____value_index_12 == nil then
|
|
332
|
+
____value_index_12 = self.defaultValue
|
|
227
333
|
end
|
|
228
|
-
|
|
334
|
+
____temp_13 = ____value_index_12
|
|
229
335
|
end
|
|
230
|
-
return
|
|
336
|
+
return ____temp_13
|
|
231
337
|
end
|
|
232
338
|
end
|
|
233
339
|
return index == nil and ({}) or self.defaultValue
|
|
234
340
|
end
|
|
235
341
|
local defaultValueByObjectDataEntryId = defaultValueByObjectDataEntryIdByObjectFieldId[self.id]
|
|
236
|
-
if defaultValueByObjectDataEntryId ~= nil then
|
|
237
|
-
local defaultValue = defaultValueByObjectDataEntryId[self:getObjectDataEntryId(entry)]
|
|
238
|
-
if defaultValue ~= nil then
|
|
239
|
-
local value = self.valueByInstance[entry] or defaultValue
|
|
240
|
-
local
|
|
342
|
+
if defaultValueByObjectDataEntryId ~= nil or self.isGlobal then
|
|
343
|
+
local defaultValue = (defaultValueByObjectDataEntryId or emptyLuaMap())[self:getObjectDataEntryId(entry)]
|
|
344
|
+
if defaultValue ~= nil or self.isGlobal then
|
|
345
|
+
local value = self.valueByInstance[entry] or defaultValue or emptyArray()
|
|
346
|
+
local ____temp_15
|
|
241
347
|
if index == nil then
|
|
242
|
-
|
|
348
|
+
____temp_15 = value
|
|
243
349
|
else
|
|
244
|
-
local
|
|
245
|
-
if
|
|
246
|
-
|
|
350
|
+
local ____value_index_14 = value[index + 1]
|
|
351
|
+
if ____value_index_14 == nil then
|
|
352
|
+
____value_index_14 = self.defaultValue
|
|
247
353
|
end
|
|
248
|
-
|
|
354
|
+
____temp_15 = ____value_index_14
|
|
249
355
|
end
|
|
250
|
-
return
|
|
356
|
+
return ____temp_15
|
|
251
357
|
end
|
|
252
358
|
end
|
|
253
359
|
if index ~= nil then
|
|
@@ -292,36 +398,16 @@ function ObjectLevelField.prototype.getValue(self, entry, level)
|
|
|
292
398
|
if defaultValueByObjectDataEntryId ~= nil then
|
|
293
399
|
local valueByLevel = defaultValueByObjectDataEntryId[entry.id]
|
|
294
400
|
if valueByLevel ~= nil then
|
|
295
|
-
local
|
|
296
|
-
if
|
|
297
|
-
|
|
401
|
+
local ____valueByLevel_index_16 = valueByLevel[level + 1]
|
|
402
|
+
if ____valueByLevel_index_16 == nil then
|
|
403
|
+
____valueByLevel_index_16 = self.defaultValue
|
|
298
404
|
end
|
|
299
|
-
return
|
|
405
|
+
return ____valueByLevel_index_16
|
|
300
406
|
end
|
|
301
407
|
end
|
|
302
408
|
return self.defaultValue
|
|
303
409
|
end
|
|
304
|
-
|
|
305
|
-
if defaultValueByObjectDataEntryId ~= nil then
|
|
306
|
-
local defaultValueByLevel = defaultValueByObjectDataEntryId[self:getObjectDataEntryId(entry)]
|
|
307
|
-
if defaultValueByLevel ~= nil then
|
|
308
|
-
local ____opt_9 = self.valueByInstance[entry]
|
|
309
|
-
local ____temp_11 = ____opt_9 and ____opt_9[level + 1]
|
|
310
|
-
if ____temp_11 == nil then
|
|
311
|
-
____temp_11 = defaultValueByLevel[level + 1]
|
|
312
|
-
end
|
|
313
|
-
local ____temp_11_12 = ____temp_11
|
|
314
|
-
if ____temp_11_12 == nil then
|
|
315
|
-
____temp_11_12 = self.defaultValue
|
|
316
|
-
end
|
|
317
|
-
return ____temp_11_12
|
|
318
|
-
end
|
|
319
|
-
end
|
|
320
|
-
local ____temp_13 = self:getNativeFieldValue(entry, level)
|
|
321
|
-
if ____temp_13 == nil then
|
|
322
|
-
____temp_13 = self.defaultValue
|
|
323
|
-
end
|
|
324
|
-
return ____temp_13
|
|
410
|
+
return self:getActualValue(entry, level)
|
|
325
411
|
end
|
|
326
412
|
function ObjectLevelField.prototype.setValue(self, entry, levelOrValue, value)
|
|
327
413
|
if value == nil then
|
|
@@ -361,28 +447,129 @@ function ObjectLevelField.prototype.setValue(self, entry, levelOrValue, value)
|
|
|
361
447
|
valueByLevel[level + 1] = value
|
|
362
448
|
return true
|
|
363
449
|
end
|
|
450
|
+
local modifiersByInstance = self.modifiersByInstance
|
|
451
|
+
if modifiersByInstance ~= nil then
|
|
452
|
+
local modifiers = modifiersByInstance[entry]
|
|
453
|
+
if modifiers ~= nil and modifiers.size ~= 0 then
|
|
454
|
+
local originalValueByLevelByInstance = self.originalValueByLevelByInstance
|
|
455
|
+
if originalValueByLevelByInstance == nil then
|
|
456
|
+
originalValueByLevelByInstance = mutableWeakLuaMap()
|
|
457
|
+
self.originalValueByLevelByInstance = originalValueByLevelByInstance
|
|
458
|
+
end
|
|
459
|
+
getOrPut(originalValueByLevelByInstance, entry, mutableLuaMap)[level] = value
|
|
460
|
+
value = self:calculateActualValue(entry, level)
|
|
461
|
+
end
|
|
462
|
+
end
|
|
463
|
+
return self:setActualValue(entry, level, value)
|
|
464
|
+
end
|
|
465
|
+
function ObjectLevelField.prototype.applyModifier(self, instance, modifier)
|
|
466
|
+
local modifiersByInstance = self.modifiersByInstance
|
|
467
|
+
if modifiersByInstance == nil then
|
|
468
|
+
modifiersByInstance = mutableWeakLuaMap()
|
|
469
|
+
self.modifiersByInstance = modifiersByInstance
|
|
470
|
+
end
|
|
471
|
+
if getOrPut(modifiersByInstance, instance, mutableLinkedSet):add(modifier) then
|
|
472
|
+
local originalValueByLevelByInstance = self.originalValueByLevelByInstance
|
|
473
|
+
if originalValueByLevelByInstance == nil then
|
|
474
|
+
originalValueByLevelByInstance = mutableWeakLuaMap()
|
|
475
|
+
self.originalValueByLevelByInstance = originalValueByLevelByInstance
|
|
476
|
+
end
|
|
477
|
+
local originalValueByLevel = getOrPut(originalValueByLevelByInstance, instance, mutableLuaMap)
|
|
478
|
+
local levelCount = self:getLevelCount(instance)
|
|
479
|
+
for level = 0, levelCount - 1 do
|
|
480
|
+
local ____originalValueByLevel_level_17 = originalValueByLevel[level]
|
|
481
|
+
if ____originalValueByLevel_level_17 == nil then
|
|
482
|
+
____originalValueByLevel_level_17 = self:getActualValue(instance, level)
|
|
483
|
+
end
|
|
484
|
+
originalValueByLevel[level] = ____originalValueByLevel_level_17
|
|
485
|
+
self:setActualValue(
|
|
486
|
+
instance,
|
|
487
|
+
level,
|
|
488
|
+
self:calculateActualValue(instance, level)
|
|
489
|
+
)
|
|
490
|
+
end
|
|
491
|
+
end
|
|
492
|
+
end
|
|
493
|
+
function ObjectLevelField.prototype.removeModifier(self, instance, modifier)
|
|
494
|
+
local modifiersByInstance = self.modifiersByInstance
|
|
495
|
+
if modifiersByInstance ~= nil then
|
|
496
|
+
local modifiers = modifiersByInstance[instance]
|
|
497
|
+
if modifiers ~= nil and modifiers:remove(modifier) then
|
|
498
|
+
local levelCount = self:getLevelCount(instance)
|
|
499
|
+
for level = 0, levelCount - 1 do
|
|
500
|
+
self:setActualValue(
|
|
501
|
+
instance,
|
|
502
|
+
level,
|
|
503
|
+
self:calculateActualValue(instance, level)
|
|
504
|
+
)
|
|
505
|
+
end
|
|
506
|
+
return true
|
|
507
|
+
end
|
|
508
|
+
end
|
|
509
|
+
return false
|
|
510
|
+
end
|
|
511
|
+
function ObjectLevelField.prototype.trySetValue(self, entry, levelOrValue, value)
|
|
512
|
+
if value ~= nil then
|
|
513
|
+
if __TS__TypeOf(value) ~= __TS__TypeOf(self.defaultValue) then
|
|
514
|
+
return false
|
|
515
|
+
end
|
|
516
|
+
if type(levelOrValue) ~= "number" then
|
|
517
|
+
return false
|
|
518
|
+
end
|
|
519
|
+
return self:setValue(entry, levelOrValue, value)
|
|
520
|
+
end
|
|
521
|
+
if __TS__TypeOf(levelOrValue) ~= __TS__TypeOf(self.defaultValue) then
|
|
522
|
+
return false
|
|
523
|
+
end
|
|
524
|
+
return self:setValue(entry, levelOrValue)
|
|
525
|
+
end
|
|
526
|
+
function ObjectLevelField.prototype.getActualValue(self, instance, level)
|
|
364
527
|
local defaultValueByObjectDataEntryId = defaultValueByObjectDataEntryIdByObjectFieldId[self.id]
|
|
365
|
-
if defaultValueByObjectDataEntryId ~= nil then
|
|
366
|
-
local defaultValueByLevel = defaultValueByObjectDataEntryId[self:getObjectDataEntryId(
|
|
367
|
-
if defaultValueByLevel ~= nil then
|
|
368
|
-
local
|
|
528
|
+
if defaultValueByObjectDataEntryId ~= nil or self.isGlobal then
|
|
529
|
+
local defaultValueByLevel = (defaultValueByObjectDataEntryId or emptyLuaMap())[self:getObjectDataEntryId(instance)]
|
|
530
|
+
if defaultValueByLevel ~= nil or self.isGlobal then
|
|
531
|
+
local ____opt_18 = self.valueByInstance[instance]
|
|
532
|
+
local ____temp_20 = ____opt_18 and ____opt_18[level + 1]
|
|
533
|
+
if ____temp_20 == nil then
|
|
534
|
+
____temp_20 = (defaultValueByLevel or emptyArray())[level + 1]
|
|
535
|
+
end
|
|
536
|
+
local ____temp_20_21 = ____temp_20
|
|
537
|
+
if ____temp_20_21 == nil then
|
|
538
|
+
____temp_20_21 = self.defaultValue
|
|
539
|
+
end
|
|
540
|
+
return ____temp_20_21
|
|
541
|
+
end
|
|
542
|
+
end
|
|
543
|
+
local ____temp_22 = self:getNativeFieldValue(instance, level)
|
|
544
|
+
if ____temp_22 == nil then
|
|
545
|
+
____temp_22 = self.defaultValue
|
|
546
|
+
end
|
|
547
|
+
return ____temp_22
|
|
548
|
+
end
|
|
549
|
+
function ObjectLevelField.prototype.setActualValue(self, instance, level, value)
|
|
550
|
+
local defaultValueByObjectDataEntryId = defaultValueByObjectDataEntryIdByObjectFieldId[self.id]
|
|
551
|
+
local objectDataEntryId = self:getObjectDataEntryId(instance)
|
|
552
|
+
if defaultValueByObjectDataEntryId ~= nil or self.isGlobal then
|
|
553
|
+
local defaultValueByLevel = (defaultValueByObjectDataEntryId or emptyLuaMap())[objectDataEntryId]
|
|
554
|
+
if defaultValueByLevel ~= nil or self.isGlobal then
|
|
555
|
+
local valueByLevel = self.valueByInstance[instance]
|
|
369
556
|
if valueByLevel == nil then
|
|
370
557
|
valueByLevel = {}
|
|
371
|
-
self.valueByInstance[
|
|
558
|
+
self.valueByInstance[instance] = valueByLevel
|
|
372
559
|
end
|
|
373
|
-
local
|
|
374
|
-
if
|
|
375
|
-
|
|
560
|
+
local ____valueByLevel_index_23 = valueByLevel[level + 1]
|
|
561
|
+
if ____valueByLevel_index_23 == nil then
|
|
562
|
+
____valueByLevel_index_23 = (defaultValueByLevel or emptyArray())[level + 1]
|
|
376
563
|
end
|
|
377
|
-
local
|
|
378
|
-
if
|
|
379
|
-
|
|
564
|
+
local ____valueByLevel_index_23_24 = ____valueByLevel_index_23
|
|
565
|
+
if ____valueByLevel_index_23_24 == nil then
|
|
566
|
+
____valueByLevel_index_23_24 = self.defaultValue
|
|
380
567
|
end
|
|
381
|
-
local previousValue =
|
|
568
|
+
local previousValue = ____valueByLevel_index_23_24
|
|
382
569
|
if value ~= previousValue then
|
|
383
570
|
valueByLevel[level + 1] = value
|
|
384
571
|
self:invokeValueChangeEvent(
|
|
385
|
-
|
|
572
|
+
instance,
|
|
386
573
|
self,
|
|
387
574
|
level,
|
|
388
575
|
previousValue,
|
|
@@ -392,16 +579,16 @@ function ObjectLevelField.prototype.setValue(self, entry, levelOrValue, value)
|
|
|
392
579
|
return true
|
|
393
580
|
end
|
|
394
581
|
end
|
|
395
|
-
if not self:hasNativeFieldValue(
|
|
582
|
+
if not self:hasNativeFieldValue(objectDataEntryId) then
|
|
396
583
|
return false
|
|
397
584
|
end
|
|
398
|
-
local previousValue = self:getNativeFieldValue(
|
|
585
|
+
local previousValue = self:getNativeFieldValue(instance, level)
|
|
399
586
|
if value ~= previousValue then
|
|
400
|
-
if not self:setNativeFieldValue(
|
|
587
|
+
if not self:setNativeFieldValue(instance, level, value) then
|
|
401
588
|
return false
|
|
402
589
|
end
|
|
403
590
|
self:invokeValueChangeEvent(
|
|
404
|
-
|
|
591
|
+
instance,
|
|
405
592
|
self,
|
|
406
593
|
level,
|
|
407
594
|
previousValue,
|
|
@@ -410,20 +597,22 @@ function ObjectLevelField.prototype.setValue(self, entry, levelOrValue, value)
|
|
|
410
597
|
end
|
|
411
598
|
return true
|
|
412
599
|
end
|
|
413
|
-
function ObjectLevelField.prototype.
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
600
|
+
function ObjectLevelField.prototype.calculateActualValue(self, instance, level)
|
|
601
|
+
local ____opt_27 = self.originalValueByLevelByInstance
|
|
602
|
+
local ____opt_25 = ____opt_27 and ____opt_27[instance]
|
|
603
|
+
local originalValue = ____opt_25 and ____opt_25[level]
|
|
604
|
+
local ____opt_29 = self.modifiersByInstance
|
|
605
|
+
local modifiers = ____opt_29 and ____opt_29[instance]
|
|
606
|
+
if originalValue ~= nil then
|
|
607
|
+
local value = originalValue
|
|
608
|
+
if modifiers ~= nil then
|
|
609
|
+
for modifier in pairs(modifiers) do
|
|
610
|
+
value = modifier(instance, level, value, originalValue)
|
|
611
|
+
end
|
|
420
612
|
end
|
|
421
|
-
return
|
|
422
|
-
end
|
|
423
|
-
if __TS__TypeOf(levelOrValue) ~= __TS__TypeOf(self.defaultValue) then
|
|
424
|
-
return false
|
|
613
|
+
return value
|
|
425
614
|
end
|
|
426
|
-
return self
|
|
615
|
+
return self.defaultValue
|
|
427
616
|
end
|
|
428
617
|
function ObjectLevelField.prototype.invokeValueChangeEvent(self, ...)
|
|
429
618
|
self:invokeValueChangeEventRecursive(
|
package/engine/random.d.ts
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/** @noSelfInFile */
|
|
2
|
+
import { ReadonlyNonEmptyArray } from "../utility/types";
|
|
2
3
|
export declare const randomAngle: () => number;
|
|
3
4
|
export declare const randomInteger: {
|
|
4
5
|
(upperBound?: number): number;
|
|
@@ -9,3 +10,11 @@ export declare const randomFloat: {
|
|
|
9
10
|
(lowerBound: number, upperBound: number): number;
|
|
10
11
|
};
|
|
11
12
|
export declare const randomXY: (centerX: number, centerY: number, range: number) => LuaMultiReturn<[x: number, y: number]>;
|
|
13
|
+
export declare const randomElement: {
|
|
14
|
+
<T>(array: ReadonlyNonEmptyArray<T>): T;
|
|
15
|
+
<T>(array: ReadonlyArray<T>): T | undefined;
|
|
16
|
+
};
|
|
17
|
+
export declare const random: {
|
|
18
|
+
<T>(element: T, ...elements: T[]): T;
|
|
19
|
+
<T>(...elements: T[]): T | undefined;
|
|
20
|
+
};
|
package/engine/random.lua
CHANGED
|
@@ -4,6 +4,7 @@ local MAXIMUM_INTEGER = ____math.MAXIMUM_INTEGER
|
|
|
4
4
|
local PI = ____math.PI
|
|
5
5
|
local getRandomInt = GetRandomInt
|
|
6
6
|
local getRandomReal = GetRandomReal
|
|
7
|
+
local select = _G.select
|
|
7
8
|
local cos = math.cos
|
|
8
9
|
local sin = math.sin
|
|
9
10
|
local sqrt = math.sqrt
|
|
@@ -15,4 +16,16 @@ ____exports.randomXY = function(centerX, centerY, range)
|
|
|
15
16
|
local t = getRandomReal(0, 1) * 2 * PI
|
|
16
17
|
return centerX + r * cos(t), centerY + r * sin(t)
|
|
17
18
|
end
|
|
19
|
+
____exports.randomElement = function(array)
|
|
20
|
+
return array[getRandomInt(1, #array)]
|
|
21
|
+
end
|
|
22
|
+
____exports.random = function(...)
|
|
23
|
+
return (select(
|
|
24
|
+
getRandomInt(
|
|
25
|
+
1,
|
|
26
|
+
select("#", ...)
|
|
27
|
+
),
|
|
28
|
+
...
|
|
29
|
+
))
|
|
30
|
+
end
|
|
18
31
|
return ____exports
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/** @noSelfInFile */
|
|
2
|
+
import { StandardSoundPresetId } from "../../object-data/entry/sound-preset";
|
|
3
|
+
export declare const ABOMINATION_PISSED_SOUND_PRESET_ID: StandardSoundPresetId;
|
|
4
|
+
export declare const ABOMINATION_READY_SOUND_PRESET_ID: StandardSoundPresetId;
|
|
5
|
+
export declare const ABOMINATION_WAR_CRY_SOUND_PRESET_ID: StandardSoundPresetId;
|
|
6
|
+
export declare const AXE_MEDIUM_CHOP_WOOD_SOUND_PRESET_ID: StandardSoundPresetId;
|
|
7
|
+
export declare const IMPALE_SOUND_PRESET_ID: StandardSoundPresetId;
|
|
8
|
+
export declare const IMPALE_HIT_SOUND_PRESET_ID: StandardSoundPresetId;
|
|
9
|
+
export declare const IMPALE_LAND_SOUND_PRESET_ID: StandardSoundPresetId;
|
|
10
|
+
export declare const IMPALE_CAST_SOUND_PRESET_ID: StandardSoundPresetId;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
local ____exports = {}
|
|
2
|
+
____exports.ABOMINATION_PISSED_SOUND_PRESET_ID = "AbominationPissed"
|
|
3
|
+
____exports.ABOMINATION_READY_SOUND_PRESET_ID = "AbominationReady"
|
|
4
|
+
____exports.ABOMINATION_WAR_CRY_SOUND_PRESET_ID = "AbominationWarcry"
|
|
5
|
+
____exports.AXE_MEDIUM_CHOP_WOOD_SOUND_PRESET_ID = "AxeMediumChopWood"
|
|
6
|
+
____exports.IMPALE_SOUND_PRESET_ID = "Impale"
|
|
7
|
+
____exports.IMPALE_HIT_SOUND_PRESET_ID = "ImpaleHit"
|
|
8
|
+
____exports.IMPALE_LAND_SOUND_PRESET_ID = "ImpaleLand"
|
|
9
|
+
____exports.IMPALE_CAST_SOUND_PRESET_ID = "ImpaleCast"
|
|
10
|
+
return ____exports
|
|
@@ -687,6 +687,8 @@ export declare const DISABLE_OTHER_ABILITIES_ABILITY_BOOLEAN_LEVEL_FIELD: Abilit
|
|
|
687
687
|
export declare const ALLOW_BOUNTY_ABILITY_BOOLEAN_LEVEL_FIELD: AbilityBooleanLevelField & symbol;
|
|
688
688
|
export declare const ICON_NORMAL_ABILITY_STRING_LEVEL_FIELD: AbilityStringLevelField & symbol;
|
|
689
689
|
export declare const CASTER_EFFECT_MODEL_PATHS_ABILITY_STRING_ARRAY_FIELD: AbilityStringArrayField & symbol;
|
|
690
|
+
export declare const CASTER_EFFECT_FIRST_ATTACHMENT_POINT_STRING_FIELD: AbilityStringField & symbol;
|
|
691
|
+
export declare const CASTER_EFFECT_SECOND_ATTACHMENT_POINT_STRING_FIELD: AbilityStringField & symbol;
|
|
690
692
|
export declare const TARGET_EFFECT_MODEL_PATHS_ABILITY_STRING_ARRAY_FIELD: AbilityStringArrayField & symbol;
|
|
691
693
|
export declare const TARGET_EFFECT_FIRST_ATTACHMENT_POINT_STRING_FIELD: AbilityStringField & symbol;
|
|
692
694
|
export declare const TARGET_EFFECT_SECOND_ATTACHMENT_POINT_STRING_FIELD: AbilityStringField & symbol;
|
|
@@ -698,6 +698,8 @@ ____exports.DISABLE_OTHER_ABILITIES_ABILITY_BOOLEAN_LEVEL_FIELD = AbilityBoolean
|
|
|
698
698
|
____exports.ALLOW_BOUNTY_ABILITY_BOOLEAN_LEVEL_FIELD = AbilityBooleanLevelField:create(fourCC("Ntm4"))
|
|
699
699
|
____exports.ICON_NORMAL_ABILITY_STRING_LEVEL_FIELD = AbilityStringLevelField:create(fourCC("aart"))
|
|
700
700
|
____exports.CASTER_EFFECT_MODEL_PATHS_ABILITY_STRING_ARRAY_FIELD = AbilityStringArrayField:create(fourCC("acat"))
|
|
701
|
+
____exports.CASTER_EFFECT_FIRST_ATTACHMENT_POINT_STRING_FIELD = AbilityStringField:create(fourCC("acap"))
|
|
702
|
+
____exports.CASTER_EFFECT_SECOND_ATTACHMENT_POINT_STRING_FIELD = AbilityStringField:create(fourCC("aca1"))
|
|
701
703
|
____exports.TARGET_EFFECT_MODEL_PATHS_ABILITY_STRING_ARRAY_FIELD = AbilityStringArrayField:create(fourCC("atat"))
|
|
702
704
|
____exports.TARGET_EFFECT_FIRST_ATTACHMENT_POINT_STRING_FIELD = AbilityStringField:create(fourCC("ata0"))
|
|
703
705
|
____exports.TARGET_EFFECT_SECOND_ATTACHMENT_POINT_STRING_FIELD = AbilityStringField:create(fourCC("ata1"))
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
/** @noSelfInFile */
|
|
2
|
+
import { UnitClassificationsField, UnitFlyHeightField, UnitPropulsionWindowField } from "../../object-field/unit";
|
|
3
|
+
export declare const PROPULSION_WINDOW_UNIT_FLOAT_FIELD: UnitPropulsionWindowField & symbol;
|
|
4
|
+
export declare const UNIT_CLASSIFICATIONS_FIELD: UnitClassificationsField & symbol;
|
|
5
|
+
export declare const FLY_HEIGHT_UNIT_FLOAT_FIELD: UnitFlyHeightField & symbol;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
local ____exports = {}
|
|
2
|
+
local ____unit = require("engine.object-field.unit")
|
|
3
|
+
local UnitClassificationsField = ____unit.UnitClassificationsField
|
|
4
|
+
local UnitFlyHeightField = ____unit.UnitFlyHeightField
|
|
5
|
+
local UnitPropulsionWindowField = ____unit.UnitPropulsionWindowField
|
|
6
|
+
____exports.PROPULSION_WINDOW_UNIT_FLOAT_FIELD = UnitPropulsionWindowField:create(fourCC("urpw"))
|
|
7
|
+
____exports.UNIT_CLASSIFICATIONS_FIELD = UnitClassificationsField:create(fourCC("utyp"))
|
|
8
|
+
____exports.FLY_HEIGHT_UNIT_FLOAT_FIELD = UnitFlyHeightField:create(fourCC("ufyh"))
|
|
9
|
+
return ____exports
|