Class Objects.LaraObject
-Class for extra player-only functions.
+Class for player-only functions.
Do not try to create an object of this type. Use the built-in Lara variable instead. LaraObject inherits all the functions of Moveable.
@@ -119,64 +123,64 @@Functions
LaraObject:SetPoison([Poison]) | -Set player poison. | +LaraObject:SetPoison([poison]) | +Set the player's poison value. |
LaraObject:GetPoison() | -Get poison potency of Lara | +Get the player's poison value. | |
LaraObject:SetAir(Air) | -Set air value of Lara | +LaraObject:SetAir(air) | +Set the player's air value. |
LaraObject:GetAir() | -Get air value of Lara | +Get the player's air value. | |
LaraObject:SetWet(Wetness) | -Set wetness value of Lara (causes dripping) | +LaraObject:SetWet(wetness) | +Set the player's wetness value, causing drips. |
LaraObject:GetWet() | -Get wetness value of Lara | +Get the player's wetness value. | |
LaraObject:SetStamina(stamina) | -Set sprint energy value of Lara | +LaraObject:SetStamina(New) | +Set the player's stamina value. |
LaraObject:GetStamina() | -Get stamina value of Lara | +Get the player's stamina value. | |
Moveable:GetAirborne() | -Get the moveable's airborne status | +Get the player's airborne status (set when jumping and falling). | |
Moveable:SetAirborne(New) | -Set the moveable's airborne status | +Moveable:SetAirborne(airborne) | +Set the player's airborne status. |
LaraObject:UndrawWeapon() | -Lara will undraw her weapon if it is drawn and throw away a flare if she is currently holding one. | +Undraw a weapon if it is drawn and throw away a flare if currently holding one. | |
LaraObject:ThrowAwayTorch() | -Lara will throw away the torch if she currently holds one in her hand. | +LaraObject:DiscardTorch() | +Discard a held torch. |
LaraObject:GetHandStatus() | -Get actual hand status of Lara | +Get the player's hand status. | |
LaraObject:GetWeaponType() | -Get actual weapon type of Lara | +Get the player's weapon type. | |
LaraObject:SetWeaponType(weaponType, activate) | -Set Lara weapon type | +Set the player's weapon type. | |
LaraObject:GetAmmoType() | @@ -184,11 +188,11 @@|||
LaraObject:GetAmmoCount() | -Get current weapon's ammo count | +Get current weapon's ammo count. | |
LaraObject:GetVehicle() | -Get current vehicle, if it exists | +Get current vehicle, if it exists. | |
LaraObject:GetTarget() | @@ -199,8 +203,16 @@Get the player's current interacted moveable (if it exists). | ||
LaraObject:TorchIsLit() | -Get current light state of the torch, if it exists | +LaraObject:IsTorchLit() | +Check if a held torch is lit. | +
LaraObject:Interact(mov, [animNumber], [offset], [minOffsetConstraint], [maxOffsetConstraint], [minRotConstraint], [maxRotConstraint], [actionID]) | +Align the player with a moveable object for interaction. | +||
LaraObject:TestInteraction(mov, [minOffsetConstraint], [maxOffsetConstraint], [minRotConstraint], [maxRotConstraint]) | +Test the player against a moveable object for interaction. |
- - LaraObject:SetPoison([Poison]) + LaraObject:SetPoison([poison])
-
- Set player poison.
+ Set the player's poison value.
Parameters:
-
-
- Poison +
- poison int - ; maximum value is 128 (default 0) - (optional) + New poison value. default: 0, max: 128 + Optional.
- - Get poison potency of Lara + Get the player's poison value. @@ -252,7 +264,7 @@
-
int
- current poison potency
+ Poison value.
- - LaraObject:SetAir(Air) + LaraObject:SetAir(air)
-
- Set air value of Lara
+ Set the player's air value.
Parameters:
-
-
- Air +
- air int - value to give Lara. Maximum value is 1800. + New air value. max: 1800
- - Get air value of Lara + Get the player's air value. @@ -303,7 +315,7 @@
-
int
- current air value
+ Air value.
- - LaraObject:SetWet(Wetness) + LaraObject:SetWet(wetness)
-
- Set wetness value of Lara (causes dripping)
+ Set the player's wetness value, causing drips.
Parameters:
-
-
- Wetness +
- wetness int - value. Maximum 255 + New wetness value. max: 255
- - Get wetness value of Lara + Get the player's wetness value. @@ -354,7 +366,7 @@
-
int
- current wetness value
+ Wetness value.
- - LaraObject:SetStamina(stamina) + LaraObject:SetStamina(New)
-
- Set sprint energy value of Lara
+ Set the player's stamina value.
Parameters:
-
-
- stamina +
- New int - to give to Lara; maximum value is 120. + stamina value. max: 120
- - Get stamina value of Lara + Get the player's stamina value. @@ -405,7 +417,7 @@
-
int
- current sprint value
+ Stamina value.
- - Get the moveable's airborne status + Get the player's airborne status (set when jumping and falling). @@ -429,8 +441,8 @@
Returns:
-
- (bool)
- true if Lara state must react to aerial forces.
+ bool
+ True if airborne, otherwise false.
- - Moveable:SetAirborne(New) + Moveable:SetAirborne(airborne)
-
- Set the moveable's airborne status
+ Set the player's airborne status.
Parameters:
-
-
- New - (bool) - airborn status for Lara. +
- airborne + bool + New airborne status.
- - Lara will undraw her weapon if it is drawn and throw away a flare if she is currently holding one. + Undraw a weapon if it is drawn and throw away a flare if currently holding one. @@ -479,11 +491,11 @@
- - - LaraObject:ThrowAwayTorch() + + LaraObject:DiscardTorch()
-
- Lara will throw away the torch if she currently holds one in her hand.
+ Discard a held torch.
@@ -493,7 +505,7 @@
Usage:
-
-
Lara:ThrowAwayTorch()
+Lara:DiscardTorch()
@@ -502,7 +514,7 @@
LaraObject:GetHandStatus()
-
- Get actual hand status of Lara
+ Get the player's hand status.
@@ -510,8 +522,8 @@
Returns:
-
- int
- hand status 0=HandsFree, 1=Busy(climbing,etc), 2=WeaponDraw, 3=WeaponUndraw, 4=WeaponInHand.
+ HandStatus
+ Hand status.
- - Get actual weapon type of Lara + Get the player's weapon type. @@ -535,8 +547,8 @@
Returns:
-
- Flow.WeaponType
- current weapon type.
+ WeaponType
+ Current weapon type.
- - Set Lara weapon type + Set the player's weapon type.
Parameters:
- weaponType - Flow.WeaponType - - - + WeaponType + New weapon type to set.
- activate
bool
- if
true
, also draw the weapons or set torch lit. Iffalse
, keep weapons holstered or leave torch unlit. + Iftrue
, also draw the weapons or set torch lit. Iffalse
, keep weapons holstered or leave torch unlit.
Returns:
-
- Flow.AmmoType
- player weapon ammo type
+ AmmoType
+ Player weapon ammo type.
- - Get current weapon's ammo count + Get current weapon's ammo count. @@ -618,7 +628,7 @@
-
int
- current ammo count (-1 if infinite)
+ Current ammo count (-1 if infinite).
- - Get current vehicle, if it exists + Get current vehicle, if it exists. @@ -643,7 +653,7 @@
-
Moveable
- current vehicle (nil if no vehicle present)
+ Current vehicle (nil if no vehicle present).
- - Get actual weapon type of Lara + Get the player's weapon type. @@ -535,8 +547,8 @@
- - - LaraObject:TorchIsLit() + + LaraObject:IsTorchLit()
-
- Get current light state of the torch, if it exists
+ Check if a held torch is lit.
@@ -718,16 +728,122 @@
-
bool
- is torch currently lit or not? (false if no torch exists)
+ True if lit, otherwise false (also false if there is no torch in hand).
Usage:
-
-
local torchIsLit = Lara:TorchIsLit()
+local isTorchLit = Lara:IsTorchLit()
+
+ - + + LaraObject:Interact(mov, [animNumber], [offset], [minOffsetConstraint], [maxOffsetConstraint], [minRotConstraint], [maxRotConstraint], [actionID]) + +
-
+ Align the player with a moveable object for interaction.
+
+
+
+
Parameters:
+-
+
- mov + Moveable + Moveable object to align the player with. + +
- animNumber + int + The animation to play after alignment is complete. + Default: 197 (BUTTON_PUSH). + +
- offset + Vec3 + Relative position offset from the moveable. + Default: Vec3(0, 0, 312). + +
- minOffsetConstraint + Vec3 + Minimum relative offset constraint. + Default: Vec3(-256, -512, 0). + +
- maxOffsetConstraint + Vec3 + Maximum relative offset constraint. + Default: Vec3(256, 0, 512). + +
- minRotConstraint + Rotation + Minimum relative rotation constraint. + Default: Rotation(-10, -40, -10). + +
- maxRotConstraint + Rotation + Maximum relative rotation constraint. + Default: Rotation(10, 40, 10). + +
- actionID + ActionID + Input action ID to trigger the alignment. + Default: Input.ActionID.ACTION. + +
Usage:
+-
+
local Lara:Interact( + moveable, 197, + Vec3(0, 0, 312), Vec3(-256, -512, -256), Vec3(256, 0, 512), + Rotation(-10, -30, -10), Rotation(10, 30, 10), TEN.Input.ActionID.ACTION)
+ + +
+ - + + LaraObject:TestInteraction(mov, [minOffsetConstraint], [maxOffsetConstraint], [minRotConstraint], [maxRotConstraint]) + +
-
+ Test the player against a moveable object for interaction.
+
+
+
+
Parameters:
+-
+
- mov + Moveable + Moveable object to align the player with. + +
- minOffsetConstraint + Vec3 + Minimum relative offset constraint. + Default: Vec3(-256, -512, 0). + +
- maxOffsetConstraint + Vec3 + Maximum relative offset constraint. + Default: Vec3(256, 0, 512). + +
- minRotConstraint + Rotation + Minimum relative rotation constraint. + Default: Rotation(-10, -40, -10). + +
- maxRotConstraint + Rotation + Maximum relative rotation constraint. + Default: Rotation(10, 40, 10). + +
3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer @@ -114,121 +118,120 @@
- - Moveable(object, name, position, rotation, roomNumber, animNumber, frameNumber, hp, OCB, AIBits) + Moveable(objectID, name, position, [rotation], [roomNumber], [animNumber], [frameNumber], [hp], [OCB], [AIBits])
-
Used to generate a new moveable dynamically at runtime.
@@ -434,9 +420,9 @@ most can just be ignored (see usage).
Parameters:
-
-
- object +
- objectID ObjID - ID + Object ID.
- name string @@ -444,43 +430,50 @@ most can just be ignored (see usage).
- position Vec3 - position in level + Position in level.
- rotation Rotation - rotation rotation about x, y, and z axes (default Rotation(0, 0, 0)) + Rotation about x, y, and z axes. + Optional.
- roomNumber int - the room number the moveable is in (default: calculated automatically). + The room number the moveable is in. Needed if you are dealing with overlapping rooms and need to force certain room number. + Optional.
- animNumber int - animation number + Animation number. + Optional.
- frameNumber int - frame number + Frame number. + Optional.
- hp int Hit points. + Optional.
- OCB int Object code bits. + Optional.
- AIBits table - table with AI bits (default { 0, 0, 0, 0, 0, 0 }) + Table with six AI bits. + Optional.
Returns:
-
- Moveable
- A new Moveable object (a wrapper around the new object)
+ Moveable
+ A new Moveable object.
- - Retrieve the object ID + Retrieve the object ID. @@ -507,8 +500,8 @@ most can just be ignored (see usage).
Returns:
-
- int
- a number representing the ID of the object
+ ObjID
+ A number representing the ID of the object.
- - Moveable:SetObjectID(ID) + Moveable:SetObjectID(objectID)
-
Change the object's ID. This will literally change the object.
@@ -526,9 +519,9 @@ most can just be ignored (see usage).
Parameters:
-
-
- ID +
- objectID ObjID - the new ID + The new ID.
- - Moveable:SetOnHit(callback) + Moveable:SetOnHit(function)
-
Set the name of the function to be called when the moveable is shot by Lara.
@@ -554,9 +547,9 @@ shiva:SetObjectID(TEN.Objects.ObjID.BIGMEDI_ITEM)
Parameters:
-
-
- callback +
- function function - function in LevelFuncs hierarchy to call when moveable is shot + Callback function in LevelFuncs hierarchy to call when moveable is shot.
- - Moveable:SetOnKilled(callback) + Moveable:SetOnKilled(function)
-
- Set the name of the function to be called when the moveable is destroyed/killed
+ Set the name of the function to be called when the moveable is destroyed/killed.
Note that enemy death often occurs at the end of an animation, and not at the exact moment
the enemy's HP becomes zero.
@@ -578,9 +571,9 @@ shiva:SetObjectID(TEN.Objects.ObjID.BIGMEDI_ITEM)
Parameters:
-
-
- callback +
- function function - function in LevelFuncs hierarchy to call when enemy is killed + Callback function in LevelFuncs hierarchy to call when moveable is killed.
- - Moveable:SetOnCollidedWithObject(func) + Moveable:SetOnCollidedWithObject(function)
-
- Set the function to be called when this moveable collides with another moveable
+ Set the function to be called when this moveable collides with another moveable.
Parameters:
-
-
- func +
- function function - callback function to be called (must be in LevelFuncs hierarchy). This function can take two arguments; these will store the two Moveables taking part in the collision. + Callback function to be called (must be in LevelFuncs hierarchy). This function can take two arguments; these will store the two Moveables taking part in the collision.
- - Moveable:SetOnCollidedWithRoom(func) + Moveable:SetOnCollidedWithRoom(function)
-
Set the function called when this moveable collides with room geometry (e.g. a wall or floor). This function can take an argument that holds the Moveable that collided with geometry.
@@ -637,9 +630,9 @@ baddy:SetOnCollidedWithObject(LevelFuncs.objCollided)
Parameters:
-
-
- func +
- function function - callback function to be called (must be in LevelFuncs hierarchy) + Callback function to be called (must be in LevelFuncs hierarchy).
- - Get the moveable's name (its unique string identifier) - e.g. "door_back_room" or "cracked_greek_statue" - This corresponds with the "Lua Name" field in an object's properties in Tomb Editor. + Get the moveable's name (its unique string identifier). This corresponds with the "Lua Name" field in an object's properties in Tomb Editor. @@ -671,7 +662,7 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
-
string
- the moveable's name
+ The moveable's name.
- - Set the moveable's name (its unique string identifier) - e.g. "door_back_room" or "cracked_greek_statue" - It cannot be blank and cannot share a name with any existing object. + Set the moveable's name (its unique string identifier). It cannot be blank and cannot share a name with any existing object. @@ -693,7 +682,7 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
- name string - the new moveable's name + The new moveable's name.
-
bool
- true if we successfully set the name, false otherwise (e.g. if another object has the name already)
+ true if name was successfully set, false otherwise (e.g. if another moveable has the name already).
- - Get the object's position + Get the moveable's position. @@ -722,7 +711,7 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
-
Vec3
- a copy of the moveable's position
+ Moveable's position.
- - Moveable:SetPosition(position[, updateRoom]) + Moveable:SetPosition(position, [updateRoom])
-
- Set the moveable's position
- If you are moving a moveable whose behaviour involves knowledge of room geometry,
- (e.g. a BADDY1, which uses it for pathfinding), then the second argument should
- be true (or omitted, as true is the default). Otherwise, said moveable will not behave correctly.
+ Set the moveable's position.
@@ -745,12 +731,12 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
- position Vec3 - the new position of the moveable + The new position of the moveable.
- updateRoom bool - Will room changes be automatically detected? Set to false if you are using overlapping rooms (default: true) - (optional) + Will room changes be automatically detected? Set to false if you are using overlapping rooms. + Default: true.
- - Moveable:GetJointPosition(jointID[, offset]) + Moveable:GetJointPosition(jointIndex, [offset])
-
Get the moveable's joint position with an optional relative offset.
@@ -770,14 +756,14 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
Parameters:
-
-
- jointID +
- jointIndex int - Joint ID. + Index of a joint to get position.
- offset Vec3 Offset relative to the joint. - (optional) + Optional.
-
Vec3
- pos World position.
+ World position.
- - Get the object's joint rotation + Get the object's joint rotation. @@ -805,7 +791,7 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
- index int - of a joint to get rotation + Index of a joint to get rotation.
-
Rotation
- a calculated copy of the moveable's joint rotation
+ Moveable's joint rotation.
- - Get the moveable's rotation + Get the moveable's rotation. @@ -834,7 +820,28 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
+-
Rotation
- a copy of the moveable's rotation
+ Moveable's rotation.
+
- + + Moveable:GetScale() + +
-
+ Get the moveable's visual scale.
+
+
+
+
+
Returns:
+-
+
+ Vec3
+ Moveable's visual scale.
- - Set the moveable's rotation + Set the moveable's rotation. @@ -854,7 +861,29 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
+- rotation Rotation - The moveable's new rotation + The moveable's new rotation. + +
- - Set the moveable's rotation + Set the moveable's rotation. @@ -854,7 +861,29 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
- + + Moveable:SetScale(scale) + +
-
+ Set the moveable's visual scale. Does not affect collision.
+
+
+
+
Parameters:
+-
+
- scale + Vec3 + New visual scale.
- - Get current HP (hit points/health points) + Get current HP (hit points / health points). @@ -877,7 +906,7 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
-
int
- the amount of HP the moveable currently has
+ The amount of HP the moveable currently has.
- - Set current HP (hit points/health points) - Clamped to [0, 32767] for "intelligent" entities (i.e. anything with AI); clamped to [-32767, 32767] otherwise. + Set current HP (hit points / health points). + Clamped to [0, 32767] for "intelligent" entities (i.e. anything with AI); clamped to [-32767, 32767] otherwise. @@ -898,7 +927,7 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
- HP int - the amount of HP to give the moveable + The amount of HP to give the moveable.
- - Get HP definded for that object type (hit points/health points) (Read Only). + Get HP definded for that object type (hit points / health points). @@ -921,7 +950,7 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
-
int
- the moveable's slot default hit points
+ The moveable's slot default hit points.
- - Get OCB (object code bit) of the moveable + Get OCB (object code bit) of the moveable. @@ -942,7 +971,7 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
-
int
- the moveable's current OCB value
+ The moveable's current OCB value.
- - Set OCB (object code bit) of the moveable + Set OCB (object code bit) of the moveable. @@ -962,7 +991,7 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
- OCB int - the new value for the moveable's OCB + The new value for the moveable's OCB.
- - Moveable:SetEffect(effect[, timeout]) + Moveable:SetEffect(effect, [timeout])
-
Set the effect for this moveable.
@@ -988,8 +1017,8 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
- timeout float - time (in seconds) after which effect turns off. - (optional) + Time (in seconds) after which effect turns off. + Optional.
Represents a moveable object in the game world.
Examples include the player, traps, enemies, doors, and pickups. See also Objects.LaraObject for player-specific features.
-pragma nostrip
-Functions
Moveable(object, name, position, rotation, roomNumber, animNumber, frameNumber, hp, OCB, AIBits) | +Moveable(objectID, name, position, [rotation], [roomNumber], [animNumber], [frameNumber], [hp], [OCB], [AIBits]) | Used to generate a new moveable dynamically at runtime. | |
Moveable:GetObjectID() | -Retrieve the object ID | +Retrieve the object ID. | |
Moveable:SetObjectID(ID) | +Moveable:SetObjectID(objectID) | Change the object's ID. | |
Moveable:SetOnHit(callback) | +Moveable:SetOnHit(function) | Set the name of the function to be called when the moveable is shot by Lara. | |
Moveable:SetOnKilled(callback) | -Set the name of the function to be called when the moveable is destroyed/killed - Note that enemy death often occurs at the end of an animation, and not at the exact moment - the enemy's HP becomes zero. | +Moveable:SetOnKilled(function) | +Set the name of the function to be called when the moveable is destroyed/killed. |
Moveable:SetOnCollidedWithObject(func) | -Set the function to be called when this moveable collides with another moveable | +Moveable:SetOnCollidedWithObject(function) | +Set the function to be called when this moveable collides with another moveable. |
Moveable:SetOnCollidedWithRoom(func) | +Moveable:SetOnCollidedWithRoom(function) | Set the function called when this moveable collides with room geometry (e.g. | |
Moveable:GetName() | -Get the moveable's name (its unique string identifier) - e.g. | +Get the moveable's name (its unique string identifier). | |
Moveable:SetName(name) | -Set the moveable's name (its unique string identifier) - e.g. | +Set the moveable's name (its unique string identifier). | |
Moveable:GetPosition() | -Get the object's position | +Get the moveable's position. | |
Moveable:SetPosition(position[, updateRoom]) | -Set the moveable's position - If you are moving a moveable whose behaviour involves knowledge of room geometry, - (e.g. | +Moveable:SetPosition(position, [updateRoom]) | +Set the moveable's position. |
Moveable:GetJointPosition(jointID[, offset]) | +Moveable:GetJointPosition(jointIndex, [offset]) | Get the moveable's joint position with an optional relative offset. | |
Moveable:GetJointRotation(index) | -Get the object's joint rotation | +Get the object's joint rotation. | |
Moveable:GetRotation() | -Get the moveable's rotation | +Get the moveable's rotation. | +|
Moveable:GetScale() | +Get the moveable's visual scale. | ||
Moveable:SetRotation(rotation) | -Set the moveable's rotation | +Set the moveable's rotation. | +|
Moveable:SetScale(scale) | +Set the moveable's visual scale. | ||
Moveable:GetHP() | -Get current HP (hit points/health points) | +Get current HP (hit points / health points). | |
Moveable:SetHP(HP) | -Set current HP (hit points/health points) - Clamped to [0, 32767] for "intelligent" entities (i.e. | +Set current HP (hit points / health points). | |
Moveable:GetSlotHP() | -Get HP definded for that object type (hit points/health points) (Read Only). | +Get HP definded for that object type (hit points / health points). | |
Moveable:GetOCB() | -Get OCB (object code bit) of the moveable | +Get OCB (object code bit) of the moveable. | |
Moveable:SetOCB(OCB) | -Set OCB (object code bit) of the moveable | +Set OCB (object code bit) of the moveable. | |
Moveable:SetEffect(effect[, timeout]) | +Moveable:SetEffect(effect, [timeout]) | Set the effect for this moveable. | |
Moveable:SetCustomEffect(Color1, Color2[, timeout]) | -Set custom colored burn effect to moveable | +Moveable:SetCustomEffect(color1, color2, [timeout]) | +Set custom colored burn effect to moveable. |
Moveable:GetEffect() | -Get current moveable effect | +Get current moveable effect. | |
Moveable:GetItemFlags(index) | -Get the value stored in ItemFlags[index] | +Get the value stored in ItemFlags[index]. | |
Moveable:SetItemFlags(value, index) | -Stores a value in ItemFlags[index] | +Stores a value in ItemFlags[index]. | |
Moveable:GetLocationAI() | -Get the location value stored in the Enemy AI | +Get the location value stored in the Enemy AI. | |
Moveable:SetLocationAI(value) | @@ -236,23 +239,19 @@|||
Moveable:GetColor() | -Get the moveable's color | +Get the moveable's color. | |
Moveable:SetColor(color) | -Set the moveable's color | +Set the moveable's color. | |
Moveable:GetAIBits() | -Get AIBits of object - This will return a table with six values, each corresponding to - an active behaviour. | +Get AIBits of object. | |
Moveable:SetAIBits(bits) | -Set AIBits of object - Use this to force a moveable into a certain AI mode or modes, as if a certain nullmesh - (or more than one) had suddenly spawned beneath their feet. | +Set AIBits of object. | |
Moveable:GetState() | @@ -275,7 +274,7 @@Retrieve the index of the current animation. | ||
Moveable:SetAnim(index[, slot]) | +Moveable:SetAnim(index, [slot]) | Set the object's animation to the one specified by the given index. | |
Moveable:GetActive() | -Determine whether the moveable is active or not | +Determine whether the moveable is active or not. | |
Moveable:GetHitStatus() | @@ -308,11 +307,11 @@|||
Moveable:GetRoom() | -Get the current room of the object | +Get the current room of the moveable. | |
Moveable:GetRoomNumber() | -Get the current room number of the object | +Get the current room number of the moveable. | |
Moveable:SetRoomNumber(roomID) | @@ -328,48 +327,39 @@|||
Moveable:GetMeshCount() | -Get number of meshes for a particular object - Returns number of meshes in an object | +Get number of meshes for a particular object. | |
Moveable:GetMeshVisible(index) | -Get state of specified mesh visibility of object - Returns true if specified mesh is visible on an object, and false - if it is not visible. | +Get state of specified mesh visibility of object. | |
Moveable:SetMeshVisible(index, isVisible) | -Makes specified mesh visible or invisible - Use this to show or hide a specified mesh of an object. | +Makes specified mesh visible or invisible. | |
Moveable:ShatterMesh(index) | -Shatters specified mesh and makes it invisible - Note that you can re-enable mesh later by using SetMeshVisible(). | +Shatters specified mesh and makes it invisible. | |
Moveable:GetMeshSwapped(index) | -Get state of specified mesh swap of object - Returns true if specified mesh is swapped on an object, and false - if it is not swapped. | +Get state of specified mesh swap of object. | |
Moveable:SwapMesh(index, slotIndex[, swapIndex]) | -Set state of specified mesh swap of object - Use this to swap specified mesh of an object. | +Moveable:SwapMesh(index, slotIndex, [swapIndex]) | +Set state of specified mesh swap of object. |
Moveable:UnswapMesh(index) | -Set state of specified mesh swap of object - Use this to bring back original unswapped mesh | +Set state of specified mesh swap of object. | |
Moveable:Enable(timeout) | +Moveable:Enable([timeout]) | Enable the item, as if a trigger for it had been stepped on. | |
Moveable:Disable() | -Disable the item, as if an antitrigger for it had been stepped on (i.e. | +Disable the item, as if an antitrigger for it had been stepped on. | |
Moveable:Explode() | @@ -388,16 +378,12 @@Set the item's collision. | ||
Moveable:MakeInvisible() | -Make the item invisible. | -||
Moveable:SetVisible(visible) | Set the item's visibility. | ||
Moveable:GetValid() | -Test if the object is in a valid state (i.e. | +Test if the object is in a valid state. | |
Moveable:Destroy() | @@ -408,8 +394,8 @@Attach camera to an object. | ||
Moveable:AnimFromObject(ObjectID, animNumber, stateID) | -Borrow animation from an object | +Moveable:AnimFromObject(objectID, animNumber, stateID) | +Borrow animation from an object. |
Parameters:
-
-
- Color1 +
- color1 Color - color the primary color of the effect (also used for lighting). + The primary color of the effect (also used for lighting). -
- Color2 +
- color2 Color - color the secondary color of the effect. + The secondary color of the effect.
- timeout float - time (in seconds) after which effect turns off. - (optional) + Time (in seconds) after which effect turns off. + Optional.
-
EffectID
- Sffect type currently assigned.
+ Effect type currently assigned.
- index int - of the ItemFlags, can be between 0 and 7. + Index of the ItemFlag, can be between 0 and 7.
-
int
- the value contained in the ItemFlags[index]
+ The value contained in the ItemFlags[index].
- value short - to store in the moveable's ItemFlags[index] + Value to store in the moveable's ItemFlags[index].
- index int - of the ItemFlags where store the value. + Index of the ItemFlag where to store the value.
-
short
- the value contained in the LocationAI of the creature.
+ The value contained in the LocationAI of the creature.
- value short - to store. + Value to store.
-
Color
- a copy of the moveable's color
+ Moveable's color.
- color Color - the new color of the moveable + The new color of the moveable.
Get AIBits of object. This will return a table with six values, each corresponding to - an active behaviour. If the object is in a certain AI mode, the table will + an active behaviour. If the object is in a certain AI mode, the table will have a 1 in the corresponding cell. Otherwise, the cell will hold a 0.
-
1 - guard
-
2 - ambush
-
3 - patrol 1
-
4 - modify
-
5 - follow
-
6 - patrol 2
+
1 - Guard
+2 - Ambush
+3 - Patrol 1
+4 - Modify
+5 - Follow
+6 - Patrol 2
+
+
+
@@ -1215,7 +1248,7 @@ baddy:SetOnCollidedWithRoom(LevelFuncs.roomCollided)
-
table
- a table of AI bits
+ A table of AI bits.
- bits table - the table of AI bits + A table of AI bits.
-
int
- number of meshes
+ Number of meshes.
- index int - index of a mesh + Index of a mesh.
-
bool
- visibility status
+ Visibility status.
- index int - index of a mesh + Index of a mesh.
- isVisible bool - true if you want the mesh to be visible, false otherwise + true if you want the mesh to be visible, false otherwise.
- index int - index of a mesh + Index of a mesh to shatter.
- index int - index of a mesh + Index of a mesh.
-
bool
- mesh swap status
+ Mesh swap status.
- index int - index of a mesh + Index of a mesh.
- slotIndex int - index of a slot to get meshswap from + Index of a slot to get meshswap from.
- swapIndex int - index of a mesh from meshswap slot to use - (optional) + Index of a mesh from meshswap slot to use. + Optional.
- index int - index of a mesh to unswap + Index of a mesh to unswap.
- timeout float - time (in seconds) after which moveable automatically disables (optional). + Time (in seconds) after which moveable automatically disables. + Optional.
-
bool
- item's collision state
+ Item's collision state.
Moveable:SetVisible(false)
.
-
-
-
-
-
-
-
-
- visible bool - true if the caller should become visible, false if it should become invisible + true if the caller should become visible, false if it should become invisible.
-
bool
- valid true if the object is still not destroyed
+ true if the object is still not destroyed.
- mesh int - of a target moveable to use as a camera target + Mesh of a target moveable to use as a camera target.
- target - Moveable - moveable to attach camera to + Moveable + Target moveable to attach camera to.
- mesh int - of a target moveable to use as a camera target + Mesh of a target moveable to use as a camera target.
Parameters:
-
-
- ObjectID +
- objectID ObjID - to take animation and stateID from, + Object ID to take animation and state ID from.
- animNumber int - animation from object + Animation from object.
- stateID int - state from object + State from object.
3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer @@ -140,11 +144,11 @@
-
- Get the room's number. ()
+ Get the room's number.
@@ -194,7 +198,7 @@
Room:GetName()
- - Get the room's unique string identifier. () + Get the room's unique string identifier. @@ -215,7 +219,7 @@ Room:GetColor()
- - Get the room's ambient light color. () + Get the room's ambient light color. @@ -236,7 +240,7 @@ Room:GetReverbType()
- - Get the room's reverb type. () + Get the room's reverb type. @@ -257,7 +261,7 @@ Room:SetName(name)
- - Set the room's unique string identifier. () + Set the room's unique string identifier. @@ -276,18 +280,18 @@
- - Get the room's unique string identifier. () + Get the room's unique string identifier. @@ -215,7 +219,7 @@ Room:GetColor()
- - Room:SetReverbType(Reverb) + Room:SetReverbType(reverb)
-
- Set the room's reverb type. ()
+ Set the room's reverb type.
Parameters:
-
-
- Reverb +
- reverb RoomReverb - type. + Reverb type.
- - Room:SetFlag(flagID, Boolean) + Room:SetFlag(flagID, value)
-
- Set the room's specified flag. ()
+ Set the room's specified flag.
@@ -311,9 +315,9 @@
RoomFlagID
Room flag ID.
-
- Boolean +
- value bool - to set the flag to. + Boolean to set the flag to.
@@ -327,7 +331,7 @@ Room:GetFlag(flagID)- - Get the room's specified flag value (true or false). () + Get the room's specified flag value (true or false). @@ -349,7 +353,7 @@ Room:IsTagPresent(tag)
- - Check if the specified tag is set for the room. () + Check if the specified tag is set for the room. @@ -377,7 +381,7 @@ Room:GetActive()
- - Check if the room is active. () + Check if the room is active. diff --git a/Documentation/doc/2 classes/Objects.Sink.html b/Documentation/doc/2 classes/Objects.Sink.html index 9ec996ac9..67e467d19 100644 --- a/Documentation/doc/2 classes/Objects.Sink.html +++ b/Documentation/doc/2 classes/Objects.Sink.html @@ -3,7 +3,7 @@ -
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer diff --git a/Documentation/doc/2 classes/Objects.SoundSource.html b/Documentation/doc/2 classes/Objects.SoundSource.html index 34d46d407..1ff54349a 100644 --- a/Documentation/doc/2 classes/Objects.SoundSource.html +++ b/Documentation/doc/2 classes/Objects.SoundSource.html @@ -3,7 +3,7 @@ -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer @@ -121,28 +125,27 @@
-
- Get the sound source's position
+ Get the sound source's position.
@@ -167,7 +170,7 @@
-
Vec3
- a copy of the sound source's position
+ Sound source's position.
- - Set the sound source's position + Set the sound source's position. @@ -187,7 +190,7 @@
- position Vec3 - the new position of the sound source + The new position of the sound source.
- - Get the sound source's unique string identifier + Get the sound source's unique string identifier. @@ -210,7 +213,7 @@
-
string
- the sound source's name
+ The sound source's name.
- - Set the sound source's name (its unique string identifier) + Set the sound source's unique string identifier. @@ -230,7 +233,7 @@
- name string - The sound source's new name + The sound source's new name.
- - Get the sound source's unique int identifier + Get the sound source's sound ID. @@ -253,7 +256,7 @@
-
int
- the ID of the sound
+ The ID of the sound.
- - Set the sound source's ID - TODO this and getSoundID should use enums + Set the sound source's ID. @@ -274,7 +276,7 @@
- name int - The sound source's new name + The sound source's new sound ID.
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer @@ -152,6 +156,10 @@
Get this static's visibility status. - - Set the sound source's position + Set the sound source's position. @@ -187,7 +190,7 @@
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
SoundSource:GetPosition() -Get the sound source's position +Get the sound source's position. SoundSource:SetPosition(position) -Set the sound source's position +Set the sound source's position. SoundSource:GetName() -Get the sound source's unique string identifier +Get the sound source's unique string identifier. SoundSource:SetName(name) -Set the sound source's name (its unique string identifier) +Set the sound source's unique string identifier. SoundSource:GetSoundID() -Get the sound source's unique int identifier +Get the sound source's sound ID. SoundSource:SetSoundID(name) -Set the sound source's ID - TODO this and getSoundID should use enums +Set the sound source's ID.
-
bool
- Status. true: visible, false: invisible
+ Status. true means visible, false otherwise.
+
Returns:
+-
+
+ bool
+ Collision status. true if can be collided with, false otherwise.
-
bool
- Solid Status. true: solid, false: soft
+ Solid Status. true if solid, false if soft.
- status bool - New status. true: solid, false: soft + New status, true is solid, false is soft. + +
Parameters:
+-
+
- collidable + bool + New collision status. true if can be collided with, false: no collision.
3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer @@ -156,7 +160,7 @@
-
- Get the unique string identifier of this volume. ()
+ Get the unique string identifier of this volume.
@@ -206,7 +210,7 @@
Volume:GetPosition()
- - Get the position of this volume. () + Get the position of this volume. @@ -227,7 +231,7 @@ Volume:GetRotation()
- - Get the rotation of this volume. () + Get the rotation of this volume. @@ -248,7 +252,7 @@ Volume:GetScale()
- - Get this scale of this volume. () + Get this scale of this volume. @@ -269,7 +273,7 @@ Volume:SetName(name)
- - Set the unique string identifier of this volume. () + Set the unique string identifier of this volume. @@ -291,7 +295,7 @@ Volume:SetPosition(pos)
- - Set the position of this volume. () + Set the position of this volume. @@ -313,7 +317,7 @@ Volume:SetRotation(rot)
- - Set the rotation of this volume. () + Set the rotation of this volume. @@ -335,7 +339,7 @@ Volume:SetScale(scale)
- - Set the scale of the volume. () + Set the scale of the volume. @@ -357,7 +361,7 @@ Volume:GetActive()
- - Determine if this volume is active. () + Determine if this volume is active. @@ -375,18 +379,18 @@
- - Get the position of this volume. () + Get the position of this volume. @@ -227,7 +231,7 @@ Volume:GetRotation()
- - Volume:IsMoveableInside(Moveable) + Volume:IsMoveableInside(moveable)
-
- Determine if a moveable is inside this volume. ()
+ Determine if a moveable is inside this volume.
Parameters:
-
-
- Moveable +
- moveable Moveable - to be checked for containment. + Moveable to be checked for containment.
- - Enable this volume. () + Enable this volume. @@ -421,7 +425,7 @@ Volume:Disable()
- - Disable this volume. () + Disable this volume. @@ -436,7 +440,7 @@ Volume:ClearActivators()
- - Clear the activators for this volume, allowing it to trigger again. () + Clear the activators for this volume, allowing it to trigger again. diff --git a/Documentation/doc/2 classes/Strings.DisplayString.html b/Documentation/doc/2 classes/Strings.DisplayString.html index c4c42536d..958d506a8 100644 --- a/Documentation/doc/2 classes/Strings.DisplayString.html +++ b/Documentation/doc/2 classes/Strings.DisplayString.html @@ -3,7 +3,7 @@ -
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer @@ -125,23 +129,23 @@ when you need to use screen-space coordinates.
- - DisplayString(string, Position[, scale][, color][, translated], table) + DisplayString(string, position, [scale], [color], [translated], [flags])
-
Create a DisplayString.
@@ -193,29 +193,30 @@ For use in ShowString and string
The string to display or key of the translated string.
-
- Position +
- position Vec2 - of the string in pixel coordinates. + Position of the string in pixel coordinates.
- scale float - size of the string, relative to the default size. Default: 1.0 - (optional) + Size of the string, relative to the default size. + Default: 1.
- color Color - the color of the text. Default: white - (optional) + The color of the text. + Default: Color(255, 255, 255).
- translated bool If false or omitted, the input string argument will be displayed. -If true, the string argument will be the key of a translated string specified in strings.lua. Default: false. - (optional) +If true, the string argument will be the key of a translated string specified in strings.lua. + Default: false.
-- table +
- flags DisplayStringOption - Default: None. Please note that Strings are automatically aligned to the LEFT + Flags which affect visual representation of a string, such as shadow or alignment. + Optional.
Functions
- DisplayString(string, Position[, scale][, color][, translated], table) +DisplayString(string, position, [scale], [color], [translated], [flags]) Create a DisplayString. DisplayString:GetColor() -Get the display string's color +Get the display string's color. DisplayString:SetColor(color) -Set the display string's color +Set the display string's color. DisplayString:GetKey() -Get the string key to use. +Get the string key. - DisplayString:SetKey(string) +DisplayString:SetKey(key) Set the string key to use. @@ -162,11 +166,7 @@ when you need to use screen-space coordinates. DisplayString:SetFlags(table) -Set the display string's flags -- DisplayString:SetTranslated(shouldTranslate) -Set translated parameter of the string +Set the display string's flags. - - Get the display string's color + Get the display string's color. @@ -244,7 +245,7 @@ If true, the string argument will be the key of a translated string specified in
-
Color
- a copy of the display string's color
+ Display string's color.
- - Set the display string's color + Set the display string's color. @@ -264,7 +265,7 @@ If true, the string argument will be the key of a translated string specified in
- color Color - the new color of the display string + The new color of the display string.
- - Get the string key to use. If
isTranslated
is true when DisplayString - is called, this will be the string key for the translation that will be displayed. - If false or omitted, this will be the string that's displayed.() + Get the string key. @@ -289,7 +288,7 @@ If true, the string argument will be the key of a translated string specified in-
string
- the string to use
+ The string key.
- - DisplayString:SetKey(string) + DisplayString:SetKey(key)
-
- Set the string key to use. If
isTranslated
is true when DisplayString - is called, this will be the string key for the translation that will be displayed. - If false or omitted, this will be the string that's displayed.() + Set the string key to use.Parameters:
-
-
- string +
- key string - the new key for the display string + The new key for the display string.
- - Set the scale of the string. () + Set the scale of the string. @@ -347,7 +344,7 @@ If true, the string argument will be the key of a translated string specified in DisplayString:GetScale()
- - Get the scale of the string. () + Get the scale of the string. @@ -369,7 +366,7 @@ If true, the string argument will be the key of a translated string specified in
- Set the position of the string. - Screen-space coordinates are expected.() + Screen-space coordinates are expected. @@ -392,7 +389,7 @@ If true, the string argument will be the key of a translated string specified in
- Get the position of the string. - Screen-space coordinates are returned.() + Screen-space coordinates are returned. @@ -413,7 +410,7 @@ If true, the string argument will be the key of a translated string specified in DisplayString:SetFlags(table)
- - Set the display string's flags () + Set the display string's flags. @@ -421,7 +418,7 @@ If true, the string argument will be the key of a translated string specified in
-- table table - the new table with display flags options + The new table with display flags options.
- - - DisplayString:SetTranslated(shouldTranslate) - -
-
- Set translated parameter of the string
-
-
-
-
Parameters:
--
-
- shouldTranslate - bool - if true, the string's key will be used as the key for the translation that will be displayed. - If false, the key itself will be displayed - -
diff --git a/Documentation/doc/2 classes/View.DisplaySprite.html b/Documentation/doc/2 classes/View.DisplaySprite.html
index 28b4952ab..9347dded9 100644
--- a/Documentation/doc/2 classes/View.DisplaySprite.html
+++ b/Documentation/doc/2 classes/View.DisplaySprite.html
@@ -3,7 +3,7 @@
- - Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer @@ -120,10 +124,14 @@
- - DisplaySprite(ID, int, pos, rot, scale[, color]) + DisplaySprite(objectID, index, pos, rot, scale, [color])
-
- Create a DisplaySprite object. ()
+ Create a DisplaySprite object.
Parameters:
-
-
- ID - ObjID - of the sprite sequence object. +
- objectID + SpriteConstants + ID of the sprite sequence object. -
- int +
- index int - spriteID ID of the sprite in the sequence. + Index of the sprite in the sequence.
- pos Vec2 @@ -217,8 +225,8 @@
- color Color - Color. Default: Color(255, 255, 255, 255) - (optional) + Color. + Default: Color(255, 255, 255).
+ - + + DisplaySprite(pos, rot, scale, [color]) + +
-
+ Create a DisplaySprite object with a video image.
+ Video should be played using View.PlayVideo function in a background mode. If no video is played, sprite will not show.
+
+
+
+
Parameters:
+-
+
- pos + Vec2 + Display position in percent. + +
- rot + float + Rotation in degrees. + +
- scale + Vec2 + Horizontal and vertical scale in percent. Scaling is interpreted by the DisplaySpriteEnum.ScaleMode passed to the Draw() function call. + +
- color + Color + Color. Default: Color(255, 255, 255, 255) + Optional. + +
Returns:
+-
+
+ DisplaySprite
+ A new DisplaySprite object with attached video image.
+
- DisplaySprite:GetObjectID()
-
- Get the object ID of the sprite sequence object used by the display sprite. ()
+ Get the object ID of the sprite sequence object used by the display sprite.
@@ -246,7 +296,7 @@
Returns:
-
- ObjID
+ SpriteConstants
Sprite sequence object ID.
- - Get the sprite ID in the sprite sequence object used by the display sprite. () + Get the sprite ID in the sprite sequence object used by the display sprite. @@ -268,7 +318,7 @@
-
int
- Sprite ID in the sprite sequence object.
+ Sprite ID in the sprite sequence object. Value -1 means that it is a background video, played using View.PlayVideo.
- - Get the display position of the display sprite in percent. () + Get the display position of the display sprite in percent. @@ -301,7 +351,7 @@ DisplaySprite:GetRotation()
- - Get the rotation of the display sprite in degrees. () + Get the rotation of the display sprite in degrees. @@ -322,7 +372,7 @@ DisplaySprite:GetScale()
- - Get the horizontal and vertical scale of the display sprite in percent. () + Get the horizontal and vertical scale of the display sprite in percent. @@ -343,7 +393,7 @@ DisplaySprite:GetColor()
- - Get the color of the display sprite. () + Get the color of the display sprite. @@ -361,18 +411,18 @@
- - Get the sprite ID in the sprite sequence object used by the display sprite. () + Get the sprite ID in the sprite sequence object used by the display sprite. @@ -268,7 +318,7 @@
- - DisplaySprite:SetObjectID(New) + DisplaySprite:SetObjectID(objectID)
-
- Set the sprite sequence object ID used by the display sprite. (Objects.ObjID)
+ Set the sprite sequence object ID used by the display sprite.
Parameters:
-
-
- New - ObjID - sprite sequence object ID. +
- objectID + SpriteConstants + New sprite sequence object ID.
- - DisplaySprite:SetSpriteID(New) + DisplaySprite:SetSpriteID(spriteID)
-
- Set the sprite ID in the sprite sequence object used by the display sprite. (int)
+ Set the sprite ID in the sprite sequence object used by the display sprite.
Parameters:
-
-
- New +
- spriteID int - sprite ID in the sprite sequence object. + New sprite ID in the sprite sequence object.
- - DisplaySprite:SetPosition(New) + DisplaySprite:SetPosition(position)
-
- Set the display position of the display sprite in percent. (Vec2)
+ Set the display position of the display sprite in percent.
Parameters:
-
-
- New +
- position Vec2 - display position in percent. + New display position in percent.
- - DisplaySprite:SetRotation(New) + DisplaySprite:SetRotation(rotation)
-
- Set the rotation of the display sprite in degrees. (float)
+ Set the rotation of the display sprite in degrees.
Parameters:
-
-
- New +
- rotation float - rotation in degrees. + New rotation in degrees.
- - DisplaySprite:SetScale(New) + DisplaySprite:SetScale(scale)
-
- Set the horizontal and vertical scale of the display sprite in percent. (Vec2)
+ Set the horizontal and vertical scale of the display sprite in percent.
Parameters:
-
-
- New +
- scale float - horizontal and vertical scale in percent. + New horizontal and vertical scale in percent.
- - DisplaySprite:SetColor(New) + DisplaySprite:SetColor(color)
-
- Set the color of the display sprite. (Color)
+ Set the color of the display sprite.
Parameters:
-
-
- New - float - color. +
- color + Color + New color.
- - DisplaySprite:Draw([priority][, alignMode][, scaleMode][, blendMode]) + DisplaySprite:Draw([priority], [alignMode], [scaleMode], [blendMode])
-
Draw the display sprite in display space for the current frame.
@@ -504,23 +554,23 @@
- priority int - Draw priority. Can be thought of as a layer, with higher values having precedence. Default: 0 - (optional) + Draw priority. Can be thought of as a layer, with higher values having precedence. + Default: 0.
- alignMode AlignMode - Align mode interpreting an offset from the sprite's position. Default: View.AlignMode.CENTER - (optional) + Align mode interpreting an offset from the sprite's position. + Default: View.AlignMode.CENTER.
- scaleMode ScaleMode - Scale mode interpreting the display sprite's horizontal and vertical scale. Default: View.ScaleMode.FIT - (optional) + Scale mode interpreting the display sprite's horizontal and vertical scale. + Default: View.ScaleMode.FIT.
- blendMode BlendID - Blend mode. Default: Effects.BlendID.ALPHABLEND - (optional) + Blend mode. + Default: Effects.BlendID.ALPHABLEND.
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer @@ -236,15 +240,15 @@
- R int - red component + Red component.
- G int - green component + Green component.
- B int - blue component + Blue component.
-
Flow.Fog
+ - Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer @@ -111,31 +115,29 @@
-
- (Color) RGB fog color
+ (Color) RGB fog color.
@@ -169,8 +171,8 @@
minDistance
- - (int) min distance. - This is the distance at which the fog starts.* + (float) Minimum distance. + This is the distance at which the fog starts (in sectors). @@ -185,8 +187,8 @@ maxDistance
- - (int) max distance. - This is the distance at which the fog reaches the maximum strength. + (float) Maximum distance. + This is the distance at which the fog reaches the maximum strength (in sectors). @@ -202,7 +204,7 @@
- - Fog(color, Min, Max) + Fog(color, min, max)
-
@@ -217,13 +219,13 @@
Color
RGB color
-
- Min +
- min int - Distance fog starts (in Sectors) + Distance at which fog starts (in sectors).
-- Max +
- max int - Distance fog ends (in Sectors) + Distance at which fog reaches the maximum strength (in sectors).
diff --git a/Documentation/doc/3 primitive classes/Flow.Horizon.html b/Documentation/doc/3 primitive classes/Flow.Horizon.html new file mode 100644 index 000000000..f0eebb4e5 --- /dev/null +++ b/Documentation/doc/3 primitive classes/Flow.Horizon.html @@ -0,0 +1,281 @@ + + + + +TombEngine 1.8.2 Lua API + + + + ++ ++ + diff --git a/Documentation/doc/3 primitive classes/Flow.InventoryItem.html b/Documentation/doc/3 primitive classes/Flow.InventoryItem.html index ac010c2e2..ba857b892 100644 --- a/Documentation/doc/3 primitive classes/Flow.InventoryItem.html +++ b/Documentation/doc/3 primitive classes/Flow.InventoryItem.html @@ -3,7 +3,7 @@ -+ ++ + ++ ++ + + + ++ + ++ ++Primitive Class
+Flow.Horizon
Represents a horizon.
+To be used with Flow.Level.horizon1 and Flow.Level.horizon2 properties.
+ + +Members
++
++ +enabled +(bool) Horizon enabled state. ++ +objectID +(Objects.ObjID) Horizon object ID. ++ +position +(Vec3) Horizon position. ++ +rotation +(Rotation) Horizon rotation. ++ +transparency +(float) Horizon transparency. +Functions
++
+ ++ +Horizon(objectID) +Create a horizon object. +
+
+ + +Members
+ +-
+
- + + enabled + +
- + (bool) Horizon enabled state. + If set to true, horizon will be visible. + + + + + + + + + +
- + + objectID + +
- + (Objects.ObjID) Horizon object ID. + + + + + + + + + +
- + + position + +
- + (Vec3) Horizon position. + Specifies an offset from the camera origin. + + + + + + + + + +
- + + rotation + +
- + (Rotation) Horizon rotation. + Specifies horizon rotation. + + + + + + + + + +
- + + transparency + +
- + (float) Horizon transparency. + Specifies horizon transparency on a range from 0 to 1. + + + + + + + + + +
Functions
+ + + + ++generated by TEN-LDoc (a fork of LDoc 1.4.6) ++TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
-
Flow.InventoryItem - Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer @@ -112,9 +116,7 @@
- nameKey
string
- key for the item's (localised) name.
-Corresponds to an entry in strings.lua. + key for the item's (localised) name. Corresponds to an entry in strings.lua. - objectID ObjID @@ -165,7 +166,7 @@ and a value of 2 will cause the item to render at twice the size.
- rot Rotation - rotation around x, y, and z axes + rotation around x, y, and z axes.
- axis RotationAxis @@ -180,7 +181,7 @@ Z
- meshBits int - Not currently implemented (will have no effect regardless of what you set it to) + Not currently implemented (will have no effect regardless of what you set it to).
- action
ItemAction
@@ -199,7 +200,7 @@ EXAMINE
-
InventoryItem
- an InventoryItem
+ an InventoryItem.
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
-
Flow.LensFlare - Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer @@ -112,65 +116,130 @@
- + + enabled + +
- + (bool) Lens flare enabled state. + If set to true, lens flare will be visible. + + + + + + + + + +
- + + spriteID + +
- + (int) Lens flare's sun sprite ID in DEFAULT_SPRITES sequence. + + + + + + + + + +
- + + pitch + +
- + (float) Lens flare's pitch (vertical) angle in degrees. + + + + + + + + + +
- + + yaw + +
- + (float) Lens flare's yaw (horizontal) angle in degrees. + + + + + + + + + +
- + + color + +
- + (Color) Lens flare's color. + + + + + + + + + +
- - LensFlare(Pitch, Yaw, Color.) + LensFlare(pitch, yaw, color)
-
Create a LensFlare object.
@@ -179,19 +248,16 @@
Parameters:
-
-
- Pitch +
- pitch float - angle in degrees. + Pitch angle in degrees. -
- Yaw +
- yaw float - angle in degrees. + Yaw angle in degrees. -
- Color. - Color - - - +
- color + Color of the lensflare.
- - - - LensFlare:GetSunSpriteID() - -
-
- Get this lens flare's sun sprite ID.
-
-
-
-
-
Returns:
--
-
- int
- Sprite ID.
-
- - - - LensFlare:GetPitch() - -
-
- Get this lens flare's pitch angle in degrees.
-
-
-
-
-
Returns:
--
-
- float
- Pitch angle in degrees.
-
- - - - LensFlare:GetYaw() - -
-
- Get this lens flare's yaw angle in degrees.
-
-
-
-
-
Returns:
--
-
- float
- Yaw angle in degrees.
-
- - - - LensFlare:GetColor() - -
- - Get the lens flare's color. - - - - - - - - - -
- - - LensFlare:GetEnabled() - -
-
- Get this lens flare's enabled status.
-
-
-
-
-
Returns:
--
-
- bool
- Enabled status. true: enabled, false: disabled
-
- - - - LensFlare:SetSunSpriteID(New) - -
-
- Set this lens flare's sun sprite ID.
-
-
-
-
Parameters:
--
-
- New - int - sun sprite ID. - -
- - - - LensFlare:SetPitch(New) - -
-
- Set this lens flare's pitch angle.
-
-
-
-
Parameters:
--
-
- New - float - pitch angle in degrees. - -
- - - - LensFlare:SetYaw(New) - -
-
- Set this lens flare's yaw angle.
-
-
-
-
Parameters:
--
-
- New - float - yaw angle in degrees. - -
- - - - LensFlare:SetColor(New) - -
-
- Set this lens flare's color.
-
-
-
-
Parameters:
--
-
- New - Color - color. - -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
-
Flow.SkyLayer
@@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer @@ -112,18 +116,18 @@
-
- (Color) RGB sky color
+ (Color) RGB sky color.
@@ -163,7 +167,7 @@
speed
- - (int) cloud speed. + (int) Cloud speed.
Values can be between [-32768, 32767], with positive numbers resulting in a sky that scrolls from west to east, and negative numbers resulting in one that travels east to west. @@ -201,11 +205,11 @@
- color Color - RGB color + RGB color.
- speed int - cloud speed + Cloud speed.
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer @@ -111,12 +115,29 @@
- + + starCount + +
- + (int) Amount of visible stars. + + + + + + + + + +
- + + meteorCount + +
- + (int) Amount of visible meteors. + + + + + + + + + +
- + + meteorSpawnDensity + +
- + (int) Meteor spawn density. + + + + + + + + + +
- + + meteorVelocity + +
- + (int) Meteor velocity. + + + + + + + + + +
- - Starfield(starCount, meteorCount) + Starfield(starCount, meteorCount, meteorSpawnDensity, meteorVel)
-
Create a starfield object with stars and meteors.
@@ -223,6 +268,14 @@
int
Meteor count. Max: 100
+
- meteorSpawnDensity + int + Meteor spawn density. +
+- meteorVel + int + Meteor velocity. +
Returns:
@@ -235,220 +288,6 @@ -
- - - - Starfield:GetStarCount() - -
-
- Get this starfield's number of stars.
-
-
-
-
-
Returns:
--
-
- int
- Count.
-
- - - - Starfield:GetMeteorCount() - -
-
- Get this starfield's number of meteors.
-
-
-
-
-
Returns:
--
-
- int
- Count.
-
- - - - Starfield:GetMeteorSpawnDensity() - -
-
- Get this starfield's meteor spawn density.
-
-
-
-
-
Returns:
--
-
- int
- Spawn density.
-
- - - - Starfield:GetMeteorVelocity() - -
-
- Get this starfield's meteor velocity.
-
-
-
-
-
Returns:
--
-
- float
- Velocity.
-
- - - - Starfield:GetStarsEnabled() - -
-
- Get this starfield's stars enabled status.
-
-
-
-
-
Returns:
--
-
- bool
- Stars enabled status. true: enabled, false: disabled
-
- - - - Starfield:GetMeteorsEnabled() - -
-
- Get this starfield's meteors enabled status.
-
-
-
-
-
Returns:
--
-
- bool
- Meteors enabled status. true: enabled, false: disabled
-
- - - - Starfield:SetStarCount(New) - -
-
- Set this starfield's number of stars.
-
-
-
-
Parameters:
--
-
- New - int - star count. - -
- - - - Starfield:SetMeteorCount(New) - -
-
- Set this starfield's number of meteors.
-
-
-
-
Parameters:
--
-
- New - int - meteor count. - -
- - - - Starfield:SetMeteorSpawnDensity(New) - -
-
- Set this starfield's meteor spawn density.
-
-
-
-
Parameters:
--
-
- New - int - meteor spawn density. - -
- - - - Starfield:SetMeteorVelocity(New) - -
-
- Set this starfield's meteor velocity.
-
-
-
-
Parameters:
--
-
- New - float - meteor velocity. - -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer diff --git a/Documentation/doc/3 primitive classes/Time.html b/Documentation/doc/3 primitive classes/Time.html index 7b291f94d..9a671f125 100644 --- a/Documentation/doc/3 primitive classes/Time.html +++ b/Documentation/doc/3 primitive classes/Time.html @@ -3,7 +3,7 @@ -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer diff --git a/Documentation/doc/3 primitive classes/Vec2.html b/Documentation/doc/3 primitive classes/Vec2.html index 9b73f8a80..7a9e44453 100644 --- a/Documentation/doc/3 primitive classes/Vec2.html +++ b/Documentation/doc/3 primitive classes/Vec2.html @@ -3,7 +3,7 @@ -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer @@ -139,23 +143,19 @@
Primitive Class
-Flow.Starfield
Represents a starfield in the sky.
-- -
+Represents a star field in the sky.
+To be used with Flow.Level.starfield property.
+Members
++
+ +starCount +(int) Amount of visible stars. ++ +meteorCount +(int) Amount of visible meteors. ++ +meteorSpawnDensity +(int) Meteor spawn density. ++ +meteorVelocity +(int) Meteor velocity. +Functions
@@ -124,55 +145,79 @@ Create a starfield object with only stars. - -Starfield(starCount, meteorCount) +Starfield(starCount, meteorCount, meteorSpawnDensity, meteorVel) Create a starfield object with stars and meteors. - -Starfield:GetStarCount() -Get this starfield's number of stars. -- -Starfield:GetMeteorCount() -Get this starfield's number of meteors. -- -Starfield:GetMeteorSpawnDensity() -Get this starfield's meteor spawn density. -- -Starfield:GetMeteorVelocity() -Get this starfield's meteor velocity. -- -Starfield:GetStarsEnabled() -Get this starfield's stars enabled status. -- -Starfield:GetMeteorsEnabled() -Get this starfield's meteors enabled status. -- -Starfield:SetStarCount(New) -Set this starfield's number of stars. -- -Starfield:SetMeteorCount(New) -Set this starfield's number of meteors. -- -Starfield:SetMeteorSpawnDensity(New) -Set this starfield's meteor spawn density. -- Starfield:SetMeteorVelocity(New) -Set this starfield's meteor velocity. -
+Members
+ +-
+
Functions
-
@@ -206,7 +251,7 @@
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
Create a Vec2 object. - - (int) cloud speed. + (int) Cloud speed.
Primitive Class
Flow.LensFlare
Represents a global lens flare (not to be confused with the lens flare object).
-- -
+To be used with Flow.Level.lensFlare property.
+Members
++
+ +enabled +(bool) Lens flare enabled state. ++ +spriteID +(int) Lens flare's sun sprite ID in DEFAULT_SPRITES sequence. ++ +pitch +(float) Lens flare's pitch (vertical) angle in degrees. ++ +yaw +(float) Lens flare's yaw (horizontal) angle in degrees. ++ +color +(Color) Lens flare's color. +Functions
- -LensFlare(Pitch, Yaw, Color.) +LensFlare(pitch, yaw, color) Create a LensFlare object. - -LensFlare:GetSunSpriteID() -Get this lens flare's sun sprite ID. -- -LensFlare:GetPitch() -Get this lens flare's pitch angle in degrees. -- -LensFlare:GetYaw() -Get this lens flare's yaw angle in degrees. -- -LensFlare:GetColor() -Get the lens flare's color. -- -LensFlare:GetEnabled() -Get this lens flare's enabled status. -- -LensFlare:SetSunSpriteID(New) -Set this lens flare's sun sprite ID. -- -LensFlare:SetPitch(New) -Set this lens flare's pitch angle. -- -LensFlare:SetYaw(New) -Set this lens flare's yaw angle. -- LensFlare:SetColor(New) -Set this lens flare's color. -
+Members
+ +-
+
Functions
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
Primitive Class
Flow.SkyLayer
Describes a layer of moving clouds.
-As seen in TR4's City of the Dead.
+To be used with Flow.Level.layer1 and Flow.Level.layer2 properties.
Members
color -(Color) RGB sky color +(Color) RGB sky color. speed -(int) cloud speed. +(int) Cloud speed. Functions
@@ -148,7 +152,7 @@ color
Primitive Class
Flow.InventoryItem
Represents the properties of an object as it appears in the inventory.
-- -
+To be used in Flow.Level.objects list.
Functions
@@ -145,8 +147,7 @@
- - (int) min distance. - This is the distance at which the fog starts.* + (float) Minimum distance. + This is the distance at which the fog starts (in sectors). @@ -185,8 +187,8 @@ maxDistance
- - - __tostring(This) - -
-
- Metafunction. Use tostring(vector).
-
-
-
-
Parameters:
--
-
- This - Vec2 - Vec2. - -
Returns:
--
-
- string
- A string showing the X and Y components of the Vec2.
-
-
@@ -335,8 +311,8 @@
- - - Translate(dir, dist) + + Vec2:Translate(dir, dist)
- Get a copy of this Vec2 translated in the input Vec2 direction by the input distance. @@ -367,8 +343,8 @@
- - - Translate(rot, dist) + + Vec2:Translate(rot, dist)
-
Get a copy of this Vec2 translated in the direction of the input rotation in degrees by the input distance.
@@ -378,7 +354,7 @@
Parameters:
- rot - Rotation + float Rotation in degrees defining the direction.
- dist @@ -399,8 +375,8 @@
- - - Translate(rot, relOffset) + + Vec2:Translate(rot, relOffset)
- Get a copy of this Vec2 translated by an offset, where the input relative offset Vec2 is rotated according to the input rotation in degrees. @@ -594,6 +570,34 @@ + +
- + + __tostring(This) + +
-
+ Metafunction. Use tostring(vector).
+
+
+
+
Parameters:
+-
+
- This + Vec2 + Vec2. + +
Returns:
+-
+
+ string
+ A string showing the X and Y components of the Vec2.
+
diff --git a/Documentation/doc/3 primitive classes/Vec3.html b/Documentation/doc/3 primitive classes/Vec3.html
index 7976a2254..f8e233fbc 100644
--- a/Documentation/doc/3 primitive classes/Vec3.html
+++ b/Documentation/doc/3 primitive classes/Vec3.html
@@ -3,7 +3,7 @@
- - Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer diff --git a/Documentation/doc/4 enums/Collision.MaterialType.html b/Documentation/doc/4 enums/Collision.MaterialType.html index 869027788..8ed328b63 100644 --- a/Documentation/doc/4 enums/Collision.MaterialType.html +++ b/Documentation/doc/4 enums/Collision.MaterialType.html @@ -3,7 +3,7 @@ -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
-
Collision.MaterialType - Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer @@ -138,7 +142,10 @@
-
-
Table of MaterialType constants.
+Table of MaterialType constants. +
+ Corresponds to Tomb Editor texture sound material types. + To be used with Collision.Probe.GetFloorMaterialType and Collision.Probe.GetCeilingMaterialType.MUD
diff --git a/Documentation/doc/4 enums/Effects.BlendID.html b/Documentation/doc/4 enums/Effects.BlendID.html
index b6f9a497a..5c3fc42f4 100644
--- a/Documentation/doc/4 enums/Effects.BlendID.html
+++ b/Documentation/doc/4 enums/Effects.BlendID.html
@@ -3,7 +3,7 @@
- - Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
-
Effects.BlendID - Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer @@ -138,18 +142,20 @@
-
-
Table of Effects.BlendID constants.
+Table of Effects.BlendID constants. +
+ All blending modes exceptOPAQUE
,ADDITIVE
andALPHA_BLEND
will use depth sorting for applicable polygons. + This may reduce engine performance, so it is preferable to minimize usage of other blending modes.-
-
OPAQUE
- ALPHA_TEST
- ADDITIVE
- NO_DEPTH_TEST
- SUBTRACTIVE
- EXCLUDE
- SCREEN
- LIGHTEN
- ALPHA_BLEND
+ OPAQUE
- No transparency.
+ ALPHA_TEST
- So called "magenta transparency", every pixel can be either fully transparent or opaque.
+ ADDITIVE
- Standard additive blending.
+ SUBTRACTIVE
- Subtractive blending, with brighter texture areas making everything darker behind them.
+ EXCLUDE
- Produces "inversion" effect.
+ SCREEN
- Similar toADDITIVE
, but without excessive overbright.
+ LIGHTEN
- Similar toSCREEN
, but with a little different blending formula.
+ ALPHA_BLEND
- True alpha blending. Should be used for textures with gradually changing alpha values.
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
-
Effects.EffectID
+ - Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
5 Lua utility modules
-
+
- CustomBar
- Diary
- EventSequence
- Timer diff --git a/Documentation/doc/4 enums/Effects.ParticleAnimationType.html b/Documentation/doc/4 enums/Effects.ParticleAnimationType.html new file mode 100644 index 000000000..d9acddbe4 --- /dev/null +++ b/Documentation/doc/4 enums/Effects.ParticleAnimationType.html @@ -0,0 +1,172 @@ + + + + +
- + + Effects.ParticleAnimationType + +
-
+
+
Table of Effects.ParticleAnimationType type constants. To be used with particles.
+ +-
+
LOOP
- Frames loop sequentially.
+ ONE_SHOT
- Frames play once and freeze on the last frame.
+ BACK_AND_FORTH
- Frames bounce back and forth.
+ LIFE_TIME_SPREAD
- Frames are distributed over the particle's lifetime
+
+ - + + Effects.StreamerFeatherMode + +
-
+
+
Table of Effects.StreamerFeatherMode constants. + To be used with Effects.EmitStreamer function.
+ +-
+
NONE
+ CENTER
+ LEFT
+ RIGHT
+
+ - Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
-
Flow.ErrorMode - Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer @@ -142,12 +146,12 @@
TERMINATE
- print to the log file and return to the title level when any script error is hit. - This is the one you will want to go for if you want to know IMMEDIATELY if something has gone wrong.
- WARN
- print to the log file and continue running the application when a recoverable script error is hit. +TERMINATE
- Print to the log file and return to the title level when any script error is hit. + This is the one you will want to go for if you want to know immediately if something has gone wrong.
+ WARN
- Print to the log file and continue running the application when a recoverable script error is hit. Choose this one if booting to the title level is too much for you.
- SILENT
- do nothing when a recoverable script error is hit. - Think very carefully before using this setting. These error modes are here to help you to keep your scripts +SILENT
- Do nothing when a recoverable script error is hit. + Think very carefully before using this setting. These error modes are here to help you to keep your scripts working properly, but if you opt to ignore errors, you won't be alerted if you've misused a function or passed an invalid argument.- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
-
Flow.FreezeMode - Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer diff --git a/Documentation/doc/4 enums/Flow.GameStatus.html b/Documentation/doc/4 enums/Flow.GameStatus.html index 955d7a5cd..1c85193ae 100644 --- a/Documentation/doc/4 enums/Flow.GameStatus.html +++ b/Documentation/doc/4 enums/Flow.GameStatus.html @@ -3,7 +3,7 @@ -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
-
Flow.GameStatus
@@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer diff --git a/Documentation/doc/4 enums/Input.ActionID.html b/Documentation/doc/4 enums/Input.ActionID.html index ac3ba5f7e..6e112df91 100644 --- a/Documentation/doc/4 enums/Input.ActionID.html +++ b/Documentation/doc/4 enums/Input.ActionID.html @@ -3,7 +3,7 @@ -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer diff --git a/Documentation/doc/4 enums/Objects.AmmoType.html b/Documentation/doc/4 enums/Objects.AmmoType.html index 3f9711c25..114163de2 100644 --- a/Documentation/doc/4 enums/Objects.AmmoType.html +++ b/Documentation/doc/4 enums/Objects.AmmoType.html @@ -3,7 +3,7 @@ -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer diff --git a/Documentation/doc/4 enums/Objects.HandStatus.html b/Documentation/doc/4 enums/Objects.HandStatus.html index 75c3dec50..b0582d69f 100644 --- a/Documentation/doc/4 enums/Objects.HandStatus.html +++ b/Documentation/doc/4 enums/Objects.HandStatus.html @@ -3,7 +3,7 @@ -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer diff --git a/Documentation/doc/4 enums/Objects.MoveableStatus.html b/Documentation/doc/4 enums/Objects.MoveableStatus.html index edee47c8e..87325f180 100644 --- a/Documentation/doc/4 enums/Objects.MoveableStatus.html +++ b/Documentation/doc/4 enums/Objects.MoveableStatus.html @@ -3,7 +3,7 @@ -
- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer @@ -143,10 +147,10 @@
INACTIVE
- moveable is inactive (was never activated).
- ACTIVE
- moveable is active.
- DEACTIVATED
- moveable is deactivated (was previously active and later deactivated).
- INVISIBLE
- moveable is invisible.
+ INACTIVE
- Moveable is inactive (was never activated).
+ ACTIVE
- Moveable is active.
+ DEACTIVATED
- Moveable is deactivated (was previously active and later deactivated).
+ INVISIBLE
- Moveable is invisible.- Flow.Fog +
- Flow.Horizon
- Flow.InventoryItem
- Flow.LensFlare
- Flow.SkyLayer @@ -79,6 +80,8 @@
- Collision.MaterialType
- Effects.BlendID
- Effects.EffectID +
- Effects.StreamerFeatherMode +
- Effects.ParticleAnimationType
- Flow.ErrorMode
- Flow.FreezeMode
- Flow.GameStatus @@ -100,6 +103,7 @@
- CustomBar
- Diary
- EventSequence
- Timer @@ -127,6 +131,10 @@
TombEngine 1.8.2 Lua API + + + + ++ ++ + diff --git a/Documentation/doc/4 enums/Effects.StreamerFeatherMode.html b/Documentation/doc/4 enums/Effects.StreamerFeatherMode.html new file mode 100644 index 000000000..c345a047e --- /dev/null +++ b/Documentation/doc/4 enums/Effects.StreamerFeatherMode.html @@ -0,0 +1,175 @@ + + + + ++ ++ + ++ ++ + + + ++ + ++ ++Enum
+Effects.ParticleAnimationType
Constants for particle animation type constants.
+To be used with Effects.EmitAdvancedParticle function.
+ + +Tables
++
+ ++ +Effects.ParticleAnimationType +Table of Effects.ParticleAnimationType type constants. +
+
+ + +Tables
+ +-
+
+generated by TEN-LDoc (a fork of LDoc 1.4.6) ++TombEngine 1.8.2 Lua API + + + + ++ ++ + diff --git a/Documentation/doc/4 enums/Flow.ErrorMode.html b/Documentation/doc/4 enums/Flow.ErrorMode.html index 2d0b7dab7..de10d20bd 100644 --- a/Documentation/doc/4 enums/Flow.ErrorMode.html +++ b/Documentation/doc/4 enums/Flow.ErrorMode.html @@ -3,7 +3,7 @@ -+ ++ + ++ ++ + + + ++ + ++ ++Enum
+Effects.StreamerFeatherMode
Constants for feather modes.
++ +
+ + +Tables
++
+ ++ +Effects.StreamerFeatherMode +Table of Effects.StreamerFeatherMode constants. +
+
+ + +Tables
+ +-
+
+generated by TEN-LDoc (a fork of LDoc 1.4.6) ++TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
The following constants are inside Flow.ErrorMode:
-
-
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
To be used with Objects.Moveable.GetStatus and Objects.Moveable.SetStatus functions.
-
-
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
PickupConstants Objects.ObjID pickup constants.
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
Primitive Class
-Flow.Fog
Distance fog.
-- -
+Represesnts distance fog.
+To be used with Flow.Level.fog property.
Members
color -(Color) RGB fog color +(Color) RGB fog color. minDistance -(int) min distance. +(float) Minimum distance. maxDistance -(int) max distance. +(float) Maximum distance. Functions
- Fog(color, Min, Max) +Fog(color, min, max) - -__tostring(This) -Metafunction. -Vec2:Normalize() Get a copy of this Vec2 normalized to length 1. - Translate(dir, dist) +Vec2:Translate(dir, dist) Get a copy of this Vec2 translated in the input Vec2 direction by the input distance. - Translate(rot, dist) +Vec2:Translate(rot, dist) Get a copy of this Vec2 translated in the direction of the input rotation in degrees by the input distance. - Translate(rot, relOffset) +Vec2:Translate(rot, relOffset) Get a copy of this Vec2 translated by an offset, where the input relative offset Vec2 is rotated according to the input rotation in degrees. @@ -182,6 +182,10 @@ +Vec2:Length() Get the length of this Vec2. + __tostring(This) +Metafunction. +
@@ -284,34 +288,6 @@ - -TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
TombEngine 1.7.2 (Developer) Lua API +TombEngine 1.8.2 Lua API @@ -64,6 +64,7 @@3 Primitive Classes
5 Lua utility modules
-
+
3 Primitive Classes
5 Lua utility modules
-
+
Functions
DisplaySprite(ID, int, pos, rot, scale[, color]) | +DisplaySprite(objectID, index, pos, rot, scale, [color]) | Create a DisplaySprite object. |
DisplaySprite(pos, rot, scale, [color]) | +Create a DisplaySprite object with a video image. | +|
DisplaySprite:GetObjectID() | Get the object ID of the sprite sequence object used by the display sprite. | Get the color of the display sprite. |
DisplaySprite:SetObjectID(New) | +DisplaySprite:SetObjectID(objectID) | Set the sprite sequence object ID used by the display sprite. |
DisplaySprite:SetSpriteID(New) | +DisplaySprite:SetSpriteID(spriteID) | Set the sprite ID in the sprite sequence object used by the display sprite. |
DisplaySprite:SetPosition(New) | +DisplaySprite:SetPosition(position) | Set the display position of the display sprite in percent. |
DisplaySprite:SetRotation(New) | +DisplaySprite:SetRotation(rotation) | Set the rotation of the display sprite in degrees. |
DisplaySprite:SetScale(New) | +DisplaySprite:SetScale(scale) | Set the horizontal and vertical scale of the display sprite in percent. |
DisplaySprite:SetColor(New) | +DisplaySprite:SetColor(color) | Set the color of the display sprite. |
DisplaySprite:Draw([priority][, alignMode][, scaleMode][, blendMode]) | +DisplaySprite:Draw([priority], [alignMode], [scaleMode], [blendMode]) | Draw the display sprite in display space for the current frame. |