Script v1_7_1_0
- AI
- Animals
- Collections
- Contracts
- Debug
- Economy
- Elements
- EnvironmentalScore
- Errors
- Events
- GUI
- Handtools
- Hud
- I3d
- Input
- Jobs
- Maps
- Materials
- Misc
- Objects
- Parameters
- Placeables
- Placement
- Player
- Shop
- Sounds
- Specialization
- Specializations
- StateMachine
- Statistics
- Tasks
- Triggers
- Utils
- Vehicles
Engine v1_7_1_0
- AI
- Animation
- Camera
- Entity
- Fillplanes
- general
- General
- I3D
- Input
- Lighting
- Math
- Network
- Node
- NoteNode
- Overlays
- Particle System
- Physics
- Rendering
- Scenegraph
- Shape
- Sound
- Spline
- String
- Terrain Detail
- Text Rendering
- Tire Track
- VoiceChat
- XML
Foundation Reference
AnimationValueBool
DescriptionAnimation value with a boolean as typeParent
AnimationValueFloatFunctions
init
DescriptionDefinitioninit()Code
33 | function AnimationValueBool:init(index, numParts) |
34 | end |
load
DescriptionDefinitionload()Code
22 | function AnimationValueBool:load(xmlFile, key) |
23 | self.value = xmlFile:getValue(key .. "#" .. self.startName) |
24 | |
25 | self.warningInfo = key |
26 | self.xmlFile = xmlFile |
27 | |
28 | return self.value ~= nil and self:extraLoad(xmlFile, key) |
29 | end |
new
DescriptionDefinitionnew()Code
16 | function AnimationValueBool.new(vehicle, animation, part, startName, endName, name, initialUpdate, get, set, extraLoad, customMt) |
17 | return AnimationValueFloat.new(vehicle, animation, part, startName, endName, name, initialUpdate, get, set, extraLoad, customMt or AnimationValueBool_mt) |
18 | end |
postInit
DescriptionDefinitionpostInit()Code
38 | function AnimationValueBool:postInit() |
39 | end |
reset
DescriptionDefinitionreset()Code
43 | function AnimationValueBool:reset() |
44 | self.curValue = nil |
45 | end |
update
DescriptionDefinitionupdate()Code
49 | function AnimationValueBool:update(durationToEnd, dtToUse, realDt) |
50 | if self.curValue == nil then |
51 | self.curValue = self:get() |
52 | end |
53 | |
54 | if self.value ~= self.curValue then |
55 | self.curValue = self.value |
56 | self:set(self.value) |
57 | return true |
58 | end |
59 | |
60 | return false |
61 | end |