Merge branch 'MontyTRC89:develop' into develop

This commit is contained in:
davidmarr 2024-11-24 13:04:23 +01:00 committed by GitHub
commit ef1a7d2d0f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
196 changed files with 4025 additions and 2145 deletions

View file

@ -6,20 +6,54 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
## Version 1.6 - xxxx-xx-xx ## Version 1.6 - xxxx-xx-xx
### Bug fixes ### Bug fixes
* Fixed engine performance around bridges.
* Fixed engine performance around multiple stacked bridges. * Fixed engine performance if weather or bubble effects are active.
* Fixed engine performance if weather effects are active. * Fixed silent crashes if loaded level is corrupted or in incorrect format.
* Fixed occasional crashes if there are static meshes placed within room border walls.
* Fixed incorrect clipping of scaled off-centered static meshes.
* Fixed incorrect collision detection for off-centered moveables.
* Fixed stutter during jumps between cameras in a flyby sequence.
* Fixed uzi targeting issues after using flycheat.
* Fixed snow particles not always melting on the ground. * Fixed snow particles not always melting on the ground.
* Fixed enemy pickups dropping on death sectors. * Fixed enemy pickups dropping on death sectors.
* Fixed Sarcophagus and Search Object pickup triggers.
* Fixed vehicle transfer not happening for levels which were not previously visited.
* Fixed audio tracks placed in subfolders not restoring after loading savegame.
* Fixed initial position and lack of fade-in for looped audio track on level start.
* Fixed scripted input events not registering on the same game frame.
* Fixed incorrect object camera position.
* Fixed incorrect camera movement near walls after leaving look mode.
* Fixed binocular or lasersight camera not switching off correctly after flyby.
* Fixed Lara's Home entry not working.
* Fixed exploding TR3 bosses.
* Fixed original issue with deactivation of Dart Emitter.
* Fixed Lens Flare object not functioning properly.
* Fixed lens flares not being occluded by static meshes and moveables.
* Fixed Skeleton and Mummy not reacting to shotgun hits.
### Features/Amendments ### New Features
* Added fast savegame reloading.
* Added ricochet sounds and make the effect more prominent.
* Allow to run the engine without title level.
* Allow more than 1024 objects in a level.
* Allow more than 1000 static mesh slots in a level.
### Lua API changes ### Lua API changes
* Added Moveable:GetCollidable() and Moveable:SetCollidable() functions.
* Added Flow.GetFreezeMode() and Flow.SetFreezeMode() functions.
* Added Flow.GetNextLevel() function to get script entry for incoming level, if it's about to start.
* Added Effects.GetWind() function to get current wind speed vector.
* Added support for transparency value in DisplayString class.
* Added extra argument for SetAmbientTrack() function to specify if new ambient track should play from the beginning.
* Use load camera instead of load screen by playing fixed camera from OnEnd() event and removing loadScreenFile field from level's gameflow entry.
* Fixed DisplayString class not supporting some Unicode characters and empty lines in multiline strings.
* Fixed incorrect behaviour of Logic.EnableEvent() and Logic.DisableEvent() functions.
* Fixed Util.HasLineOfSight() not taking static meshes into consideration.
* Fixed collision callbacks not properly clearing after leveljump.
## [Version 1.5](https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.7.2) - 2024-11-03 ## [Version 1.5](https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.7.2) - 2024-11-03
### Bug fixes ### Bug fixes
* Fixed original issue with classic switch off trigger incorrectly activating some trigger actions. * Fixed original issue with classic switch off trigger incorrectly activating some trigger actions.
* Fixed moveable status after antitriggering. * Fixed moveable status after antitriggering.
* Fixed leveljump vehicle transfer. * Fixed leveljump vehicle transfer.
@ -57,8 +91,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
* Fixed display sprites and display strings rendering in the inventory background. * Fixed display sprites and display strings rendering in the inventory background.
* Fixed young Lara hair drawing. https://tombengine.com/docs/level-settings/#young_lara * Fixed young Lara hair drawing. https://tombengine.com/docs/level-settings/#young_lara
### Features/Amendments ### New Features
* Added high framerate mode (also known as 60 FPS mode). * Added high framerate mode (also known as 60 FPS mode).
* Added a customisable global lensflare effect. https://tombengine.com/docs/level-settings/#lensflare * Added a customisable global lensflare effect. https://tombengine.com/docs/level-settings/#lensflare
* Added a customisable starry sky and meteor effect. https://tombengine.com/docs/level-settings/#stars * Added a customisable starry sky and meteor effect. https://tombengine.com/docs/level-settings/#stars
@ -87,14 +120,13 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
* Removed original limit of 32 active Flame Emitters. * Removed original limit of 32 active Flame Emitters.
### Lua API changes ### Lua API changes
* Added Flow.EnableHomeLevel() function. * Added Flow.EnableHomeLevel() function.
* Added Flow.IsStringPresent() function. * Added Flow.IsStringPresent() function.
* Added Flow.LensFlare() and Flow.Starfield() classes. * Added Flow.LensFlare() and Flow.Starfield() classes.
* Added Inventory.GetUsedItem(), Inventory.SetUsedItem() and Inventory.ClearUsedItem() functions. * Added Inventory.GetUsedItem(), Inventory.SetUsedItem() and Inventory.ClearUsedItem() functions.
* Added Input.KeyClearAll() function. * Added Input.KeyClearAll() function.
* Added Moveable.GetJointRotation() and optional 'offset' parameter for Moveable.GetJointPosition(). * Added Moveable:GetJointRotation() and optional 'offset' parameter for Moveable.GetJointPosition().
* Added Moveable.GetTargetState() function. * Added Moveable:GetTargetState() function.
* Added Room:GetRoomNumber() function. * Added Room:GetRoomNumber() function.
* Removed anims.monkeyAutoJump. It is now a player menu configuration. * Removed anims.monkeyAutoJump. It is now a player menu configuration.
* Fixed Volume:GetActive() method. * Fixed Volume:GetActive() method.
@ -119,7 +151,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
* Fixed bottom collision for solid static meshes. * Fixed bottom collision for solid static meshes.
* Fixed T-Rex's head rotation. * Fixed T-Rex's head rotation.
### Features/Amendments ### New Features
* Auto-switch to a crawl state if player start position is in a crawlspace. * Auto-switch to a crawl state if player start position is in a crawlspace.
* Allow directional flame emitter (negative OCBs) to be rotated at any angle. * Allow directional flame emitter (negative OCBs) to be rotated at any angle.
* Revise wall spikes: * Revise wall spikes:
@ -166,7 +198,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
* Fixed incorrect light collection in some cases. * Fixed incorrect light collection in some cases.
* Fixed normal mapping for rooms, items, and statics.' * Fixed normal mapping for rooms, items, and statics.'
### Features/Amendments ### New Features
* Added ambient occlusion (SSAO). * Added ambient occlusion (SSAO).
* Added new post-process workflow (monochrome, negative, exclusion) with tinting. * Added new post-process workflow (monochrome, negative, exclusion) with tinting.
* Added SMAA antialiasing instead of MSAA. * Added SMAA antialiasing instead of MSAA.
@ -225,7 +257,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
* Fix camera snap when disengaging the look-around mode. * Fix camera snap when disengaging the look-around mode.
* Fix TR4 mapper not being visible. * Fix TR4 mapper not being visible.
### Features/Amendments ### New Features
* Improve head-on wall collision. * Improve head-on wall collision.
* Overhaul pushables: * Overhaul pushables:
- Separate climbable and non-climbable pushable object slots. - Separate climbable and non-climbable pushable object slots.
@ -308,7 +340,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
* Fix incorrect culling for scaled static meshes. * Fix incorrect culling for scaled static meshes.
* Fix normal mapping. * Fix normal mapping.
### Features/Amendments ### New Features
* Add ability to save screenshot in the "Screenshots" subfolder by pressing the "Print screen" key. * Add ability to save screenshot in the "Screenshots" subfolder by pressing the "Print screen" key.
* Implement separate audio track channel for playing voiceovers with subtitles in .srt format. * Implement separate audio track channel for playing voiceovers with subtitles in .srt format.
* Don't stop ambience when Lara dies. * Don't stop ambience when Lara dies.
@ -356,7 +388,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
* Fix rendering for static meshes with custom blending modes and alpha transparency. * Fix rendering for static meshes with custom blending modes and alpha transparency.
* Fix inconsistent multiline string spacing on different display modes. * Fix inconsistent multiline string spacing on different display modes.
### Features/Amendments ### New Features
* Remove search object 4 hardcoded meshswap activated with a flipmap. * Remove search object 4 hardcoded meshswap activated with a flipmap.
* Add TR1 cowboy. * Add TR1 cowboy.
* Add TR3 wall mounted blade. * Add TR3 wall mounted blade.
@ -414,7 +446,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
- Please note you must use the patched version found here: https://github.com/TombEngine/Resources/blob/main/Wad2%20Objects/tr5_Imp.wad2 - Please note you must use the patched version found here: https://github.com/TombEngine/Resources/blob/main/Wad2%20Objects/tr5_Imp.wad2
* Fix and improve wraith tails. * Fix and improve wraith tails.
### Features/Amedments ### New Features/Amedments
* Add dedicated WRAITH_TRAP object with enhanced effects. * Add dedicated WRAITH_TRAP object with enhanced effects.
- OCB 0: Effect disabled. - OCB 0: Effect disabled.
- OCB 1: Effect enabled. - OCB 1: Effect enabled.
@ -463,7 +495,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
* Fix TR3 big gun spawning rocket with 0 life which caused an immediate explosion. * Fix TR3 big gun spawning rocket with 0 life which caused an immediate explosion.
* Fix TR3 Tony and add boss effect for him. * Fix TR3 Tony and add boss effect for him.
### Features/Amendments ### New Features
* Add TR3 civvy. * Add TR3 civvy.
* Add TR3 electric cleaner. * Add TR3 electric cleaner.
* Add TR3 Sophia Leigh with following OCBs: * Add TR3 Sophia Leigh with following OCBs:
@ -515,7 +547,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
* Fix grenade and rocket launcher lighting. * Fix grenade and rocket launcher lighting.
* Fix ceiling trapdoor and floor trapdoor that Lara couldn't open manually. * Fix ceiling trapdoor and floor trapdoor that Lara couldn't open manually.
### Features/Amendments ### New Features
* Make enemies drop pickups at first available bounding box corner point, not centerpoint. * Make enemies drop pickups at first available bounding box corner point, not centerpoint.
* Restore original volumetric explosion effects. * Restore original volumetric explosion effects.
* Add TR3 lizard and Puna. * Add TR3 lizard and Puna.
@ -567,7 +599,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
* Fix bone rotations of some entities. * Fix bone rotations of some entities.
* Fix Lara's animation for cog switch release. * Fix Lara's animation for cog switch release.
### Features/Amendments ### New Features
* Added new OCB to cog switch object: * Added new OCB to cog switch object:
- Use OCB 0 to have the traditional behaviour. - Use OCB 0 to have the traditional behaviour.
- Use any other OCB to can use the Cog Switch without need of any door linked. - Use any other OCB to can use the Cog Switch without need of any door linked.
@ -581,7 +613,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
## [Version 1.0.4](https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.6.2) - 2022-12-16 ## [Version 1.0.4](https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.6.2) - 2022-12-16
### Features/Amendments ### New Features
* Add generic assignable effects for moveables - fire, sparks, smoke and laser / electric ignite. * Add generic assignable effects for moveables - fire, sparks, smoke and laser / electric ignite.
* Add ability to burn enemies with FLAME_EMITTER_1 and death blocks. * Add ability to burn enemies with FLAME_EMITTER_1 and death blocks.
* Add wireframe mode and other visual debug information (switch by F10/F11 debug page scroll hotkeys). * Add wireframe mode and other visual debug information (switch by F10/F11 debug page scroll hotkeys).
@ -653,7 +685,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
## [Version 1.0.3](https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.6.1) - 2022-11-18 ## [Version 1.0.3](https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.6.1) - 2022-11-18
### Features/Amendments ### New Features
* Add ledge jumps (Lara object must be updated with new animations to make it work). * Add ledge jumps (Lara object must be updated with new animations to make it work).
* Allow any object slot to be used as a meshswap. * Allow any object slot to be used as a meshswap.
* Add OCB 1 for rollingball to make it silent. * Add OCB 1 for rollingball to make it silent.
@ -721,7 +753,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
## [Version 1.0.2](https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.6) - 2022-09-16 ## [Version 1.0.2](https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.6) - 2022-09-16
### Features/Amendments ### New Features
* Fix removing Pistols with TakeItem and SetItemCount. * Fix removing Pistols with TakeItem and SetItemCount.
* Allow saving and loading of Vec3s in LevelVars and GameVars. * Allow saving and loading of Vec3s in LevelVars and GameVars.
* Support volume triggers made with node editor. * Support volume triggers made with node editor.
@ -776,7 +808,7 @@ TombEngine releases are located in this repository (alongside with Tomb Editor):
## [Version 1.0.1](https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.5.2) - 2022-08-16 ## [Version 1.0.1](https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.5.2) - 2022-08-16
### Features ### New Features
* Added antialiasing support. * Added antialiasing support.
* Added static mesh scaling support. * Added static mesh scaling support.
* Added free rotation for teeth spikes instead of using OCB codes. * Added free rotation for teeth spikes instead of using OCB codes.

View file

@ -370,6 +370,30 @@ Leave them as is. This is good: `auto x = std::vector<int>();`
Use `//`-styled comments where possible. Use `//`-styled comments where possible.
Only use `/* */` style in case you are about to temporarily comment certain block for testing purposes or when writing a comment that will serve as the source for generated documentation. Only use `/* */` style in case you are about to temporarily comment certain block for testing purposes or when writing a comment that will serve as the source for generated documentation.
Use a `NOTE: ` prefix in your comment if you want to highlight something particularly noteworthy:
```c
// NOTE: Will not work for bones at ends of hierarchies.
float GetBoneLength(GAME_OBJECT_ID objectID, int boneIndex)
{
const auto& object = Objects[objectID];
if (object.nmeshes == boneIndex)
return 0.0f;
auto nextBoneOffset = GetJointOffset(objectID, boneIndex + 1);
return nextBoneOffset.Length();
}
```
Use a `FAILSAFE: ` prefix in your comment if you want to highlight a particularly quirky solution without an obvious and clear purpose:
```c
if (portalRoomNumber != NO_VALUE &&
rayRoomNumber != portalRoomNumber) // FAILSAFE: Prevent infinite loop if room portal leads back to itself.
{
player.Explode();
}
```
## Branches and pull requests ## Branches and pull requests
Make sure that epic branches (tens or hundreds of files changed due to renames, namespace wrappings, etc) **are focused on a single feature or task**. Don't jump in to others epic branches with another round of your epic changes. It masks bugs and makes review process very cumbersome. Make sure that epic branches (tens or hundreds of files changed due to renames, namespace wrappings, etc) **are focused on a single feature or task**. Don't jump in to others epic branches with another round of your epic changes. It masks bugs and makes review process very cumbersome.

View file

@ -12,7 +12,7 @@ new_type("luautil", "5 Lua utility modules", true)
not_luadoc = true not_luadoc = true
local version = "1.5" local version = "1.6"
project = "TombEngine" project = "TombEngine"
title = "TombEngine " .. version .. " Lua API" title = "TombEngine " .. version .. " Lua API"
description = "TombEngine " .. version .. " scripting interface" description = "TombEngine " .. version .. " scripting interface"
@ -34,7 +34,7 @@ If this happens, check __logs/TENLog.txt__ and look for an error message with th
Enjoy. Enjoy.
\- _squidshire_ \- _squidshire and the TombEngine development team._
]] ]]
convert_opt=true convert_opt=true

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
@ -142,6 +144,10 @@
<td class="name" ><a href="#MakeEarthquake">MakeEarthquake(strength)</a></td> <td class="name" ><a href="#MakeEarthquake">MakeEarthquake(strength)</a></td>
<td class="summary">Make an earthquake</td> <td class="summary">Make an earthquake</td>
</tr> </tr>
<tr>
<td class="name" ><a href="#GetWind">GetWind()</a></td>
<td class="summary">Get the wind vector for the current game frame.</td>
</tr>
</table> </table>
<br/> <br/>
@ -497,6 +503,28 @@
</dd>
<dt>
<a name = "GetWind"></a>
<strong>GetWind()</strong>
</dt>
<dd>
Get the wind vector for the current game frame.
This represents the 3D displacement applied by the engine on things like particles affected by wind.()
<h3>Returns:</h3>
<ol>
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
Wind vector.
</ol>
</dd> </dd>
</dl> </dl>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
@ -162,6 +164,10 @@ scripts too.</p>
<td class="summary">Returns the level that the game control is running in that moment.</td> <td class="summary">Returns the level that the game control is running in that moment.</td>
</tr> </tr>
<tr> <tr>
<td class="name" ><a href="#GetNextLevel">GetNextLevel()</a></td>
<td class="summary">Returns the level that is about to load.</td>
</tr>
<tr>
<td class="name" ><a href="#EndLevel">EndLevel([index][, startPos])</a></td> <td class="name" ><a href="#EndLevel">EndLevel([index][, startPos])</a></td>
<td class="summary">Finishes the current level, with optional level index and start position index provided.</td> <td class="summary">Finishes the current level, with optional level index and start position index provided.</td>
</tr> </tr>
@ -170,6 +176,14 @@ scripts too.</p>
<td class="summary">Get current game status, such as normal game loop, exiting to title, etc.</td> <td class="summary">Get current game status, such as normal game loop, exiting to title, etc.</td>
</tr> </tr>
<tr> <tr>
<td class="name" ><a href="#GetFreezeMode">GetFreezeMode()</a></td>
<td class="summary">Get current freeze mode, such as none, full, spectator or player.</td>
</tr>
<tr>
<td class="name" ><a href="#SetFreezeMode">SetFreezeMode(new)</a></td>
<td class="summary">Set current freeze mode, such as none, full, spectator or player.</td>
</tr>
<tr>
<td class="name" ><a href="#SaveGame">SaveGame(slotID)</a></td> <td class="name" ><a href="#SaveGame">SaveGame(slotID)</a></td>
<td class="summary">Save the game to a savegame slot.</td> <td class="summary">Save the game to a savegame slot.</td>
</tr> </tr>
@ -538,6 +552,27 @@ have an ID of 0, the second an ID of 1, and so on.
</dd>
<dt>
<a name = "GetNextLevel"></a>
<strong>GetNextLevel()</strong>
</dt>
<dd>
Returns the level that is about to load. If no new level is about to load, returns current level.
<h3>Returns:</h3>
<ol>
<span class="types"><a class="type" href="../2 classes/Flow.Level.html#">Level</a></span>
incoming new level or current level, if no new level is loading
</ol>
</dd> </dd>
<dt> <dt>
<a name = "EndLevel"></a> <a name = "EndLevel"></a>
@ -590,6 +625,51 @@ teleported to such object with OCB similar to provided second argument.
</dd>
<dt>
<a name = "GetFreezeMode"></a>
<strong>GetFreezeMode()</strong>
</dt>
<dd>
Get current freeze mode, such as none, full, spectator or player.
<h3>Returns:</h3>
<ol>
<span class="types"><a class="type" href="../4 enums/Flow.FreezeMode.html#">FreezeMode</a></span>
the current freeze mode
</ol>
</dd>
<dt>
<a name = "SetFreezeMode"></a>
<strong>SetFreezeMode(new)</strong>
</dt>
<dd>
Set current freeze mode, such as none, full, spectator or player. <br/>
Freeze mode specifies whether game is in normal mode or paused in a particular way to allow
custom menu creation, photo mode or time freeze.
<h3>Parameters:</h3>
<ul>
<li><span class="parameter">new</span>
<span class="types"><a class="type" href="../4 enums/Flow.FreezeMode.html#">FreezeMode</a></span>
freeze mode to set.
</li>
</ul>
</dd> </dd>
<dt> <dt>
<a name = "SaveGame"></a> <a name = "SaveGame"></a>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
@ -183,6 +185,9 @@ PRESAVE <span class="comment">-- will be called immediately before OnSave
PRELOAD <span class="comment">-- will be called immediately before OnLoad PRELOAD <span class="comment">-- will be called immediately before OnLoad
</span>POSTLOAD <span class="comment">-- will be called immediately after OnLoad </span>POSTLOAD <span class="comment">-- will be called immediately after OnLoad
</span> </span>
PREFREEZE <span class="comment">-- will be called before entering freeze mode
</span>POSTFREEZE <span class="comment">-- will be called immediately after exiting freeze mode
</span>
<span class="comment">-- These take a LevelEndReason arg, like OnEnd <span class="comment">-- These take a LevelEndReason arg, like OnEnd
</span>PREEND <span class="comment">-- will be called immediately before OnEnd </span>PREEND <span class="comment">-- will be called immediately before OnEnd
</span>POSTEND <span class="comment">-- will be called immediately after OnEnd </span>POSTEND <span class="comment">-- will be called immediately after OnEnd
@ -190,6 +195,10 @@ PRELOAD <span class="comment">-- will be called immediately before OnLoad
<span class="comment">-- These take functions which accepts a deltaTime argument <span class="comment">-- These take functions which accepts a deltaTime argument
</span>PRELOOP <span class="comment">-- will be called in the beginning of game loop </span>PRELOOP <span class="comment">-- will be called in the beginning of game loop
</span>POSTLOOP <span class="comment">-- will be called at the end of game loop </span>POSTLOOP <span class="comment">-- will be called at the end of game loop
</span>
<span class="comment">-- These take functions which accepts an objectNumber argument, like OnUseItem
</span>PREUSEITEM <span class="comment">-- will be called immediately before OnUseItem
</span>POSTUSEITEM <span class="comment">-- will be called immediately after OnUseItem
</span></pre> </span></pre>
<p>The order in which two functions with the same CallbackPoint are called is undefined. <p>The order in which two functions with the same CallbackPoint are called is undefined.
i.e. if you register <code>MyFunc</code> and <code>MyFunc2</code> with <code>PRELOOP</code>, both will be called in the beginning of game loop, but there is no guarantee that <code>MyFunc</code> will be called before <code>MyFunc2</code>, or vice-versa.</p> i.e. if you register <code>MyFunc</code> and <code>MyFunc2</code> with <code>PRELOOP</code>, both will be called in the beginning of game loop, but there is no guarantee that <code>MyFunc</code> will be called before <code>MyFunc2</code>, or vice-versa.</p>
@ -266,7 +275,8 @@ SAVE
START START
END END
LOOP LOOP
USEITEM</pre> USEITEM
MENU</pre>
<h3>Parameters:</h3> <h3>Parameters:</h3>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
@ -115,7 +117,7 @@
<td class="summary">Play an audio track</td> <td class="summary">Play an audio track</td>
</tr> </tr>
<tr> <tr>
<td class="name" ><a href="#SetAmbientTrack">SetAmbientTrack(name)</a></td> <td class="name" ><a href="#SetAmbientTrack">SetAmbientTrack(name, fromStart)</a></td>
<td class="summary">Set and play an ambient track</td> <td class="summary">Set and play an ambient track</td>
</tr> </tr>
<tr> <tr>
@ -187,7 +189,7 @@
</dd> </dd>
<dt> <dt>
<a name = "SetAmbientTrack"></a> <a name = "SetAmbientTrack"></a>
<strong>SetAmbientTrack(name)</strong> <strong>SetAmbientTrack(name, fromStart)</strong>
</dt> </dt>
<dd> <dd>
Set and play an ambient track Set and play an ambient track
@ -200,6 +202,10 @@
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span> <span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
of track (without file extension) to play of track (without file extension) to play
</li> </li>
<li><span class="parameter">fromStart</span>
<span class="types"><span class="type">bool</span></span>
specifies whether ambient track should play from the start, or crossfade at a random position
</li>
</ul> </ul>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
@ -114,6 +116,10 @@
<td class="name" ><a href="#errorMode">errorMode</a></td> <td class="name" ><a href="#errorMode">errorMode</a></td>
<td class="summary">How should the application respond to script errors?</td> <td class="summary">How should the application respond to script errors?</td>
</tr> </tr>
<tr>
<td class="name" ><a href="#fastReload">fastReload</a></td>
<td class="summary">Can the game utilize the fast reload feature?</td>
</tr>
</table> </table>
<br/> <br/>
@ -129,6 +135,7 @@
</dt> </dt>
<dd> <dd>
How should the application respond to script errors? How should the application respond to script errors?
<br>
Must be one of the following: Must be one of the following:
<code>ErrorMode.TERMINATE</code> - print to the log file and return to the title level when any script error is hit. <code>ErrorMode.TERMINATE</code> - 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.</p> This is the one you will want to go for if you want to know IMMEDIATELY if something has gone wrong.</p>
@ -151,6 +158,25 @@ has an unrecoverable error, the game will close.
</dd>
<dt>
<a name = "fastReload"></a>
<strong>fastReload</strong>
</dt>
<dd>
Can the game utilize the fast reload feature?
<br>
When set to <code>true</code>, the game will attempt to perform fast savegame reloading if current level is the same as
the level loaded from the savegame. It will not work if the level timestamp or checksum has changed
(i.e. level was updated). If set to <code>false</code>, this functionality is turned off.
</dd> </dd>
</dl> </dl>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
@ -382,6 +384,14 @@ pickups, and Lara herself (see also <a href="../2 classes/Objects.LaraObject.htm
<td class="summary">Disable the item, as if an antitrigger for it had been stepped on (i.e.</td> <td class="summary">Disable the item, as if an antitrigger for it had been stepped on (i.e.</td>
</tr> </tr>
<tr> <tr>
<td class="name" ><a href="#Moveable:GetCollidable">Moveable:GetCollidable()</a></td>
<td class="summary">Get the item's collision state.</td>
</tr>
<tr>
<td class="name" ><a href="#Moveable:SetCollidable">Moveable:SetCollidable(collidable)</a></td>
<td class="summary">Set the item's collision.</td>
</tr>
<tr>
<td class="name" ><a href="#Moveable:MakeInvisible">Moveable:MakeInvisible()</a></td> <td class="name" ><a href="#Moveable:MakeInvisible">Moveable:MakeInvisible()</a></td>
<td class="summary">Make the item invisible.</td> <td class="summary">Make the item invisible.</td>
</tr> </tr>
@ -1966,6 +1976,49 @@ sas:SetPosition(newPos, <span class="keyword">false</span>)</pre>
</dd>
<dt>
<a name = "Moveable:GetCollidable"></a>
<strong>Moveable:GetCollidable()</strong>
</dt>
<dd>
Get the item's collision state.
<h3>Returns:</h3>
<ol>
<span class="types"><span class="type">bool</span></span>
item's collision state
</ol>
</dd>
<dt>
<a name = "Moveable:SetCollidable"></a>
<strong>Moveable:SetCollidable(collidable)</strong>
</dt>
<dd>
Set the item's collision.
<h3>Parameters:</h3>
<ul>
<li><span class="parameter">collidable</span>
<span class="types"><span class="type">bool</span></span>
true if the caller should be collidable, false if no collision should occur.
</li>
</ul>
</dd> </dd>
<dt> <dt>
<a name = "Moveable:MakeInvisible"></a> <a name = "Moveable:MakeInvisible"></a>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
@ -116,7 +118,7 @@ when you need to use screen-space coordinates.</p>
<h2><a href="#Functions">Functions</a></h2> <h2><a href="#Functions">Functions</a></h2>
<table class="function_list"> <table class="function_list">
<tr> <tr>
<td class="name" ><a href="#DisplayString">DisplayString(string, Position[, scale][, color][, translated][, flags])</a></td> <td class="name" ><a href="#DisplayString">DisplayString(string, Position[, scale][, color][, translated], table)</a></td>
<td class="summary">Create a DisplayString.</td> <td class="summary">Create a DisplayString.</td>
</tr> </tr>
<tr> <tr>
@ -170,7 +172,7 @@ when you need to use screen-space coordinates.</p>
<dl class="function"> <dl class="function">
<dt> <dt>
<a name = "DisplayString"></a> <a name = "DisplayString"></a>
<strong>DisplayString(string, Position[, scale][, color][, translated][, flags])</strong> <strong>DisplayString(string, Position[, scale][, color][, translated], table)</strong>
</dt> </dt>
<dd> <dd>
Create a DisplayString. Create a DisplayString.
@ -204,16 +206,9 @@ For use in <a href="../1 modules/Strings.html#ShowString">ShowString</a> and <a
If true, the string argument will be the key of a translated string specified in strings.lua. <strong>Default: false</strong>. If true, the string argument will be the key of a translated string specified in strings.lua. <strong>Default: false</strong>.
(<em>optional</em>) (<em>optional</em>)
</li> </li>
<li><span class="parameter">flags</span> <li><span class="parameter">table</span>
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.6">table</a></span> <span class="types"><a class="type" href="../4 enums/Strings.DisplayStringOption.html#">DisplayStringOption</a></span>
A table of string display options. Can be empty or omitted. The possible values and their effects are:</p> <strong>Default: None.</strong> <em>Please note that Strings are automatically aligned to the LEFT</em>
<pre><code>TEN.Strings.DisplayStringOption.CENTER: set the horizontal origin point to the center of the string.
TEN.Strings.DisplayStringOption.RIGHT: set the horizontal origin point to right of the string.
TEN.Strings.DisplayStringOption.SHADOW: give the string a small shadow.
TEN.Strings.DisplayStringOption.BLINK: blink the string.
</code></pre>
<p><strong>Default: empty</strong>
(<em>optional</em>)
</li> </li>
</ul> </ul>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <here>Effects.BlendID</here></li> <li> <here>Effects.BlendID</here></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <here>Effects.EffectID</here></li> <li> <here>Effects.EffectID</here></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -0,0 +1,166 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head>
<title>TombEngine 1.5 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head>
<body>
<div id="container">
<div id="product">
<div id="product_logo"></div>
<div id="product_name"><big><b></b></big></div>
<div id="product_description"></div>
</div> <!-- id="product" -->
<div id="main">
<!-- Menu -->
<div id="navigation">
<br/>
<h1>TombEngine</h1>
<ul>
<li><a href="../index.html">Index</a></li>
</ul>
<h2>1 Modules</h2>
<ul class="nowrap">
<li> <a href="../1 modules/Effects.html">Effects</a></li>
<li> <a href="../1 modules/Flow.html">Flow</a></li>
<li> <a href="../1 modules/Input.html">Input</a></li>
<li> <a href="../1 modules/Inventory.html">Inventory</a></li>
<li> <a href="../1 modules/Logic.html">Logic</a></li>
<li> <a href="../1 modules/Objects.html">Objects</a></li>
<li> <a href="../1 modules/Sound.html">Sound</a></li>
<li> <a href="../1 modules/Strings.html">Strings</a></li>
<li> <a href="../1 modules/Util.html">Util</a></li>
<li> <a href="../1 modules/View.html">View</a></li>
</ul>
<h2>2 Classes</h2>
<ul class="nowrap">
<li> <a href="../2 classes/View.DisplaySprite.html">View.DisplaySprite</a></li>
<li> <a href="../2 classes/Flow.Animations.html">Flow.Animations</a></li>
<li> <a href="../2 classes/Flow.Fog.html">Flow.Fog</a></li>
<li> <a href="../2 classes/Flow.InventoryItem.html">Flow.InventoryItem</a></li>
<li> <a href="../2 classes/Flow.LensFlare.html">Flow.LensFlare</a></li>
<li> <a href="../2 classes/Flow.Level.html">Flow.Level</a></li>
<li> <a href="../2 classes/Flow.Mirror.html">Flow.Mirror</a></li>
<li> <a href="../2 classes/Flow.Settings.html">Flow.Settings</a></li>
<li> <a href="../2 classes/Flow.SkyLayer.html">Flow.SkyLayer</a></li>
<li> <a href="../2 classes/Flow.Starfield.html">Flow.Starfield</a></li>
<li> <a href="../2 classes/Objects.AIObject.html">Objects.AIObject</a></li>
<li> <a href="../2 classes/Objects.Camera.html">Objects.Camera</a></li>
<li> <a href="../2 classes/Objects.LaraObject.html">Objects.LaraObject</a></li>
<li> <a href="../2 classes/Objects.Moveable.html">Objects.Moveable</a></li>
<li> <a href="../2 classes/Objects.Room.html">Objects.Room</a></li>
<li> <a href="../2 classes/Objects.Sink.html">Objects.Sink</a></li>
<li> <a href="../2 classes/Objects.SoundSource.html">Objects.SoundSource</a></li>
<li> <a href="../2 classes/Objects.Static.html">Objects.Static</a></li>
<li> <a href="../2 classes/Objects.Volume.html">Objects.Volume</a></li>
<li> <a href="../2 classes/Strings.DisplayString.html">Strings.DisplayString</a></li>
</ul>
<h2>3 Primitive Classes</h2>
<ul class="nowrap">
<li> <a href="../3 primitive classes/Color.html">Color</a></li>
<li> <a href="../3 primitive classes/Rotation.html">Rotation</a></li>
<li> <a href="../3 primitive classes/Vec2.html">Vec2</a></li>
<li> <a href="../3 primitive classes/Vec3.html">Vec3</a></li>
</ul>
<h2>4 Enums</h2>
<ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <here>Flow.BreakMode</here></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
<li> <a href="../4 enums/Objects.MoveableStatus.html">Objects.MoveableStatus</a></li>
<li> <a href="../4 enums/Objects.ObjID.html">Objects.ObjID</a></li>
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
<li> <a href="../4 enums/View.PostProcessMode.html">View.PostProcessMode</a></li>
<li> <a href="../4 enums/View.ScaleMode.html">View.ScaleMode</a></li>
</ul>
<h2>5 Lua utility modules</h2>
<ul class="nowrap">
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
</ul>
</div>
<div id="content">
<h1>Enum <code>Flow.BreakMode</code></h1>
<p>Constants for break modes.</p>
<p>
</p>
<h2><a href="#Flow_BreakMode_constants">Flow.BreakMode constants </a></h2>
<table class="function_list">
<tr>
<td class="name" ><a href="#CONSTANT_STRING_HERE">CONSTANT_STRING_HERE</a></td>
<td class="summary">Table of break modes.</td>
</tr>
</table>
<br/>
<br/>
<h2 class="section-header has-description"><a name="Flow_BreakMode_constants"></a>Flow.BreakMode constants </h2>
<div class="section-description">
<p>The following constants are inside Flow.BreakMode.</p>
<pre><code>NONE
FULL
SPECTATOR
PLAYER
</code></pre>
</div>
<dl class="function">
<dt>
<a name = "CONSTANT_STRING_HERE"></a>
<strong>CONSTANT_STRING_HERE</strong>
</dt>
<dd>
Table of break modes.
</dd>
</dl>
</div> <!-- id="content" -->
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="https://github.com/hispidence/TEN-LDoc">TEN-LDoc</a> (a fork of <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a>)</i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
</html>

View file

@ -0,0 +1,167 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head>
<title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head>
<body>
<div id="container">
<div id="product">
<div id="product_logo"></div>
<div id="product_name"><big><b></b></big></div>
<div id="product_description"></div>
</div> <!-- id="product" -->
<div id="main">
<!-- Menu -->
<div id="navigation">
<br/>
<h1>TombEngine</h1>
<ul>
<li><a href="../index.html">Index</a></li>
</ul>
<h2>1 Modules</h2>
<ul class="nowrap">
<li> <a href="../1 modules/Effects.html">Effects</a></li>
<li> <a href="../1 modules/Flow.html">Flow</a></li>
<li> <a href="../1 modules/Input.html">Input</a></li>
<li> <a href="../1 modules/Inventory.html">Inventory</a></li>
<li> <a href="../1 modules/Logic.html">Logic</a></li>
<li> <a href="../1 modules/Objects.html">Objects</a></li>
<li> <a href="../1 modules/Sound.html">Sound</a></li>
<li> <a href="../1 modules/Strings.html">Strings</a></li>
<li> <a href="../1 modules/Util.html">Util</a></li>
<li> <a href="../1 modules/View.html">View</a></li>
</ul>
<h2>2 Classes</h2>
<ul class="nowrap">
<li> <a href="../2 classes/View.DisplaySprite.html">View.DisplaySprite</a></li>
<li> <a href="../2 classes/Flow.Animations.html">Flow.Animations</a></li>
<li> <a href="../2 classes/Flow.Fog.html">Flow.Fog</a></li>
<li> <a href="../2 classes/Flow.InventoryItem.html">Flow.InventoryItem</a></li>
<li> <a href="../2 classes/Flow.LensFlare.html">Flow.LensFlare</a></li>
<li> <a href="../2 classes/Flow.Level.html">Flow.Level</a></li>
<li> <a href="../2 classes/Flow.Mirror.html">Flow.Mirror</a></li>
<li> <a href="../2 classes/Flow.Settings.html">Flow.Settings</a></li>
<li> <a href="../2 classes/Flow.SkyLayer.html">Flow.SkyLayer</a></li>
<li> <a href="../2 classes/Flow.Starfield.html">Flow.Starfield</a></li>
<li> <a href="../2 classes/Objects.AIObject.html">Objects.AIObject</a></li>
<li> <a href="../2 classes/Objects.Camera.html">Objects.Camera</a></li>
<li> <a href="../2 classes/Objects.LaraObject.html">Objects.LaraObject</a></li>
<li> <a href="../2 classes/Objects.Moveable.html">Objects.Moveable</a></li>
<li> <a href="../2 classes/Objects.Room.html">Objects.Room</a></li>
<li> <a href="../2 classes/Objects.Sink.html">Objects.Sink</a></li>
<li> <a href="../2 classes/Objects.SoundSource.html">Objects.SoundSource</a></li>
<li> <a href="../2 classes/Objects.Static.html">Objects.Static</a></li>
<li> <a href="../2 classes/Objects.Volume.html">Objects.Volume</a></li>
<li> <a href="../2 classes/Strings.DisplayString.html">Strings.DisplayString</a></li>
</ul>
<h2>3 Primitive Classes</h2>
<ul class="nowrap">
<li> <a href="../3 primitive classes/Color.html">Color</a></li>
<li> <a href="../3 primitive classes/Rotation.html">Rotation</a></li>
<li> <a href="../3 primitive classes/Vec2.html">Vec2</a></li>
<li> <a href="../3 primitive classes/Vec3.html">Vec3</a></li>
</ul>
<h2>4 Enums</h2>
<ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <here>Flow.FreezeMode</here></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
<li> <a href="../4 enums/Objects.MoveableStatus.html">Objects.MoveableStatus</a></li>
<li> <a href="../4 enums/Objects.ObjID.html">Objects.ObjID</a></li>
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
<li> <a href="../4 enums/View.PostProcessMode.html">View.PostProcessMode</a></li>
<li> <a href="../4 enums/View.ScaleMode.html">View.ScaleMode</a></li>
</ul>
<h2>5 Lua utility modules</h2>
<ul class="nowrap">
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
</ul>
</div>
<div id="content">
<h1>Enum <code>Flow.FreezeMode</code></h1>
<p>Constants for freeze modes.</p>
<p>
</p>
<h2><a href="#Flow_FreezeMode_constants">Flow.FreezeMode constants </a></h2>
<table class="function_list">
<tr>
<td class="name" ><a href="#CONSTANT_STRING_HERE">CONSTANT_STRING_HERE</a></td>
<td class="summary">Table of freeze modes.</td>
</tr>
</table>
<br/>
<br/>
<h2 class="section-header has-description"><a name="Flow_FreezeMode_constants"></a>Flow.FreezeMode constants </h2>
<div class="section-description">
<p>The following constants are inside Flow.FreezeMode.</p>
<pre><code>NONE - Normal in-game operation.
FULL - Game is completely frozen, as in pause or inventory menus.
SPECTATOR - Game is completely frozen, but with ability to control camera.
PLAYER - Game is completely frozen, but with ability to control player. Experimental.
</code></pre>
</div>
<dl class="function">
<dt>
<a name = "CONSTANT_STRING_HERE"></a>
<strong>CONSTANT_STRING_HERE</strong>
</dt>
<dd>
Table of freeze modes.
</dd>
</dl>
</div> <!-- id="content" -->
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="https://github.com/hispidence/TEN-LDoc">TEN-LDoc</a> (a fork of <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a>)</i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
</html>

View file

@ -0,0 +1,165 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head>
<title>TombEngine 1.5 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head>
<body>
<div id="container">
<div id="product">
<div id="product_logo"></div>
<div id="product_name"><big><b></b></big></div>
<div id="product_description"></div>
</div> <!-- id="product" -->
<div id="main">
<!-- Menu -->
<div id="navigation">
<br/>
<h1>TombEngine</h1>
<ul>
<li><a href="../index.html">Index</a></li>
</ul>
<h2>1 Modules</h2>
<ul class="nowrap">
<li> <a href="../1 modules/Effects.html">Effects</a></li>
<li> <a href="../1 modules/Flow.html">Flow</a></li>
<li> <a href="../1 modules/Input.html">Input</a></li>
<li> <a href="../1 modules/Inventory.html">Inventory</a></li>
<li> <a href="../1 modules/Logic.html">Logic</a></li>
<li> <a href="../1 modules/Objects.html">Objects</a></li>
<li> <a href="../1 modules/Sound.html">Sound</a></li>
<li> <a href="../1 modules/Strings.html">Strings</a></li>
<li> <a href="../1 modules/Util.html">Util</a></li>
<li> <a href="../1 modules/View.html">View</a></li>
</ul>
<h2>2 Classes</h2>
<ul class="nowrap">
<li> <a href="../2 classes/View.DisplaySprite.html">View.DisplaySprite</a></li>
<li> <a href="../2 classes/Flow.Animations.html">Flow.Animations</a></li>
<li> <a href="../2 classes/Flow.Fog.html">Flow.Fog</a></li>
<li> <a href="../2 classes/Flow.InventoryItem.html">Flow.InventoryItem</a></li>
<li> <a href="../2 classes/Flow.LensFlare.html">Flow.LensFlare</a></li>
<li> <a href="../2 classes/Flow.Level.html">Flow.Level</a></li>
<li> <a href="../2 classes/Flow.Mirror.html">Flow.Mirror</a></li>
<li> <a href="../2 classes/Flow.Settings.html">Flow.Settings</a></li>
<li> <a href="../2 classes/Flow.SkyLayer.html">Flow.SkyLayer</a></li>
<li> <a href="../2 classes/Flow.Starfield.html">Flow.Starfield</a></li>
<li> <a href="../2 classes/Objects.AIObject.html">Objects.AIObject</a></li>
<li> <a href="../2 classes/Objects.Camera.html">Objects.Camera</a></li>
<li> <a href="../2 classes/Objects.LaraObject.html">Objects.LaraObject</a></li>
<li> <a href="../2 classes/Objects.Moveable.html">Objects.Moveable</a></li>
<li> <a href="../2 classes/Objects.Room.html">Objects.Room</a></li>
<li> <a href="../2 classes/Objects.Sink.html">Objects.Sink</a></li>
<li> <a href="../2 classes/Objects.SoundSource.html">Objects.SoundSource</a></li>
<li> <a href="../2 classes/Objects.Static.html">Objects.Static</a></li>
<li> <a href="../2 classes/Objects.Volume.html">Objects.Volume</a></li>
<li> <a href="../2 classes/Strings.DisplayString.html">Strings.DisplayString</a></li>
</ul>
<h2>3 Primitive Classes</h2>
<ul class="nowrap">
<li> <a href="../3 primitive classes/Color.html">Color</a></li>
<li> <a href="../3 primitive classes/Rotation.html">Rotation</a></li>
<li> <a href="../3 primitive classes/Vec2.html">Vec2</a></li>
<li> <a href="../3 primitive classes/Vec3.html">Vec3</a></li>
</ul>
<h2>4 Enums</h2>
<ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <here>Flow.GameMode</here></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
<li> <a href="../4 enums/Objects.MoveableStatus.html">Objects.MoveableStatus</a></li>
<li> <a href="../4 enums/Objects.ObjID.html">Objects.ObjID</a></li>
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
<li> <a href="../4 enums/View.PostProcessMode.html">View.PostProcessMode</a></li>
<li> <a href="../4 enums/View.ScaleMode.html">View.ScaleMode</a></li>
</ul>
<h2>5 Lua utility modules</h2>
<ul class="nowrap">
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
</ul>
</div>
<div id="content">
<h1>Enum <code>Flow.GameMode</code></h1>
<p>Constants for game modes.</p>
<p>
</p>
<h2><a href="#Flow_GameMode_constants">Flow.GameMode constants </a></h2>
<table class="function_list">
<tr>
<td class="name" ><a href="#CONSTANT_STRING_HERE">CONSTANT_STRING_HERE</a></td>
<td class="summary">Table of game modes.</td>
</tr>
</table>
<br/>
<br/>
<h2 class="section-header has-description"><a name="Flow_GameMode_constants"></a>Flow.GameMode constants </h2>
<div class="section-description">
<p>The following constants are inside Flow.GameMode.</p>
<pre><code>NORMAL
FROZEN
MENU
</code></pre>
</div>
<dl class="function">
<dt>
<a name = "CONSTANT_STRING_HERE"></a>
<strong>CONSTANT_STRING_HERE</strong>
</dt>
<dd>
Table of game modes.
</dd>
</dl>
</div> <!-- id="content" -->
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="https://github.com/hispidence/TEN-LDoc">TEN-LDoc</a> (a fork of <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a>)</i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
</html>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <here>Flow.GameStatus</here></li> <li> <here>Flow.GameStatus</here></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <here>Input.ActionID</here></li> <li> <here>Input.ActionID</here></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <here>Objects.AmmoType</here></li> <li> <here>Objects.AmmoType</here></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <here>Objects.RoomFlagID</here></li> <li> <here>Objects.RoomFlagID</here></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <here>Objects.RoomReverb</here></li> <li> <here>Objects.RoomReverb</here></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <here>Sound.SoundTrackType</here></li> <li> <here>Sound.SoundTrackType</here></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -0,0 +1,160 @@
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head>
<title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head>
<body>
<div id="container">
<div id="product">
<div id="product_logo"></div>
<div id="product_name"><big><b></b></big></div>
<div id="product_description"></div>
</div> <!-- id="product" -->
<div id="main">
<!-- Menu -->
<div id="navigation">
<br/>
<h1>TombEngine</h1>
<ul>
<li><a href="../index.html">Index</a></li>
</ul>
<h2>1 Modules</h2>
<ul class="nowrap">
<li> <a href="../1 modules/Effects.html">Effects</a></li>
<li> <a href="../1 modules/Flow.html">Flow</a></li>
<li> <a href="../1 modules/Input.html">Input</a></li>
<li> <a href="../1 modules/Inventory.html">Inventory</a></li>
<li> <a href="../1 modules/Logic.html">Logic</a></li>
<li> <a href="../1 modules/Objects.html">Objects</a></li>
<li> <a href="../1 modules/Sound.html">Sound</a></li>
<li> <a href="../1 modules/Strings.html">Strings</a></li>
<li> <a href="../1 modules/Util.html">Util</a></li>
<li> <a href="../1 modules/View.html">View</a></li>
</ul>
<h2>2 Classes</h2>
<ul class="nowrap">
<li> <a href="../2 classes/View.DisplaySprite.html">View.DisplaySprite</a></li>
<li> <a href="../2 classes/Flow.Animations.html">Flow.Animations</a></li>
<li> <a href="../2 classes/Flow.Fog.html">Flow.Fog</a></li>
<li> <a href="../2 classes/Flow.InventoryItem.html">Flow.InventoryItem</a></li>
<li> <a href="../2 classes/Flow.LensFlare.html">Flow.LensFlare</a></li>
<li> <a href="../2 classes/Flow.Level.html">Flow.Level</a></li>
<li> <a href="../2 classes/Flow.Mirror.html">Flow.Mirror</a></li>
<li> <a href="../2 classes/Flow.Settings.html">Flow.Settings</a></li>
<li> <a href="../2 classes/Flow.SkyLayer.html">Flow.SkyLayer</a></li>
<li> <a href="../2 classes/Flow.Starfield.html">Flow.Starfield</a></li>
<li> <a href="../2 classes/Objects.AIObject.html">Objects.AIObject</a></li>
<li> <a href="../2 classes/Objects.Camera.html">Objects.Camera</a></li>
<li> <a href="../2 classes/Objects.LaraObject.html">Objects.LaraObject</a></li>
<li> <a href="../2 classes/Objects.Moveable.html">Objects.Moveable</a></li>
<li> <a href="../2 classes/Objects.Room.html">Objects.Room</a></li>
<li> <a href="../2 classes/Objects.Sink.html">Objects.Sink</a></li>
<li> <a href="../2 classes/Objects.SoundSource.html">Objects.SoundSource</a></li>
<li> <a href="../2 classes/Objects.Static.html">Objects.Static</a></li>
<li> <a href="../2 classes/Objects.Volume.html">Objects.Volume</a></li>
<li> <a href="../2 classes/Strings.DisplayString.html">Strings.DisplayString</a></li>
</ul>
<h2>3 Primitive Classes</h2>
<ul class="nowrap">
<li> <a href="../3 primitive classes/Color.html">Color</a></li>
<li> <a href="../3 primitive classes/Rotation.html">Rotation</a></li>
<li> <a href="../3 primitive classes/Vec2.html">Vec2</a></li>
<li> <a href="../3 primitive classes/Vec3.html">Vec3</a></li>
</ul>
<h2>4 Enums</h2>
<ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
<li> <a href="../4 enums/Objects.MoveableStatus.html">Objects.MoveableStatus</a></li>
<li> <a href="../4 enums/Objects.ObjID.html">Objects.ObjID</a></li>
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <here>Strings.DisplayStringOption</here></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>
<li> <a href="../4 enums/View.PostProcessMode.html">View.PostProcessMode</a></li>
<li> <a href="../4 enums/View.ScaleMode.html">View.ScaleMode</a></li>
</ul>
<h2>5 Lua utility modules</h2>
<ul class="nowrap">
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
</ul>
</div>
<div id="content">
<h1>Enum <code>Strings.DisplayStringOption</code></h1>
<p>Constants for Display String Options.</p>
<p>
</p>
<h2><a href="#Tables">Tables</a></h2>
<table class="function_list">
<tr>
<td class="name" ><a href="#Strings.DisplayStringOption">Strings.DisplayStringOption</a></td>
<td class="summary">Strings.DisplayStringOption constants.</td>
</tr>
</table>
<br/>
<br/>
<h2 class="section-header "><a name="Tables"></a>Tables</h2>
<dl class="function">
<dt>
<a name = "Strings.DisplayStringOption"></a>
<strong>Strings.DisplayStringOption</strong>
</dt>
<dd>
<p>Strings.DisplayStringOption constants. </p>
<pre><code>CENTER -- set the horizontal origin point to the center of the string.
RIGHT -- set the horizontal origin point to right of the string.
SHADOW -- gives the string a small drop shadow.
BLINK -- blinks the string
</code></pre>
</dd>
</dl>
</div> <!-- id="content" -->
</div> <!-- id="main" -->
<div id="about">
<i>generated by <a href="https://github.com/hispidence/TEN-LDoc">TEN-LDoc</a> (a fork of <a href="http://github.com/stevedonovan/LDoc">LDoc 1.4.6</a>)</i>
</div> <!-- id="about" -->
</div> <!-- id="container" -->
</body>
</html>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <here>Util.LogLevel</here></li> <li> <here>Util.LogLevel</here></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <here>View.AlignMode</here></li> <li> <here>View.AlignMode</here></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <here>View.CameraType</here></li> <li> <here>View.CameraType</here></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="../ldoc.css" type="text/css" /> <link rel="stylesheet" href="../ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="../4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="../4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="../4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="../4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="../4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="../4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="../4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="../4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="../4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="../4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="../4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="../4 enums/View.CameraType.html">View.CameraType</a></li>

View file

@ -3,7 +3,7 @@
<html> <html>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/> <meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<head> <head>
<title>TombEngine 1.5 Lua API</title> <title>TombEngine 1.6 Lua API</title>
<link rel="stylesheet" href="ldoc.css" type="text/css" /> <link rel="stylesheet" href="ldoc.css" type="text/css" />
</head> </head>
<body> <body>
@ -77,6 +77,7 @@
<ul class="nowrap"> <ul class="nowrap">
<li> <a href="4 enums/Effects.BlendID.html">Effects.BlendID</a></li> <li> <a href="4 enums/Effects.BlendID.html">Effects.BlendID</a></li>
<li> <a href="4 enums/Effects.EffectID.html">Effects.EffectID</a></li> <li> <a href="4 enums/Effects.EffectID.html">Effects.EffectID</a></li>
<li> <a href="4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></li>
<li> <a href="4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li> <li> <a href="4 enums/Flow.GameStatus.html">Flow.GameStatus</a></li>
<li> <a href="4 enums/Input.ActionID.html">Input.ActionID</a></li> <li> <a href="4 enums/Input.ActionID.html">Input.ActionID</a></li>
<li> <a href="4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li> <li> <a href="4 enums/Objects.AmmoType.html">Objects.AmmoType</a></li>
@ -85,6 +86,7 @@
<li> <a href="4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li> <li> <a href="4 enums/Objects.RoomFlagID.html">Objects.RoomFlagID</a></li>
<li> <a href="4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li> <li> <a href="4 enums/Objects.RoomReverb.html">Objects.RoomReverb</a></li>
<li> <a href="4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li> <li> <a href="4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></li>
<li> <a href="4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></li>
<li> <a href="4 enums/Util.LogLevel.html">Util.LogLevel</a></li> <li> <a href="4 enums/Util.LogLevel.html">Util.LogLevel</a></li>
<li> <a href="4 enums/View.AlignMode.html">View.AlignMode</a></li> <li> <a href="4 enums/View.AlignMode.html">View.AlignMode</a></li>
<li> <a href="4 enums/View.CameraType.html">View.CameraType</a></li> <li> <a href="4 enums/View.CameraType.html">View.CameraType</a></li>
@ -102,7 +104,7 @@
<div id="content"> <div id="content">
<h2>TombEngine 1.5 scripting interface</h2> <h2>TombEngine 1.6 scripting interface</h2>
<p>Welcome to the TombEngine scripting API. This is a work in progress and some information might be wrong or outdated. Please also note that this is primarily a reference document, not a tutorial, so expect descriptions to be fairly sparse.</p> <p>Welcome to the TombEngine scripting API. This is a work in progress and some information might be wrong or outdated. Please also note that this is primarily a reference document, not a tutorial, so expect descriptions to be fairly sparse.</p>
<p>At the time of writing, there is a tutorial describing the basics of Lua, as well as a number of example scripts, on <a href="https://www.tombengine.com">the TombEngine website</a>.</p> <p>At the time of writing, there is a tutorial describing the basics of Lua, as well as a number of example scripts, on <a href="https://www.tombengine.com">the TombEngine website</a>.</p>
@ -122,7 +124,7 @@ local door = GetMoveableByName("door_type4_14")
<p>Enjoy.</p> <p>Enjoy.</p>
<p>- <em>squidshire</em></p> <p>- <em>squidshire and the TombEngine development team.</em></p>
<h2>1 Modules</h2> <h2>1 Modules</h2>
<table class="module_list"> <table class="module_list">
@ -279,6 +281,10 @@ local door = GetMoveableByName("door_type4_14")
<td class="name" ><a href="4 enums/Effects.EffectID.html">Effects.EffectID</a></td> <td class="name" ><a href="4 enums/Effects.EffectID.html">Effects.EffectID</a></td>
<td class="summary">Constants for effect IDs.</td> <td class="summary">Constants for effect IDs.</td>
</tr> </tr>
<tr>
<td class="name" ><a href="4 enums/Flow.FreezeMode.html">Flow.FreezeMode</a></td>
<td class="summary">Constants for freeze modes.</td>
</tr>
<tr> <tr>
<td class="name" ><a href="4 enums/Flow.GameStatus.html">Flow.GameStatus</a></td> <td class="name" ><a href="4 enums/Flow.GameStatus.html">Flow.GameStatus</a></td>
<td class="summary">Constants for game statuses.</td> <td class="summary">Constants for game statuses.</td>
@ -311,6 +317,10 @@ local door = GetMoveableByName("door_type4_14")
<td class="name" ><a href="4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></td> <td class="name" ><a href="4 enums/Sound.SoundTrackType.html">Sound.SoundTrackType</a></td>
<td class="summary">Constants for the type of the audio tracks.</td> <td class="summary">Constants for the type of the audio tracks.</td>
</tr> </tr>
<tr>
<td class="name" ><a href="4 enums/Strings.DisplayStringOption.html">Strings.DisplayStringOption</a></td>
<td class="summary">Constants for Display String Options.</td>
</tr>
<tr> <tr>
<td class="name" ><a href="4 enums/Util.LogLevel.html">Util.LogLevel</a></td> <td class="name" ><a href="4 enums/Util.LogLevel.html">Util.LogLevel</a></td>
<td class="summary">Constants for LogLevel IDs.</td> <td class="summary">Constants for LogLevel IDs.</td>

View file

@ -141,9 +141,9 @@ table.index td { text-align: left; vertical-align: top; }
} }
#content { #content {
margin-left: 16em; margin-left: 18em;
padding: 1em; padding: 2em;
width: 700px; width: 900px;
border-left: 2px solid #cccccc; border-left: 2px solid #cccccc;
border-right: 2px solid #cccccc; border-right: 2px solid #cccccc;
background-color: #ffffff; background-color: #ffffff;
@ -220,7 +220,6 @@ table.function_list td.name { background-color: #f0f0f0; min-width: 250px; }
table.function_list td.summary { width: 100%; } table.function_list td.summary { width: 100%; }
ul.nowrap { ul.nowrap {
overflow:auto;
white-space:nowrap; white-space:nowrap;
} }

View file

@ -141,9 +141,9 @@ table.index td { text-align: left; vertical-align: top; }
} }
#content { #content {
margin-left: 16em; margin-left: 18em;
padding: 1em; padding: 2em;
width: 700px; width: 900px;
border-left: 2px solid #cccccc; border-left: 2px solid #cccccc;
border-right: 2px solid #cccccc; border-right: 2px solid #cccccc;
background-color: #ffffff; background-color: #ffffff;
@ -220,7 +220,6 @@ table.function_list td.name { background-color: #f0f0f0; min-width: 250px; }
table.function_list td.summary { width: 100%; } table.function_list td.summary { width: 100%; }
ul.nowrap { ul.nowrap {
overflow:auto;
white-space:nowrap; white-space:nowrap;
} }

View file

@ -5,6 +5,7 @@ local Flow = TEN.Flow
local settings = Flow.Settings.new() local settings = Flow.Settings.new()
settings.errorMode = Flow.ErrorMode.WARN settings.errorMode = Flow.ErrorMode.WARN
settings.fastReload = true
Flow.SetSettings(settings) Flow.SetSettings(settings)
local anims = Flow.Animations.new() local anims = Flow.Animations.new()

View file

@ -82,7 +82,7 @@ constexpr auto LARA_STAMINA_MIN = LARA_STAMINA_MAX / 10;
constexpr auto LARA_STAMINA_CRITICAL = LARA_STAMINA_MAX / 2; constexpr auto LARA_STAMINA_CRITICAL = LARA_STAMINA_MAX / 2;
constexpr auto PLAYER_DRIP_NODE_MAX = 64.0f; constexpr auto PLAYER_DRIP_NODE_MAX = 64.0f;
constexpr auto PLAYER_BUBBLE_NODE_MAX = 12.0f; constexpr auto PLAYER_BUBBLE_NODE_MAX = 8.0f;
constexpr auto STEPUP_HEIGHT = (int)CLICK(1.5f); constexpr auto STEPUP_HEIGHT = (int)CLICK(1.5f);
constexpr auto CRAWL_STEPUP_HEIGHT = CLICK(1) - 1; constexpr auto CRAWL_STEPUP_HEIGHT = CLICK(1) - 1;

View file

@ -874,7 +874,7 @@ FireWeaponType FireWeapon(LaraWeaponType weaponType, ItemInfo& targetEntity, Ite
} }
} }
if (closestJointIndex < 0) if (closestJointIndex == NO_VALUE)
{ {
auto vTarget = GameVector(target); auto vTarget = GameVector(target);
GetTargetOnLOS(&vOrigin, &vTarget, false, true); GetTargetOnLOS(&vOrigin, &vTarget, false, true);
@ -1109,6 +1109,9 @@ void HitTarget(ItemInfo* laraItem, ItemInfo* targetEntity, GameVector* hitPos, i
if (targetEntity->IsCreature()) if (targetEntity->IsCreature())
GetCreatureInfo(targetEntity)->HurtByLara = true; GetCreatureInfo(targetEntity)->HurtByLara = true;
if (object.HitRoutine == nullptr)
return;
if (hitPos != nullptr) if (hitPos != nullptr)
{ {
hitPos->RoomNumber = targetEntity->RoomNumber; hitPos->RoomNumber = targetEntity->RoomNumber;

View file

@ -260,7 +260,7 @@ void DrawFlare(ItemInfo& laraItem)
SoundEffect( SoundEffect(
SFX_TR4_FLARE_IGNITE_DRY, SFX_TR4_FLARE_IGNITE_DRY,
&laraItem.Pose, &laraItem.Pose,
TestEnvironment(ENV_FLAG_WATER, &laraItem) ? SoundEnvironment::ShallowWater : SoundEnvironment::Land); TestEnvironment(ENV_FLAG_WATER, &laraItem) ? SoundEnvironment::Underwater : SoundEnvironment::Land);
} }
DoFlareInHand(laraItem, player.Flare.Life); DoFlareInHand(laraItem, player.Flare.Life);

View file

@ -726,7 +726,7 @@ static void GivePlayerItemsCheat(ItemInfo& item)
player.Inventory.Puzzles[i] = true; player.Inventory.Puzzles[i] = true;
player.Inventory.PuzzlesCombo[2 * i] = false; player.Inventory.PuzzlesCombo[2 * i] = false;
player.Inventory.PuzzlesCombo[(92 * i) + 1] = false; player.Inventory.PuzzlesCombo[(2 * i) + 1] = false;
} }
for (int i = 0; i < 8; ++i) for (int i = 0; i < 8; ++i)
@ -895,7 +895,9 @@ void HandlePlayerFlyCheat(ItemInfo& item)
{ {
SetAnimation(item, LA_FLY_CHEAT); SetAnimation(item, LA_FLY_CHEAT);
ResetPlayerFlex(&item); ResetPlayerFlex(&item);
item.Animation.IsAirborne = false; item.Animation.Velocity = Vector3::Zero;
item.Animation.IsAirborne = true;
item.Pose.Position.y -= CLICK(0.5f);
item.HitPoints = LARA_HEALTH_MAX; item.HitPoints = LARA_HEALTH_MAX;
player.Control.WaterStatus = WaterStatus::FlyCheat; player.Control.WaterStatus = WaterStatus::FlyCheat;
@ -953,7 +955,7 @@ void HandlePlayerWetnessDrips(ItemInfo& item)
void HandlePlayerDiveBubbles(ItemInfo& item) void HandlePlayerDiveBubbles(ItemInfo& item)
{ {
constexpr auto BUBBLE_COUNT_MULT = 6; constexpr auto BUBBLE_COUNT_MULT = 3;
auto& player = *GetLaraInfo(&item); auto& player = *GetLaraInfo(&item);
@ -990,7 +992,7 @@ void HandlePlayerAirBubbles(ItemInfo* item)
{ {
constexpr auto BUBBLE_COUNT_MAX = 3; constexpr auto BUBBLE_COUNT_MAX = 3;
SoundEffect(SFX_TR4_LARA_BUBBLES, &item->Pose, SoundEnvironment::ShallowWater); SoundEffect(SFX_TR4_LARA_BUBBLES, &item->Pose, SoundEnvironment::Underwater);
const auto& level = *g_GameFlow->GetLevel(CurrentLevel); const auto& level = *g_GameFlow->GetLevel(CurrentLevel);
@ -1467,7 +1469,7 @@ void UpdateLaraSubsuitAngles(ItemInfo* item)
auto mul1 = (float)abs(lara->Control.Subsuit.Velocity[0]) / BLOCK(8); auto mul1 = (float)abs(lara->Control.Subsuit.Velocity[0]) / BLOCK(8);
auto mul2 = (float)abs(lara->Control.Subsuit.Velocity[1]) / BLOCK(8); auto mul2 = (float)abs(lara->Control.Subsuit.Velocity[1]) / BLOCK(8);
auto vol = ((mul1 + mul2) * 5.0f) + 0.5f; auto vol = ((mul1 + mul2) * 5.0f) + 0.5f;
SoundEffect(SFX_TR5_VEHICLE_DIVESUIT_ENGINE, &item->Pose, SoundEnvironment::ShallowWater, 1.0f + (mul1 + mul2), vol); SoundEffect(SFX_TR5_VEHICLE_DIVESUIT_ENGINE, &item->Pose, SoundEnvironment::Underwater, 1.0f + (mul1 + mul2), vol);
} }
} }

View file

@ -428,7 +428,7 @@ void FireShotgun(ItemInfo& laraItem)
player.RightArm.GunFlash = Weapons[(int)LaraWeaponType::Shotgun].FlashTime; player.RightArm.GunFlash = Weapons[(int)LaraWeaponType::Shotgun].FlashTime;
SoundEffect(SFX_TR4_EXPLOSION1, &laraItem.Pose, TestEnvironment(ENV_FLAG_WATER, &laraItem) ? SoundEnvironment::ShallowWater : SoundEnvironment::Land); SoundEffect(SFX_TR4_EXPLOSION1, &laraItem.Pose, TestEnvironment(ENV_FLAG_WATER, &laraItem) ? SoundEnvironment::Underwater : SoundEnvironment::Land);
SoundEffect(Weapons[(int)LaraWeaponType::Shotgun].SampleNum, &laraItem.Pose); SoundEffect(Weapons[(int)LaraWeaponType::Shotgun].SampleNum, &laraItem.Pose);
Rumble(0.5f, 0.2f); Rumble(0.5f, 0.2f);
@ -1568,7 +1568,7 @@ void HandleProjectile(ItemInfo& projectile, ItemInfo& emitter, const Vector3i& p
hasHit = hasHitNotByEmitter = doShatter = true; hasHit = hasHitNotByEmitter = doShatter = true;
doExplosion = isExplosive; doExplosion = isExplosive;
if (StaticObjects[staticPtr->staticNumber].shatterType == ShatterType::None) if (Statics[staticPtr->staticNumber].shatterType == ShatterType::None)
continue; continue;
staticPtr->HitPoints -= damage; staticPtr->HitPoints -= damage;

View file

@ -33,7 +33,7 @@ using namespace TEN::Entities;
using namespace TEN::Entities::Switches; using namespace TEN::Entities::Switches;
ObjectHandler Objects; ObjectHandler Objects;
StaticInfo StaticObjects[MAX_STATICS]; StaticHandler Statics;
void ObjectHandler::Initialize() void ObjectHandler::Initialize()
{ {
@ -76,6 +76,44 @@ ObjectInfo& ObjectHandler::GetFirstAvailableObject()
return _objects[0]; return _objects[0];
} }
void StaticHandler::Initialize()
{
_lookupTable.resize(0);
_lookupTable.reserve(_defaultLUTSize);
_statics.resize(0);
}
int StaticHandler::GetIndex(int staticID)
{
if (staticID < 0 || staticID >= _lookupTable.size())
{
TENLog("Attempt to get nonexistent static mesh ID slot index (" + std::to_string(staticID) + ")", LogLevel::Warning);
return _lookupTable.front();
}
return _lookupTable[staticID];
}
StaticInfo& StaticHandler::operator [](int staticID)
{
if (staticID < 0)
{
TENLog("Attempt to access illegal static mesh ID slot info", LogLevel::Warning);
return _statics.front();
}
if (staticID >= _lookupTable.size())
_lookupTable.resize(staticID + 1, NO_VALUE);
if (_lookupTable[staticID] != NO_VALUE)
return _statics[_lookupTable[staticID]];
_statics.emplace_back();
_lookupTable[staticID] = (int)_statics.size() - 1;
return _statics.back();
}
// NOTE: JointRotationFlags allows bones to be rotated with CreatureJoint(). // NOTE: JointRotationFlags allows bones to be rotated with CreatureJoint().
void ObjectInfo::SetBoneRotationFlags(int boneID, int flags) void ObjectInfo::SetBoneRotationFlags(int boneID, int flags)
{ {
@ -191,6 +229,7 @@ void InitializeObjects()
obj->hitEffect = HitEffect::None; obj->hitEffect = HitEffect::None;
obj->explodableMeshbits = 0; obj->explodableMeshbits = 0;
obj->intelligent = false; obj->intelligent = false;
obj->AlwaysActive = false;
obj->waterCreature = false; obj->waterCreature = false;
obj->nonLot = false; obj->nonLot = false;
obj->usingDrawAnimatingItem = true; obj->usingDrawAnimatingItem = true;

View file

@ -12,8 +12,6 @@ constexpr auto DEFAULT_RADIUS = 10;
constexpr auto GRAVITY = 6.0f; constexpr auto GRAVITY = 6.0f;
constexpr auto SWAMP_GRAVITY = GRAVITY / 3.0f; constexpr auto SWAMP_GRAVITY = GRAVITY / 3.0f;
constexpr auto MAX_STATICS = 1000;
enum JointRotationFlags enum JointRotationFlags
{ {
ROT_X = 1 << 2, ROT_X = 1 << 2,
@ -42,8 +40,7 @@ enum class LotType
Blockable, // For large creatures such as trex and shiva. Blockable, // For large creatures such as trex and shiva.
Spider, // Only 2 block vault allowed. Spider, // Only 2 block vault allowed.
Ape, // Only 2 block vault allowed. Ape, // Only 2 block vault allowed.
SnowmobileGun, // Only 1 block vault allowed and 4 block drop max. SnowmobileGun // Only 1 block vault allowed and 4 block drop max.
EnemyJeep
}; };
enum class HitEffect enum class HitEffect
@ -70,6 +67,7 @@ enum class ShatterType
Explode Explode
}; };
// TODO: All fields to PascalCase.
struct ObjectInfo struct ObjectInfo
{ {
bool loaded = false; // IsLoaded bool loaded = false; // IsLoaded
@ -89,13 +87,14 @@ struct ObjectInfo
int pivotLength; int pivotLength;
int radius; int radius;
int HitPoints; int HitPoints = 0;
bool intelligent; // IsIntelligent bool AlwaysActive = false;
bool waterCreature; // IsWaterCreature bool intelligent = false;
bool nonLot; // IsNonLot bool waterCreature = false;
bool isPickup; // IsPickup bool nonLot = false;
bool isPuzzleHole; // IsReceptacle bool isPickup = false;
bool usingDrawAnimatingItem; bool isPuzzleHole = false;
bool usingDrawAnimatingItem = false;
DWORD explodableMeshbits; DWORD explodableMeshbits;
@ -115,15 +114,13 @@ class ObjectHandler
{ {
private: private:
ObjectInfo _objects[ID_NUMBER_OBJECTS]; ObjectInfo _objects[ID_NUMBER_OBJECTS];
ObjectInfo& GetFirstAvailableObject();
public: public:
void Initialize(); void Initialize();
bool CheckID(GAME_OBJECT_ID objectID, bool isSilent = false); bool CheckID(GAME_OBJECT_ID objectID, bool isSilent = false);
ObjectInfo& operator [](int objectID); ObjectInfo& operator [](int objectID);
private:
ObjectInfo& GetFirstAvailableObject();
}; };
struct StaticInfo struct StaticInfo
@ -134,10 +131,34 @@ struct StaticInfo
GameBoundingBox collisionBox; GameBoundingBox collisionBox;
ShatterType shatterType; ShatterType shatterType;
int shatterSound; int shatterSound;
int ObjectNumber;
};
class StaticHandler
{
private:
static const int _defaultLUTSize = 256;
std::vector<StaticInfo> _statics = {};
std::vector<int> _lookupTable = {};
public:
void Initialize();
int GetIndex(int staticID);
StaticInfo& operator [](int staticID);
// Iterators
auto begin() { return _statics.begin(); } // Non-const begin
auto end() { return _statics.end(); } // Non-const end
auto begin() const { return _statics.cbegin(); } // Const begin
auto end() const { return _statics.cend(); } // Const end
auto cbegin() const { return _statics.cbegin(); } // Explicit const begin
auto cend() const { return _statics.cend(); } // Explicit const end
}; };
extern ObjectHandler Objects; extern ObjectHandler Objects;
extern StaticInfo StaticObjects[MAX_STATICS]; extern StaticHandler Statics;
void InitializeGameFlags(); void InitializeGameFlags();
void InitializeSpecialEffects(); void InitializeSpecialEffects();

View file

@ -39,7 +39,7 @@ static void PerformAnimCommands(ItemInfo& item, bool isFrameBased)
return; return;
// Get command data pointer. // Get command data pointer.
short* commandDataPtr = &g_Level.Commands[anim.CommandIndex]; int* commandDataPtr = &g_Level.Commands[anim.CommandIndex];
for (int i = anim.NumCommands; i > 0; i--) for (int i = anim.NumCommands; i > 0; i--)
{ {
@ -118,45 +118,11 @@ static void PerformAnimCommands(ItemInfo& item, bool isFrameBased)
int frameNumber = commandDataPtr[0]; int frameNumber = commandDataPtr[0];
if (isFrameBased && item.Animation.FrameNumber == frameNumber) if (isFrameBased && item.Animation.FrameNumber == frameNumber)
{ {
// Get sound ID and sound environment flag from packed data. // Get sound ID and sound environment flag.
int soundID = commandDataPtr[1] & 0xFFF; // Exclude last 4 bits for sound ID. int soundID = commandDataPtr[1];
int soundEnvFlag = commandDataPtr[1] & 0xF000; // Keep only last 4 bits for sound environment flag. auto requiredSoundEnv = (SoundEnvironment)commandDataPtr[2];
// FAILSAFE. int roomNumberAtPos = (item.RoomNumber == NO_VALUE) ? Camera.pos.RoomNumber : GetPointCollision(item).GetRoomNumber();
if (item.RoomNumber == NO_VALUE)
{
SoundEffect(soundID, &item.Pose, SoundEnvironment::Always);
commandDataPtr += 2;
break;
}
// Get required sound environment from flag.
auto requiredSoundEnv = SoundEnvironment::Always;
switch (soundEnvFlag)
{
default:
case 0:
requiredSoundEnv = SoundEnvironment::Always;
break;
case (1 << 14):
requiredSoundEnv = SoundEnvironment::Land;
break;
case (1 << 15):
requiredSoundEnv = SoundEnvironment::ShallowWater;
break;
case (1 << 12):
requiredSoundEnv = SoundEnvironment::Swamp;
break;
case (1 << 13):
requiredSoundEnv = SoundEnvironment::Underwater;
break;
}
int roomNumberAtPos = GetPointCollision(item).GetRoomNumber();
bool isWater = TestEnvironment(ENV_FLAG_WATER, roomNumberAtPos); bool isWater = TestEnvironment(ENV_FLAG_WATER, roomNumberAtPos);
bool isSwamp = TestEnvironment(ENV_FLAG_SWAMP, roomNumberAtPos); bool isSwamp = TestEnvironment(ENV_FLAG_SWAMP, roomNumberAtPos);
@ -201,13 +167,13 @@ static void PerformAnimCommands(ItemInfo& item, bool isFrameBased)
SoundEffect(soundID, &item.Pose, *soundEnv); SoundEffect(soundID, &item.Pose, *soundEnv);
} }
commandDataPtr += 2; commandDataPtr += 3;
}
break; break;
}
case AnimCommandType::Flipeffect: case AnimCommandType::Flipeffect:
if (isFrameBased && item.Animation.FrameNumber == commandDataPtr[0]) if (isFrameBased && item.Animation.FrameNumber == commandDataPtr[0])
DoFlipEffect((commandDataPtr[1] & 0x3FFF), &item); DoFlipEffect(commandDataPtr[1], &item);
commandDataPtr += 2; commandDataPtr += 2;
break; break;
@ -318,6 +284,8 @@ void AnimateItem(ItemInfo* item)
item->Pose.Position.y += item->Animation.Velocity.y; item->Pose.Position.y += item->Animation.Velocity.y;
} }
else else
{
if (item->Animation.ActiveState != LS_FLY_CHEAT)
{ {
item->Animation.Velocity.y += GetEffectiveGravity(item->Animation.Velocity.y); item->Animation.Velocity.y += GetEffectiveGravity(item->Animation.Velocity.y);
item->Animation.Velocity.z += animAccel.z; item->Animation.Velocity.z += animAccel.z;
@ -325,6 +293,7 @@ void AnimateItem(ItemInfo* item)
item->Pose.Position.y += item->Animation.Velocity.y; item->Pose.Position.y += item->Animation.Velocity.y;
} }
} }
}
else else
{ {
item->Animation.Velocity.y += GetEffectiveGravity(item->Animation.Velocity.y); item->Animation.Velocity.y += GetEffectiveGravity(item->Animation.Velocity.y);

View file

@ -49,8 +49,8 @@ struct OLD_CAMERA
Vector3i target; Vector3i target;
}; };
bool ItemCameraOn;
GameVector LastTarget; GameVector LastTarget;
GameVector LastIdeal; GameVector LastIdeal;
GameVector Ideals[5]; GameVector Ideals[5];
OLD_CAMERA OldCam; OLD_CAMERA OldCam;
@ -60,7 +60,6 @@ GameVector LookCamPosition;
GameVector LookCamTarget; GameVector LookCamTarget;
Vector3i CamOldPos; Vector3i CamOldPos;
CAMERA_INFO Camera; CAMERA_INFO Camera;
ObjectCameraInfo ItemCamera;
GameVector ForcedFixedCamera; GameVector ForcedFixedCamera;
int UseForcedFixedCamera; int UseForcedFixedCamera;
@ -403,13 +402,13 @@ void ObjCamera(ItemInfo* camSlotId, int camMeshId, ItemInfo* targetItem, int tar
{ {
//camSlotId and targetItem stay the same object until I know how to expand targetItem to another object. //camSlotId and targetItem stay the same object until I know how to expand targetItem to another object.
//activates code below -> void CalculateCamera(). //activates code below -> void CalculateCamera().
ItemCamera.ItemCameraOn = cond; ItemCameraOn = cond;
UpdateCameraElevation(); UpdateCameraElevation();
//get mesh 0 coordinates. //get mesh 0 coordinates.
auto pos = GetJointPosition(camSlotId, 0, Vector3i::Zero); auto pos = GetJointPosition(camSlotId, 0, Vector3i::Zero);
auto dest = Vector3(pos.x, pos.y, pos.z); auto dest = Vector3(pos.x, pos.y, pos.z) + camSlotId->Pose.Position.ToVector3();
GameVector from = GameVector(dest, camSlotId->RoomNumber); GameVector from = GameVector(dest, camSlotId->RoomNumber);
Camera.fixedCamera = true; Camera.fixedCamera = true;
@ -420,7 +419,7 @@ void ObjCamera(ItemInfo* camSlotId, int camMeshId, ItemInfo* targetItem, int tar
void ClearObjCamera() void ClearObjCamera()
{ {
ItemCamera.ItemCameraOn = false; ItemCameraOn = false;
} }
void MoveObjCamera(GameVector* ideal, ItemInfo* camSlotId, int camMeshId, ItemInfo* targetItem, int targetMeshId) void MoveObjCamera(GameVector* ideal, ItemInfo* camSlotId, int camMeshId, ItemInfo* targetItem, int targetMeshId)
@ -483,17 +482,10 @@ void MoveObjCamera(GameVector* ideal, ItemInfo* camSlotId, int camMeshId, ItemIn
speed = 2; speed = 2;
} }
//actual movement of the target. // Actual movement of the target.
Camera.target.x += (pos2.x - Camera.target.x) / speed; Camera.target.x += (pos2.x - Camera.target.x) / speed;
Camera.target.y += (pos2.y - Camera.target.y) / speed; Camera.target.y += (pos2.y - Camera.target.y) / speed;
Camera.target.z += (pos2.z - Camera.target.z) / speed; Camera.target.z += (pos2.z - Camera.target.z) / speed;
if (ItemCamera.LastAngle != position)
{
ItemCamera.LastAngle = Vector3i(ItemCamera.LastAngle.x = angle.x,
ItemCamera.LastAngle.y = angle.y,
ItemCamera.LastAngle.z = angle.z);
}
} }
void RefreshFixedCamera(short camNumber) void RefreshFixedCamera(short camNumber)
@ -522,6 +514,13 @@ void ChaseCamera(ItemInfo* item)
else if (Camera.actualElevation < ANGLE(-85.0f)) else if (Camera.actualElevation < ANGLE(-85.0f))
Camera.actualElevation = ANGLE(-85.0f); Camera.actualElevation = ANGLE(-85.0f);
// Force item position after exiting look mode to avoid weird movements near walls.
if (Camera.oldType == CameraType::Look)
{
Camera.target.x = item->Pose.Position.x;
Camera.target.z = item->Pose.Position.z;
}
int distance = Camera.targetDistance * phd_cos(Camera.actualElevation); int distance = Camera.targetDistance * phd_cos(Camera.actualElevation);
auto pointColl = GetPointCollision(Vector3i(Camera.target.x, Camera.target.y + CLICK(1), Camera.target.z), Camera.target.RoomNumber); auto pointColl = GetPointCollision(Vector3i(Camera.target.x, Camera.target.y + CLICK(1), Camera.target.z), Camera.target.RoomNumber);
@ -1074,7 +1073,6 @@ static bool CalculateDeathCamera(const ItemInfo& item)
// Special death animations. // Special death animations.
if (item.Animation.AnimNumber == LA_SPIKE_DEATH || if (item.Animation.AnimNumber == LA_SPIKE_DEATH ||
item.Animation.AnimNumber == LA_BOULDER_DEATH ||
item.Animation.AnimNumber == LA_TRAIN_OVERBOARD_DEATH) item.Animation.AnimNumber == LA_TRAIN_OVERBOARD_DEATH)
{ {
return true; return true;
@ -1095,10 +1093,8 @@ void CalculateCamera(const CollisionInfo& coll)
return; return;
} }
if (ItemCamera.ItemCameraOn) if (ItemCameraOn)
{
return; return;
}
if (UseForcedFixedCamera != 0) if (UseForcedFixedCamera != 0)
{ {
@ -1260,7 +1256,8 @@ void CalculateCamera(const CollisionInfo& coll)
if (isFixedCamera == Camera.fixedCamera) if (isFixedCamera == Camera.fixedCamera)
{ {
Camera.fixedCamera = false; Camera.fixedCamera = false;
if (Camera.speed != 1 &&
if (Camera.speed != 1 && Camera.oldType != CameraType::Look &&
!Lara.Control.Look.IsUsingBinoculars) !Lara.Control.Look.IsUsingBinoculars)
{ {
if (TargetSnaps <= 8) if (TargetSnaps <= 8)
@ -1331,8 +1328,13 @@ void CalculateCamera(const CollisionInfo& coll)
bool TestBoundsCollideCamera(const GameBoundingBox& bounds, const Pose& pose, short radius) bool TestBoundsCollideCamera(const GameBoundingBox& bounds, const Pose& pose, short radius)
{ {
auto sphere = BoundingSphere(Camera.pos.ToVector3(), radius); auto camSphere = BoundingSphere(Camera.pos.ToVector3(), radius);
return sphere.Intersects(bounds.ToBoundingOrientedBox(pose)); auto boundsSphere = BoundingSphere(pose.Position.ToVector3(), bounds.GetExtents().Length());
if (!camSphere.Intersects(boundsSphere))
return false;
return camSphere.Intersects(bounds.ToBoundingOrientedBox(pose));
} }
float GetParticleDistanceFade(const Vector3i& pos) float GetParticleDistanceFade(const Vector3i& pos)
@ -1507,10 +1509,13 @@ void ItemsCollideCamera()
if (TestBoundsCollideCamera(bounds, item->Pose, CAMERA_RADIUS)) if (TestBoundsCollideCamera(bounds, item->Pose, CAMERA_RADIUS))
ItemPushCamera(&bounds, &item->Pose, RADIUS); ItemPushCamera(&bounds, &item->Pose, RADIUS);
if (DebugMode)
{
DrawDebugBox( DrawDebugBox(
bounds.ToBoundingOrientedBox(item->Pose), bounds.ToBoundingOrientedBox(item->Pose),
Vector4(1.0f, 0.0f, 0.0f, 1.0f), RendererDebugPage::CollisionStats); Vector4(1.0f, 0.0f, 0.0f, 1.0f), RendererDebugPage::CollisionStats);
} }
}
// Done. // Done.
itemList.clear(); itemList.clear();
@ -1530,10 +1535,13 @@ void ItemsCollideCamera()
if (TestBoundsCollideCamera(bounds, mesh->pos, CAMERA_RADIUS)) if (TestBoundsCollideCamera(bounds, mesh->pos, CAMERA_RADIUS))
ItemPushCamera(&bounds, &mesh->pos, RADIUS); ItemPushCamera(&bounds, &mesh->pos, RADIUS);
if (DebugMode)
{
DrawDebugBox( DrawDebugBox(
bounds.ToBoundingOrientedBox(mesh->pos), bounds.ToBoundingOrientedBox(mesh->pos),
Vector4(1.0f, 0.0f, 0.0f, 1.0f), RendererDebugPage::CollisionStats); Vector4(1.0f, 0.0f, 0.0f, 1.0f), RendererDebugPage::CollisionStats);
} }
}
// Done. // Done.
staticList.clear(); staticList.clear();

View file

@ -1,6 +1,7 @@
#pragma once #pragma once
#include "Game/items.h" #include "Game/items.h"
#include "Math/Math.h" #include "Math/Math.h"
#include "Specific/Clock.h"
struct CollisionInfo; struct CollisionInfo;
@ -53,12 +54,6 @@ struct CAMERA_INFO
bool DisableInterpolation = false; bool DisableInterpolation = false;
}; };
struct ObjectCameraInfo
{
GameVector LastAngle;
bool ItemCameraOn;
};
enum CAMERA_FLAGS enum CAMERA_FLAGS
{ {
CF_NONE = 0, CF_NONE = 0,
@ -67,7 +62,7 @@ enum CAMERA_FLAGS
CF_CHASE_OBJECT = 3, CF_CHASE_OBJECT = 3,
}; };
constexpr auto FADE_SCREEN_SPEED = 16.0f / 255.0f; constexpr auto FADE_SCREEN_SPEED = 2.0f / FPS;
constexpr auto DEFAULT_FOV = 80.0f; constexpr auto DEFAULT_FOV = 80.0f;
extern CAMERA_INFO Camera; extern CAMERA_INFO Camera;

View file

@ -408,7 +408,7 @@ namespace TEN::Collision::Point
short slopeAngle = Geometry::GetSurfaceSlopeAngle(GetFloorNormal()); short slopeAngle = Geometry::GetSurfaceSlopeAngle(GetFloorNormal());
short steepSlopeAngle = (GetFloorBridgeItemNumber() != NO_VALUE) ? short steepSlopeAngle = (GetFloorBridgeItemNumber() != NO_VALUE) ?
DEFAULT_STEEP_FLOOR_SLOPE_ANGLE : DEFAULT_STEEP_FLOOR_SLOPE_ANGLE :
GetBottomSector().GetSurfaceIllegalSlopeAngle(_position.x, _position.z, true); GetBottomSector().GetSurfaceSteepSlopeAngle(_position.x, _position.z, true);
return (abs(slopeAngle) >= steepSlopeAngle); return (abs(slopeAngle) >= steepSlopeAngle);
} }
@ -418,7 +418,7 @@ namespace TEN::Collision::Point
short slopeAngle = Geometry::GetSurfaceSlopeAngle(GetCeilingNormal(), -Vector3::UnitY); short slopeAngle = Geometry::GetSurfaceSlopeAngle(GetCeilingNormal(), -Vector3::UnitY);
short steepSlopeAngle = (GetCeilingBridgeItemNumber() != NO_VALUE) ? short steepSlopeAngle = (GetCeilingBridgeItemNumber() != NO_VALUE) ?
DEFAULT_STEEP_CEILING_SLOPE_ANGLE : DEFAULT_STEEP_CEILING_SLOPE_ANGLE :
GetTopSector().GetSurfaceIllegalSlopeAngle(_position.x, _position.z, false); GetTopSector().GetSurfaceSteepSlopeAngle(_position.x, _position.z, false);
return (abs(slopeAngle) >= steepSlopeAngle); return (abs(slopeAngle) >= steepSlopeAngle);
} }

View file

@ -27,6 +27,7 @@ using namespace TEN::Collision::Sphere;
using namespace TEN::Math; using namespace TEN::Math;
constexpr auto ANIMATED_ALIGNMENT_FRAME_COUNT_THRESHOLD = 6; constexpr auto ANIMATED_ALIGNMENT_FRAME_COUNT_THRESHOLD = 6;
constexpr auto COLLIDABLE_BOUNDS_THRESHOLD = 4;
// Globals // Globals
@ -95,7 +96,6 @@ void GenericSphereBoxCollision(short itemNumber, ItemInfo* playerItem, Collision
CollidedObjectData GetCollidedObjects(ItemInfo& collidingItem, bool onlyVisible, bool ignorePlayer, float customRadius, ObjectCollectionMode mode) CollidedObjectData GetCollidedObjects(ItemInfo& collidingItem, bool onlyVisible, bool ignorePlayer, float customRadius, ObjectCollectionMode mode)
{ {
constexpr auto EXTENTS_LENGTH_MIN = 2.0f;
constexpr auto ROUGH_BOX_HEIGHT_MIN = BLOCK(1 / 8.0f); constexpr auto ROUGH_BOX_HEIGHT_MIN = BLOCK(1 / 8.0f);
auto collObjects = CollidedObjectData{}; auto collObjects = CollidedObjectData{};
@ -105,20 +105,20 @@ CollidedObjectData GetCollidedObjects(ItemInfo& collidingItem, bool onlyVisible,
// Establish parameters of colliding item. // Establish parameters of colliding item.
const auto& collidingBounds = GetBestFrame(collidingItem).BoundingBox; const auto& collidingBounds = GetBestFrame(collidingItem).BoundingBox;
auto collidingExtents = collidingBounds.GetExtents();
auto collidingSphere = BoundingSphere(collidingBounds.GetCenter() + collidingItem.Pose.Position.ToVector3(), collidingExtents.Length()); // Quickly discard collision if colliding item bounds are below tolerance threshold.
auto collidingCircle = Vector3(collidingSphere.Center.x, collidingSphere.Center.z, (customRadius > 0.0f) ? customRadius : std::hypot(collidingExtents.x, collidingExtents.z)); if (!customRadius && collidingBounds.GetExtents().Length() <= COLLIDABLE_BOUNDS_THRESHOLD)
return collObjects;
// Convert bounding box to DX bounds. // Convert bounding box to DX bounds.
auto convertedBounds = collidingBounds.ToBoundingOrientedBox(collidingItem.Pose); auto convertedBounds = collidingBounds.ToBoundingOrientedBox(collidingItem.Pose);
// Create conservative AABB for rough tests.
auto collidingAabb = collidingBounds.ToConservativeBoundingBox(collidingItem.Pose);
// Override extents if specified. // Override extents if specified.
if (customRadius > 0.0f) if (customRadius > 0.0f)
convertedBounds.Extents = Vector3(customRadius); collidingAabb = BoundingBox(collidingItem.Pose.Position.ToVector3(), Vector3(customRadius));
// Quickly discard collision if colliding item bounds are below tolerance threshold.
if (collidingSphere.Radius <= EXTENTS_LENGTH_MIN)
return collObjects;
// Run through neighboring rooms. // Run through neighboring rooms.
const auto& room = g_Level.Rooms[collidingItem.RoomNumber]; const auto& room = g_Level.Rooms[collidingItem.RoomNumber];
@ -151,13 +151,12 @@ CollidedObjectData GetCollidedObjects(ItemInfo& collidingItem, bool onlyVisible,
continue; continue;
// Ignore items not feasible for collision. // Ignore items not feasible for collision.
if (item.Index == collidingItem.Index || if (item.Index == collidingItem.Index || item.Flags & IFLAG_KILLED || item.MeshBits == NO_JOINT_BITS)
item.Flags & IFLAG_KILLED || item.MeshBits == NO_JOINT_BITS || continue;
(object.drawRoutine == nullptr && !item.IsLara()) ||
(object.collision == nullptr && !item.IsLara())) // Ignore non-collidable non-player.
{ if (!item.IsLara() && (!item.Collidable || object.drawRoutine == nullptr || object.collision == nullptr))
continue; continue;
}
// HACK: Ignore UPV and big gun. // HACK: Ignore UPV and big gun.
if ((item.ObjectNumber == ID_UPV || item.ObjectNumber == ID_BIGGUN) && item.HitPoints == 1) if ((item.ObjectNumber == ID_UPV || item.ObjectNumber == ID_BIGGUN) && item.HitPoints == 1)
@ -168,34 +167,19 @@ CollidedObjectData GetCollidedObjects(ItemInfo& collidingItem, bool onlyVisible,
if (dist > COLLISION_CHECK_DISTANCE) if (dist > COLLISION_CHECK_DISTANCE)
continue; continue;
const auto& bounds = GetBestFrame(item).BoundingBox;
auto extents = bounds.GetExtents();
// If item bounding box extents is below tolerance threshold, discard object. // If item bounding box extents is below tolerance threshold, discard object.
if (extents.Length() <= EXTENTS_LENGTH_MIN) const auto& bounds = GetBestFrame(item).BoundingBox;
if (bounds.GetExtents().Length() <= COLLIDABLE_BOUNDS_THRESHOLD)
continue; continue;
// Test rough vertical distance to discard objects not intersecting vertically. // Test conservative AABB intersection.
if (((collidingItem.Pose.Position.y + collidingBounds.Y1) - ROUGH_BOX_HEIGHT_MIN) > auto aabb = bounds.ToConservativeBoundingBox(item.Pose);
((item.Pose.Position.y + bounds.Y2) + ROUGH_BOX_HEIGHT_MIN)) if (!aabb.Intersects(collidingAabb))
{
continue;
}
if (((collidingItem.Pose.Position.y + collidingBounds.Y2) + ROUGH_BOX_HEIGHT_MIN) <
((item.Pose.Position.y + bounds.Y1) - ROUGH_BOX_HEIGHT_MIN))
{
continue;
}
// Test rough circle intersection to discard objects not intersecting horizontally.
auto circle = Vector3(item.Pose.Position.x, item.Pose.Position.z, std::hypot(extents.x, extents.z));
if (!Geometry::CircleIntersects(circle, collidingCircle))
continue; continue;
auto box = bounds.ToBoundingOrientedBox(item.Pose); // Test accurate OBB intersection.
auto obb = bounds.ToBoundingOrientedBox(item.Pose);
// Test accurate box intersection. if (obb.Intersects(convertedBounds))
if (box.Intersects(convertedBounds))
collObjects.Items.push_back(&item); collObjects.Items.push_back(&item);
} }
while (itemNumber != NO_VALUE); while (itemNumber != NO_VALUE);
@ -217,36 +201,19 @@ CollidedObjectData GetCollidedObjects(ItemInfo& collidingItem, bool onlyVisible,
if (dist > COLLISION_CHECK_DISTANCE) if (dist > COLLISION_CHECK_DISTANCE)
continue; continue;
const auto& bounds = GetBoundsAccurate(staticObj, false);
// Test rough vertical distance to discard statics not intersecting vertically.
if (((collidingItem.Pose.Position.y + collidingBounds.Y1) - ROUGH_BOX_HEIGHT_MIN) >
((staticObj.pos.Position.y + bounds.Y2) + ROUGH_BOX_HEIGHT_MIN))
{
continue;
}
if (((collidingItem.Pose.Position.y + collidingBounds.Y2) + ROUGH_BOX_HEIGHT_MIN) <
((staticObj.pos.Position.y + bounds.Y1) - ROUGH_BOX_HEIGHT_MIN))
{
continue;
}
// Test rough circle intersection to discard statics not intersecting horizontally.
auto circle = Vector3(staticObj.pos.Position.x, staticObj.pos.Position.z, (bounds.GetExtents() * Vector3(1.0f, 0.0f, 1.0f)).Length());
if (!Geometry::CircleIntersects(circle, collidingCircle))
continue;
// Skip if either bounding box has any zero extent (not a collidable volume). // Skip if either bounding box has any zero extent (not a collidable volume).
if (bounds.GetExtents().Length() <= EXTENTS_LENGTH_MIN) const auto& bounds = GetBoundsAccurate(staticObj, false);
if (bounds.GetExtents().Length() <= COLLIDABLE_BOUNDS_THRESHOLD)
continue; continue;
if (collidingBounds.GetExtents().Length() <= EXTENTS_LENGTH_MIN) // Test conservative AABB intersection.
auto aabb = bounds.ToConservativeBoundingBox(staticObj.pos);
if (!aabb.Intersects(collidingAabb))
continue; continue;
auto box = bounds.ToBoundingOrientedBox(staticObj.pos.Position); // Test accurate OBB intersection.
auto obb = bounds.ToBoundingOrientedBox(staticObj.pos.Position);
// Test accurate box intersection. if (obb.Intersects(convertedBounds))
if (box.Intersects(convertedBounds))
collObjects.Statics.push_back(&staticObj); collObjects.Statics.push_back(&staticObj);
} }
} }
@ -971,13 +938,13 @@ bool CollideSolidBounds(ItemInfo* item, const GameBoundingBox& box, const Pose&
{ {
bool result = false; bool result = false;
// Ignore processing null bounds.
if (box.GetExtents().Length() <= COLLIDABLE_BOUNDS_THRESHOLD)
return false;
// Get DX static bounds in global coordinates. // Get DX static bounds in global coordinates.
auto staticBounds = box.ToBoundingOrientedBox(pose); auto staticBounds = box.ToBoundingOrientedBox(pose);
// Ignore processing null bounds.
if (Vector3(staticBounds.Extents) == Vector3::Zero)
return false;
// Get local TR bounds and DX item bounds in global coordinates. // Get local TR bounds and DX item bounds in global coordinates.
auto itemBBox = GameBoundingBox(item); auto itemBBox = GameBoundingBox(item);
auto itemBounds = itemBBox.ToBoundingOrientedBox(item->Pose); auto itemBounds = itemBBox.ToBoundingOrientedBox(item->Pose);
@ -1805,7 +1772,7 @@ void DoObjectCollision(ItemInfo* item, CollisionInfo* coll)
if (isPlayer) if (isPlayer)
{ {
GetLaraInfo(*item).HitDirection = -1; GetLaraInfo(*item).HitDirection = NO_VALUE;
if (item->HitPoints <= 0) if (item->HitPoints <= 0)
return; return;
@ -1874,10 +1841,9 @@ void DoObjectCollision(ItemInfo* item, CollisionInfo* coll)
if (linkItem.HitPoints <= 0 || linkItem.HitPoints == NOT_TARGETABLE) if (linkItem.HitPoints <= 0 || linkItem.HitPoints == NOT_TARGETABLE)
continue; continue;
if (isHarmless || abs(item->Animation.Velocity.z) < VEHICLE_COLLISION_TERMINAL_VELOCITY || if (isHarmless || abs(item->Animation.Velocity.z) < VEHICLE_COLLISION_TERMINAL_VELOCITY)
object.damageType == DamageMode::None)
{ {
// If vehicle is harmless, enemy is non-damageable, or speed is too low, push enemy. // If vehicle is harmless or speed is too low, just push enemy.
ItemPushItem(&linkItem, item, coll, false, 0); ItemPushItem(&linkItem, item, coll, false, 0);
continue; continue;
} }
@ -1921,7 +1887,7 @@ void DoObjectCollision(ItemInfo* item, CollisionInfo* coll)
// HACK: Shatter statics only by harmful vehicles. // HACK: Shatter statics only by harmful vehicles.
if (!isPlayer && if (!isPlayer &&
!isHarmless && abs(item->Animation.Velocity.z) > VEHICLE_COLLISION_TERMINAL_VELOCITY && !isHarmless && abs(item->Animation.Velocity.z) > VEHICLE_COLLISION_TERMINAL_VELOCITY &&
StaticObjects[staticObject.staticNumber].shatterType != ShatterType::None) Statics[staticObject.staticNumber].shatterType != ShatterType::None)
{ {
SoundEffect(GetShatterSound(staticObject.staticNumber), &staticObject.pos); SoundEffect(GetShatterSound(staticObject.staticNumber), &staticObject.pos);
ShatterObject(nullptr, &staticObject, -128, item->RoomNumber, 0); ShatterObject(nullptr, &staticObject, -128, item->RoomNumber, 0);

View file

@ -41,9 +41,16 @@ int FloorInfo::GetSurfaceTriangleID(int x, int z, bool isFloor) const
constexpr auto TRI_ID_0 = 0; constexpr auto TRI_ID_0 = 0;
constexpr auto TRI_ID_1 = 1; constexpr auto TRI_ID_1 = 1;
static const auto ROT_MATRIX_0 = Matrix::CreateRotationZ(TO_RAD(SectorSurfaceData::SPLIT_ANGLE_0));
static const auto ROT_MATRIX_1 = Matrix::CreateRotationZ(TO_RAD(SectorSurfaceData::SPLIT_ANGLE_1));
// Get matrix.
const auto& rotMatrix = isFloor ?
((FloorSurface.SplitAngle == SectorSurfaceData::SPLIT_ANGLE_0) ? ROT_MATRIX_0 : ROT_MATRIX_1) :
((CeilingSurface.SplitAngle == SectorSurfaceData::SPLIT_ANGLE_0) ? ROT_MATRIX_0 : ROT_MATRIX_1);
// Calculate bias. // Calculate bias.
auto sectorPoint = GetSectorPoint(x, z).ToVector2(); auto sectorPoint = GetSectorPoint(x, z).ToVector2();
auto rotMatrix = Matrix::CreateRotationZ(TO_RAD(isFloor ? FloorSurface.SplitAngle : CeilingSurface.SplitAngle));
float bias = Vector2::Transform(sectorPoint, rotMatrix).x; float bias = Vector2::Transform(sectorPoint, rotMatrix).x;
// Return triangle ID according to bias. // Return triangle ID according to bias.
@ -76,7 +83,7 @@ Vector3 FloorInfo::GetSurfaceNormal(int x, int z, bool isFloor) const
return GetSurfaceNormal(triID, isFloor); return GetSurfaceNormal(triID, isFloor);
} }
short FloorInfo::GetSurfaceIllegalSlopeAngle(int x, int z, bool isFloor) const short FloorInfo::GetSurfaceSteepSlopeAngle(int x, int z, bool isFloor) const
{ {
const auto& tri = GetSurfaceTriangle(x, z, isFloor); const auto& tri = GetSurfaceTriangle(x, z, isFloor);
return tri.SteepSlopeAngle; return tri.SteepSlopeAngle;
@ -223,21 +230,16 @@ int FloorInfo::GetSurfaceHeight(const Vector3i& pos, bool isFloor) const
auto bridgeCeilingHeight = bridge.GetCeilingHeight(bridgeItem, pos); auto bridgeCeilingHeight = bridge.GetCeilingHeight(bridgeItem, pos);
// 2.1) Get bridge surface height. // 2.1) Get bridge surface height.
auto bridgeSurfaceHeight = isFloor ? bridge.GetFloorHeight(bridgeItem, pos) : bridge.GetCeilingHeight(bridgeItem, pos); auto bridgeSurfaceHeight = isFloor ? bridgeFloorHeight : bridgeCeilingHeight;
if (!bridgeSurfaceHeight.has_value()) if (!bridgeSurfaceHeight.has_value())
continue; continue;
// Use bridge midpoint to decide whether to return bridge height or room height, in case probe point
// is located within the bridge. Without it, dynamic bridges may fail while Lara is standing on them.
int thickness = bridge.GetCeilingBorder(bridgeItem) - bridge.GetFloorBorder(bridgeItem);
int midpoint = bridgeItem.Pose.Position.y + thickness / 2;
// 2.2) Track closest floor or ceiling height. // 2.2) Track closest floor or ceiling height.
if (isFloor) if (isFloor)
{ {
// Test if bridge floor height is closer. // Test if bridge floor height is closer.
if (midpoint >= pos.y && // Bridge midpoint is below position. if (*bridgeCeilingHeight >= pos.y && // Bridge midpoint is below position.
*bridgeSurfaceHeight < floorHeight && // Bridge floor height is above current closest floor height. *bridgeSurfaceHeight < floorHeight && // Bridge floor height is above current closest floor height.
*bridgeSurfaceHeight >= ceilingHeight) // Bridge ceiling height is below sector ceiling height. *bridgeSurfaceHeight >= ceilingHeight) // Bridge ceiling height is below sector ceiling height.
{ {
@ -247,7 +249,7 @@ int FloorInfo::GetSurfaceHeight(const Vector3i& pos, bool isFloor) const
else else
{ {
// Test if bridge ceiling height is closer. // Test if bridge ceiling height is closer.
if (midpoint <= pos.y && // Bridge midpoint is above position. if (*bridgeFloorHeight <= pos.y && // Bridge midpoint is above position.
*bridgeSurfaceHeight > ceilingHeight && // Bridge ceiling height is below current closest ceiling height. *bridgeSurfaceHeight > ceilingHeight && // Bridge ceiling height is below current closest ceiling height.
*bridgeSurfaceHeight <= floorHeight) // Bridge floor height is above sector floor height. *bridgeSurfaceHeight <= floorHeight) // Bridge floor height is above sector floor height.
{ {
@ -879,7 +881,7 @@ namespace TEN::Collision::Floordata
} }
// Updates BridgeItem for all blocks which are enclosed by bridge bounds. // Updates BridgeItem for all blocks which are enclosed by bridge bounds.
void UpdateBridgeItem(const ItemInfo& item, bool forceRemoval) void UpdateBridgeItem(const ItemInfo& item, BridgeUpdateType updateType)
{ {
constexpr auto SECTOR_EXTENTS = Vector3(BLOCK(0.5f)); constexpr auto SECTOR_EXTENTS = Vector3(BLOCK(0.5f));
@ -891,7 +893,7 @@ namespace TEN::Collision::Floordata
// Force removal if item was killed. // Force removal if item was killed.
if (item.Flags & IFLAG_KILLED) if (item.Flags & IFLAG_KILLED)
forceRemoval = true; updateType = BridgeUpdateType::Remove;
// Get bridge OBB. // Get bridge OBB.
auto bridgeBox = GameBoundingBox(&item).ToBoundingOrientedBox(item.Pose); auto bridgeBox = GameBoundingBox(&item).ToBoundingOrientedBox(item.Pose);
@ -919,10 +921,11 @@ namespace TEN::Collision::Floordata
float offZ = pZ - item.Pose.Position.z; float offZ = pZ - item.Pose.Position.z;
// Clean previous bridge state. // Clean previous bridge state.
if (updateType != BridgeUpdateType::Initialize)
RemoveBridge(item.Index, offX, offZ); RemoveBridge(item.Index, offX, offZ);
// In sweep mode; don't try readding to sector. // In removal mode; don't try re-adding to sector.
if (forceRemoval) if (updateType == BridgeUpdateType::Remove)
continue; continue;
// Sector is outside enclosed AABB space; ignore precise check. // Sector is outside enclosed AABB space; ignore precise check.

View file

@ -55,6 +55,13 @@ enum class ClimbDirectionFlags
West = 1 << 11 West = 1 << 11
}; };
enum class BridgeUpdateType
{
Normal,
Initialize,
Remove
};
// NOTE: Describes vertical room location. // NOTE: Describes vertical room location.
class RoomVector class RoomVector
{ {
@ -154,7 +161,7 @@ public:
const SectorSurfaceTriangleData& GetSurfaceTriangle(int x, int z, bool isFloor) const; const SectorSurfaceTriangleData& GetSurfaceTriangle(int x, int z, bool isFloor) const;
Vector3 GetSurfaceNormal(int triID, bool isFloor) const; Vector3 GetSurfaceNormal(int triID, bool isFloor) const;
Vector3 GetSurfaceNormal(int x, int z, bool isFloor) const; Vector3 GetSurfaceNormal(int x, int z, bool isFloor) const;
short GetSurfaceIllegalSlopeAngle(int x, int z, bool isFloor) const; short GetSurfaceSteepSlopeAngle(int x, int z, bool isFloor) const;
MaterialType GetSurfaceMaterial(int x, int z, bool isFloor) const; MaterialType GetSurfaceMaterial(int x, int z, bool isFloor) const;
std::optional<int> GetNextRoomNumber(int x, int z, bool isBelow) const; std::optional<int> GetNextRoomNumber(int x, int z, bool isBelow) const;
@ -201,7 +208,7 @@ namespace TEN::Collision::Floordata
std::optional<int> GetBridgeItemIntersect(const ItemInfo& item, const Vector3i& pos, bool useBottomHeight); std::optional<int> GetBridgeItemIntersect(const ItemInfo& item, const Vector3i& pos, bool useBottomHeight);
int GetBridgeBorder(const ItemInfo& item, bool isBottom); int GetBridgeBorder(const ItemInfo& item, bool isBottom);
void UpdateBridgeItem(const ItemInfo& item, bool forceRemoval = false); void UpdateBridgeItem(const ItemInfo& item, BridgeUpdateType updateType = BridgeUpdateType::Normal);
bool TestMaterial(MaterialType refMaterial, const std::vector<MaterialType>& materials); bool TestMaterial(MaterialType refMaterial, const std::vector<MaterialType>& materials);

View file

@ -1297,15 +1297,11 @@ void GetAITarget(CreatureInfo* creature)
{ {
auto* enemy = creature->Enemy; auto* enemy = creature->Enemy;
int enemyObjectID = 0; short enemyObjectNumber;
if (enemy) if (enemy)
{ enemyObjectNumber = enemy->ObjectNumber;
enemyObjectID = enemy->ObjectNumber;
}
else else
{ enemyObjectNumber = NO_VALUE;
enemyObjectID = NO_VALUE;
}
auto* item = &g_Level.Items[creature->ItemNumber]; auto* item = &g_Level.Items[creature->ItemNumber];
@ -1333,12 +1329,12 @@ void GetAITarget(CreatureInfo* creature)
} }
else if (!creature->Patrol) else if (!creature->Patrol)
{ {
if (enemyObjectID != ID_AI_PATROL1) if (enemyObjectNumber != ID_AI_PATROL1)
FindAITargetObject(*item, ID_AI_PATROL1); FindAITargetObject(creature, ID_AI_PATROL1);
} }
else if (enemyObjectID != ID_AI_PATROL2) else if (enemyObjectNumber != ID_AI_PATROL2)
{ {
FindAITargetObject(*item, ID_AI_PATROL2); FindAITargetObject(creature, ID_AI_PATROL2);
} }
else if (abs(enemy->Pose.Position.x - item->Pose.Position.x) < REACHED_GOAL_RADIUS && else if (abs(enemy->Pose.Position.x - item->Pose.Position.x) < REACHED_GOAL_RADIUS &&
abs(enemy->Pose.Position.y - item->Pose.Position.y) < REACHED_GOAL_RADIUS && abs(enemy->Pose.Position.y - item->Pose.Position.y) < REACHED_GOAL_RADIUS &&
@ -1354,8 +1350,8 @@ void GetAITarget(CreatureInfo* creature)
// First if was removed probably after TR3 and was it used by monkeys? // First if was removed probably after TR3 and was it used by monkeys?
/*if (!(item->aiBits & MODIFY) && !creature->hurtByLara) /*if (!(item->aiBits & MODIFY) && !creature->hurtByLara)
creature->enemy = LaraItem; creature->enemy = LaraItem;
else*/ if (enemyObjectID != ID_AI_AMBUSH) else*/ if (enemyObjectNumber != ID_AI_AMBUSH)
FindAITargetObject(*item, ID_AI_AMBUSH); FindAITargetObject(creature, ID_AI_AMBUSH);
/*else if (item->objectNumber == ID_MONKEY) /*else if (item->objectNumber == ID_MONKEY)
return;*/ return;*/
else if (abs(enemy->Pose.Position.x - item->Pose.Position.x) < REACHED_GOAL_RADIUS && else if (abs(enemy->Pose.Position.x - item->Pose.Position.x) < REACHED_GOAL_RADIUS &&
@ -1366,7 +1362,6 @@ void GetAITarget(CreatureInfo* creature)
creature->ReachedGoal = true; creature->ReachedGoal = true;
creature->Enemy = LaraItem; creature->Enemy = LaraItem;
item->AIBits &= ~(AMBUSH /* | MODIFY*/); item->AIBits &= ~(AMBUSH /* | MODIFY*/);
if (item->AIBits != MODIFY) if (item->AIBits != MODIFY)
{ {
item->AIBits |= GUARD; item->AIBits |= GUARD;
@ -1386,9 +1381,9 @@ void GetAITarget(CreatureInfo* creature)
{ {
item->AIBits &= ~FOLLOW; item->AIBits &= ~FOLLOW;
} }
else if (enemyObjectID != ID_AI_FOLLOW) else if (enemyObjectNumber != ID_AI_FOLLOW)
{ {
FindAITargetObject(*item, ID_AI_FOLLOW); FindAITargetObject(creature, ID_AI_FOLLOW);
} }
else if (abs(enemy->Pose.Position.x - item->Pose.Position.x) < REACHED_GOAL_RADIUS && else if (abs(enemy->Pose.Position.x - item->Pose.Position.x) < REACHED_GOAL_RADIUS &&
abs(enemy->Pose.Position.y - item->Pose.Position.y) < REACHED_GOAL_RADIUS && abs(enemy->Pose.Position.y - item->Pose.Position.y) < REACHED_GOAL_RADIUS &&
@ -1398,18 +1393,17 @@ void GetAITarget(CreatureInfo* creature)
item->AIBits &= ~FOLLOW; item->AIBits &= ~FOLLOW;
} }
} }
/*else if (item->objectNumber == ID_MONKEY && item->carriedItem == NO_VALUE)
/*else if (item->ObjectNumber == ID_MONKEY && item->CarriedItem == NO_VALUE)
{ {
if (item->AIBits != MODIFY) if (item->aiBits != MODIFY)
{ {
if (enemyObjectID != ID_SMALLMEDI_ITEM) if (enemyObjectNumber != ID_SMALLMEDI_ITEM)
FindAITargetObject(*item, ID_SMALLMEDI_ITEM); FindAITargetObject(creature, ID_SMALLMEDI_ITEM);
} }
else else
{ {
if (enemyObjectID != ID_KEY_ITEM4) if (enemyObjectNumber != ID_KEY_ITEM4)
FindAITargetObject(*item, ID_KEY_ITEM4); FindAITargetObject(creature, ID_KEY_ITEM4);
} }
}*/ }*/
} }
@ -1438,101 +1432,69 @@ void FindAITarget(CreatureInfo* creature, short objectNumber)
} }
} }
void FindAITargetObject(ItemInfo& item, GAME_OBJECT_ID objectID, std::optional<int> ocb, std::optional<bool> checkSameZone) void FindAITargetObject(CreatureInfo* creature, int objectNumber)
{ {
auto& creature = *GetCreatureInfo(&item); const auto& item = g_Level.Items[creature->ItemNumber];
auto data = AITargetData{}; FindAITargetObject(creature, objectNumber, item.ItemFlags[3], true);
data.CheckDistance = false;
data.CheckOcb = ocb.has_value();
data.ObjectID = objectID;
data.Ocb = ocb.value_or(item.ItemFlags[3]);
data.CheckSameZone = checkSameZone.value_or(true);
if (FindAITargetObject(item, data))
{
*creature.AITarget = data.FoundItem;
creature.Enemy = creature.AITarget;
}
} }
bool FindAITargetObject(ItemInfo& item, AITargetData& data) void FindAITargetObject(CreatureInfo* creature, int objectNumber, int ocb, bool checkSameZone)
{ {
auto& item = g_Level.Items[creature->ItemNumber];
if (g_Level.AIObjects.empty()) if (g_Level.AIObjects.empty())
return false; return;
auto& creature = *GetCreatureInfo(&item); AI_OBJECT* foundObject = nullptr;
const AI_OBJECT* foundAIObject = nullptr; for (auto& aiObject : g_Level.AIObjects)
for (const auto& aiObject : g_Level.AIObjects)
{ {
// Check if object IDs match. if (aiObject.objectNumber == objectNumber &&
if (aiObject.objectNumber != data.ObjectID) aiObject.triggerFlags == ocb &&
continue; aiObject.roomNumber != NO_VALUE)
// Check if room is valid.
if (aiObject.roomNumber == NO_VALUE)
continue;
// Check if distance is valid.
if (data.CheckDistance)
{ {
if (Vector3i::Distance(item.Pose.Position, aiObject.pos.Position) > data.DistanceMax) int* zone = g_Level.Zones[(int)creature->LOT.Zone][(int)FlipStatus].data();
continue;
}
// Check if OCBs match (useful for pathfinding).
if (data.CheckOcb)
{
if (aiObject.triggerFlags != data.Ocb)
continue;
}
// Check if zone IDs match.
if (data.CheckSameZone)
{
int* zone = g_Level.Zones[(int)creature.LOT.Zone][(int)FlipStatus].data();
auto* room = &g_Level.Rooms[item.RoomNumber]; auto* room = &g_Level.Rooms[item.RoomNumber];
// NOTE: Avoid changing box ID of item or AI item so a local variable isn't required when searching for AI object near it. item.BoxNumber = GetSector(room, item.Pose.Position.x - room->Position.x, item.Pose.Position.z - room->Position.z)->PathfindingBoxID;
int boxID = GetSector(room, item.Pose.Position.x - room->Position.x, item.Pose.Position.z - room->Position.z)->PathfindingBoxID;
room = &g_Level.Rooms[aiObject.roomNumber]; room = &g_Level.Rooms[aiObject.roomNumber];
int aiBoxID = GetSector(room, aiObject.pos.Position.x - room->Position.x, aiObject.pos.Position.z - room->Position.z)->PathfindingBoxID; aiObject.boxNumber = GetSector(room, aiObject.pos.Position.x - room->Position.x, aiObject.pos.Position.z - room->Position.z)->PathfindingBoxID;
// Box is invalid or zones don't match; continue. if (item.BoxNumber == NO_VALUE || aiObject.boxNumber == NO_VALUE)
if (boxID == NO_VALUE || aiBoxID == NO_VALUE) return;
continue;
// Zone is invalid; continue. if (checkSameZone && (zone[item.BoxNumber] != zone[aiObject.boxNumber]))
if (zone[boxID] != zone[aiBoxID]) return;
continue;
// Don't check for same zone. Needed for Sophia Leigh.
foundObject = &aiObject;
}
} }
// HACK: Don't check for matching zone. Needed for Sophia Leigh. if (foundObject == nullptr)
foundAIObject = &aiObject; return;
}
if (foundAIObject == nullptr) auto& aiItem = *creature->AITarget;
return false;
auto aiItem = ItemInfo{}; creature->Enemy = &aiItem;
aiItem.ObjectNumber = foundAIObject->objectNumber;
aiItem.RoomNumber = foundAIObject->roomNumber;
aiItem.Pose.Position = foundAIObject->pos.Position;
aiItem.Pose.Orientation.y = foundAIObject->pos.Orientation.y;
aiItem.Flags = foundAIObject->flags;
aiItem.TriggerFlags = foundAIObject->triggerFlags;
aiItem.BoxNumber = foundAIObject->boxNumber;
if (!(aiItem.Flags & IFLAG_TRIGGERED)) aiItem.ObjectNumber = foundObject->objectNumber;
aiItem.RoomNumber = foundObject->roomNumber;
aiItem.Pose.Position = foundObject->pos.Position;
aiItem.Pose.Orientation.y = foundObject->pos.Orientation.y;
aiItem.Flags = foundObject->flags;
aiItem.TriggerFlags = foundObject->triggerFlags;
aiItem.BoxNumber = foundObject->boxNumber;
if (!(creature->AITarget->Flags & ItemFlags::IFLAG_TRIGGERED))
{ {
aiItem.Pose.Position.x += CLICK(1) * phd_sin(aiItem.Pose.Orientation.y); float sinY = phd_sin(creature->AITarget->Pose.Orientation.y);
aiItem.Pose.Position.z += CLICK(1) * phd_cos(aiItem.Pose.Orientation.y); float cosY = phd_cos(creature->AITarget->Pose.Orientation.y);
}
data.FoundItem = aiItem; creature->AITarget->Pose.Position.x += CLICK(1) * sinY;
return true; creature->AITarget->Pose.Position.z += CLICK(1) * cosY;
}
} }
int TargetReachable(ItemInfo* item, ItemInfo* enemy) int TargetReachable(ItemInfo* item, ItemInfo* enemy)
@ -2187,7 +2149,7 @@ void InitializeItemBoxData()
for (const auto& mesh : room.mesh) for (const auto& mesh : room.mesh)
{ {
long index = ((mesh.pos.Position.z - room.Position.z) / BLOCK(1)) + room.ZSize * ((mesh.pos.Position.x - room.Position.x) / BLOCK(1)); long index = ((mesh.pos.Position.z - room.Position.z) / BLOCK(1)) + room.ZSize * ((mesh.pos.Position.x - room.Position.x) / BLOCK(1));
if (index > room.Sectors.size()) if (index >= room.Sectors.size())
continue; continue;
auto* floor = &room.Sectors[index]; auto* floor = &room.Sectors[index];

View file

@ -83,23 +83,10 @@ constexpr auto CLIP_ALL = (CLIP_LEFT | CLIP_RIGHT | CLIP_TOP | CLIP_BOTTOM);
constexpr auto CLIP_SECONDARY = 0x10; constexpr auto CLIP_SECONDARY = 0x10;
struct AITargetData
{
ItemInfo FoundItem = {};
GAME_OBJECT_ID ObjectID = GAME_OBJECT_ID::ID_NO_OBJECT;
float DistanceMax = 0.0f;
int Ocb = NO_VALUE;
bool CheckDistance = false;
bool CheckSameZone = true;
bool CheckOcb = false;
};
void GetCreatureMood(ItemInfo* item, AI_INFO* AI, bool isViolent); void GetCreatureMood(ItemInfo* item, AI_INFO* AI, bool isViolent);
void CreatureMood(ItemInfo* item, AI_INFO* AI, bool isViolent); void CreatureMood(ItemInfo* item, AI_INFO* AI, bool isViolent);
void FindAITargetObject(ItemInfo& item, GAME_OBJECT_ID objectID, std::optional<int> ocb = std::nullopt, std::optional<bool> checkSameZone = std::nullopt); void FindAITargetObject(CreatureInfo* creature, int objectNumber);
bool FindAITargetObject(ItemInfo& item, AITargetData& data); void FindAITargetObject(CreatureInfo* creature, int objectNumber, int ocb, bool checkSameZone = true);
void GetAITarget(CreatureInfo* creature); void GetAITarget(CreatureInfo* creature);
int CreatureVault(short itemNumber, short angle, int vault, int shift); int CreatureVault(short itemNumber, short angle, int vault, int shift);
bool MoveCreature3DPos(Pose* fromPose, Pose* toPose, int velocity, short angleDif, int angleAdd); bool MoveCreature3DPos(Pose* fromPose, Pose* toPose, int velocity, short angleDif, int angleAdd);

View file

@ -96,17 +96,15 @@ constexpr auto DEATH_INPUT_TIMEOUT = 3 * FPS;
int GameTimer = 0; int GameTimer = 0;
int GlobalCounter = 0; int GlobalCounter = 0;
bool InitializeGame; bool InitializeGame = false;
bool DoTheGame; bool DoTheGame = false;
bool JustLoaded; bool JustLoaded = false;
bool ThreadEnded; bool ThreadEnded = false;
int RequiredStartPos; int RequiredStartPos;
int CurrentLevel; int CurrentLevel;
int NextLevel; int NextLevel;
int SystemNameHash = 0;
bool InItemControlLoop; bool InItemControlLoop;
short ItemNewRoomNo; short ItemNewRoomNo;
short ItemNewRooms[MAX_ROOMS]; short ItemNewRooms[MAX_ROOMS];
@ -123,15 +121,19 @@ void DrawPhase(bool isTitle, float interpolationFactor)
{ {
g_Renderer.RenderTitle(interpolationFactor); g_Renderer.RenderTitle(interpolationFactor);
} }
else else if (g_GameFlow->CurrentFreezeMode == FreezeMode::None)
{ {
g_Renderer.Render(interpolationFactor); g_Renderer.Render(interpolationFactor);
} }
else
{
g_Renderer.RenderFreezeMode(interpolationFactor, g_GameFlow->CurrentFreezeMode == FreezeMode::Full);
}
g_Renderer.Lock(); g_Renderer.Lock();
} }
GameStatus ControlPhase(bool insideMenu) GameStatus GamePhase(bool insideMenu)
{ {
auto time1 = std::chrono::high_resolution_clock::now(); auto time1 = std::chrono::high_resolution_clock::now();
bool isTitle = (CurrentLevel == 0); bool isTitle = (CurrentLevel == 0);
@ -157,11 +159,17 @@ GameStatus ControlPhase(bool insideMenu)
g_GameScript->OnLoop(DELTA_TIME, false); // TODO: Don't use DELTA_TIME constant with high framerate. g_GameScript->OnLoop(DELTA_TIME, false); // TODO: Don't use DELTA_TIME constant with high framerate.
HandleAllGlobalEvents(EventType::Loop, (Activator)LaraItem->Index); HandleAllGlobalEvents(EventType::Loop, (Activator)LaraItem->Index);
// Control lock is processed after handling scripts because builder may want to process input externally while locking player from input. // Queued input actions are read again after OnLoop, so that remaining control loop can immediately register
// emulated keypresses from the script.
ApplyActionQueue();
// Control lock is processed after handling scripts because builder may want to process input externally
// while locking player from input.
if (!isTitle && Lara.Control.IsLocked) if (!isTitle && Lara.Control.IsLocked)
ClearAllActions(); ClearAllActions();
// Item update should happen before camera update, so potential flyby/track camera triggers are processed correctly. // Item update should happen before camera update, so potential flyby/track camera triggers
// are processed correctly.
UpdateAllItems(); UpdateAllItems();
UpdateAllEffects(); UpdateAllEffects();
UpdateLara(LaraItem, isTitle); UpdateLara(LaraItem, isTitle);
@ -173,11 +181,6 @@ GameStatus ControlPhase(bool insideMenu)
// Clear last selected item in inventory (must be after on loop event handling, so they can detect that). // Clear last selected item in inventory (must be after on loop event handling, so they can detect that).
g_Gui.CancelInventorySelection(); g_Gui.CancelInventorySelection();
// Control lock is processed after handling scripts because builder may want to
// process input externally while locking player from input.
if (!isTitle && Lara.Control.IsLocked)
ClearAllActions();
// Update weather. // Update weather.
Weather.Update(); Weather.Update();
@ -224,24 +227,33 @@ GameStatus ControlPhase(bool insideMenu)
PlaySoundSources(); PlaySoundSources();
Sound_UpdateScene(); Sound_UpdateScene();
// Handle inventory, pause, load, save screens. auto gameStatus = GameStatus::Normal;
if (!insideMenu) if (!insideMenu)
{ {
auto result = HandleMenuCalls(isTitle); // Handle inventory, pause, load, save screens.
if (result != GameStatus::Normal) gameStatus = HandleMenuCalls(isTitle);
return result;
// Handle global input events. // Handle global input events.
result = HandleGlobalInputEvents(isTitle); if (gameStatus == GameStatus::Normal)
if (result != GameStatus::Normal) gameStatus = HandleGlobalInputEvents(isTitle);
return result; }
if (gameStatus != GameStatus::Normal)
{
// Call post-loop callbacks last time and end level.
g_GameScript->OnLoop(DELTA_TIME, true);
g_GameScript->OnEnd(gameStatus);
HandleAllGlobalEvents(EventType::End, (Activator)LaraItem->Index);
}
else
{
// Post-loop script and event handling.
g_GameScript->OnLoop(DELTA_TIME, true);
} }
UpdateCamera(); UpdateCamera();
// Post-loop script and event handling.
g_GameScript->OnLoop(DELTA_TIME, true);
// Clear savegame loaded flag. // Clear savegame loaded flag.
JustLoaded = false; JustLoaded = false;
@ -252,9 +264,87 @@ GameStatus ControlPhase(bool insideMenu)
auto time2 = std::chrono::high_resolution_clock::now(); auto time2 = std::chrono::high_resolution_clock::now();
ControlPhaseTime = (std::chrono::duration_cast<std::chrono::nanoseconds>(time2 - time1)).count() / 1000000; ControlPhaseTime = (std::chrono::duration_cast<std::chrono::nanoseconds>(time2 - time1)).count() / 1000000;
return gameStatus;
}
GameStatus FreezePhase()
{
// If needed when first entering freeze mode, do initialization.
if (g_GameFlow->LastFreezeMode == FreezeMode::None)
{
// Capture the screen for drawing it as a background.
if (g_GameFlow->LastFreezeMode == FreezeMode::Full)
g_Renderer.DumpGameScene(SceneRenderMode::NoHud);
StopRumble();
}
// Update last freeze mode here, so that items won't update inside freeze loop.
g_GameFlow->LastFreezeMode = g_GameFlow->CurrentFreezeMode;
g_Renderer.PrepareScene();
g_Renderer.SaveOldState();
ClearLensFlares();
ClearAllDisplaySprites();
SetupInterpolation();
PrepareCamera();
g_GameStringsHandler->ProcessDisplayStrings(DELTA_TIME);
// Track previous player animation to queue hair update if needed.
int lastAnimNumber = LaraItem->Animation.AnimNumber;
// Poll controls and call scripting events.
HandleControls(false);
g_GameScript->OnFreeze();
HandleAllGlobalEvents(EventType::Freeze, (Activator)LaraItem->Index);
// Partially update scene if not using full freeze mode.
if (g_GameFlow->LastFreezeMode != FreezeMode::Full)
{
if (g_GameFlow->LastFreezeMode == FreezeMode::Player)
UpdateLara(LaraItem, false);
UpdateAllItems();
UpdateGlobalLensFlare();
UpdateCamera();
PlaySoundSources();
Sound_UpdateScene();
}
// HACK: Update player hair if animation was switched in spectator mode.
// Needed for photo mode and other similar functionality.
if (g_GameFlow->LastFreezeMode == FreezeMode::Spectator &&
lastAnimNumber != LaraItem->Animation.AnimNumber)
{
lastAnimNumber = LaraItem->Animation.AnimNumber;
for (int i = 0; i < FPS; i++)
HairEffect.Update(*LaraItem);
}
// Update last freeze mode again, as it may have been changed in a script.
g_GameFlow->LastFreezeMode = g_GameFlow->CurrentFreezeMode;
return GameStatus::Normal; return GameStatus::Normal;
} }
GameStatus ControlPhase(bool insideMenu)
{
// For safety, only allow to break game loop in non-title levels.
if (g_GameFlow->CurrentFreezeMode == FreezeMode::None || CurrentLevel == 0)
{
return GamePhase(insideMenu);
}
else
{
return FreezePhase();
}
}
unsigned CALLBACK GameMain(void *) unsigned CALLBACK GameMain(void *)
{ {
TENLog("Starting GameMain()...", LogLevel::Info); TENLog("Starting GameMain()...", LogLevel::Info);
@ -486,14 +576,11 @@ void InitializeScripting(int levelIndex, LevelLoadType type)
// Play default background music. // Play default background music.
if (type != LevelLoadType::Load) if (type != LevelLoadType::Load)
PlaySoundTrack(level.GetAmbientTrack(), SoundTrackType::BGM); PlaySoundTrack(level.GetAmbientTrack(), SoundTrackType::BGM, 0, SOUND_XFADETIME_LEVELJUMP);
} }
void DeInitializeScripting(int levelIndex, GameStatus reason) void DeInitializeScripting(int levelIndex, GameStatus reason)
{ {
g_GameScript->OnEnd(reason);
HandleAllGlobalEvents(EventType::End, (Activator)LaraItem->Index);
g_GameScript->FreeLevelScripts(); g_GameScript->FreeLevelScripts();
g_GameScriptEntities->FreeEntities(); g_GameScriptEntities->FreeEntities();
@ -507,10 +594,8 @@ void InitializeOrLoadGame(bool loadGame)
g_Gui.SetEnterInventory(NO_VALUE); g_Gui.SetEnterInventory(NO_VALUE);
// Restore game? // Restore game?
if (loadGame) if (loadGame && SaveGame::Load(g_GameFlow->SelectedSaveGame))
{ {
SaveGame::Load(g_GameFlow->SelectedSaveGame);
InitializeGame = false; InitializeGame = false;
g_GameFlow->SelectedSaveGame = 0; g_GameFlow->SelectedSaveGame = 0;
@ -548,9 +633,9 @@ GameStatus DoGameLoop(int levelIndex)
int frameCount = LOOP_FRAME_COUNT; int frameCount = LOOP_FRAME_COUNT;
auto& status = g_GameFlow->LastGameStatus; auto& status = g_GameFlow->LastGameStatus;
// Before entering actual game loop, ControlPhase() must be // Before entering actual game loop, GamePhase() must be called once to sort out
// called once to sort out various runtime shenanigangs (e.g. hair). // various runtime shenanigangs (e.g. hair or freeze mode initialization).
status = ControlPhase(false); status = GamePhase(false);
g_Synchronizer.Init(); g_Synchronizer.Init();
bool legacy30FpsDoneDraw = false; bool legacy30FpsDoneDraw = false;
@ -570,6 +655,9 @@ GameStatus DoGameLoop(int levelIndex)
if (status != GameStatus::Normal) if (status != GameStatus::Normal)
break; break;
if (g_GameFlow->LastFreezeMode != g_GameFlow->CurrentFreezeMode)
continue;
if (!g_Configuration.EnableHighFramerate) if (!g_Configuration.EnableHighFramerate)
{ {
if (!legacy30FpsDoneDraw) if (!legacy30FpsDoneDraw)
@ -591,11 +679,14 @@ GameStatus DoGameLoop(int levelIndex)
void EndGameLoop(int levelIndex, GameStatus reason) void EndGameLoop(int levelIndex, GameStatus reason)
{ {
// Save last screenshot for loading screen.
g_Renderer.DumpGameScene();
SaveGame::SaveHub(levelIndex); SaveGame::SaveHub(levelIndex);
DeInitializeScripting(levelIndex, reason); DeInitializeScripting(levelIndex, reason);
StopAllSounds(); StopAllSounds();
StopSoundTracks(); StopSoundTracks(SOUND_XFADETIME_LEVELJUMP, true);
StopRumble(); StopRumble();
} }
@ -632,6 +723,10 @@ GameStatus HandleMenuCalls(bool isTitle)
case InventoryResult::NewGameSelectedLevel: case InventoryResult::NewGameSelectedLevel:
return GameStatus::NewGame; return GameStatus::NewGame;
case InventoryResult::HomeLevel:
return GameStatus::HomeLevel;
break;
case InventoryResult::LoadGame: case InventoryResult::LoadGame:
return GameStatus::LoadGame; return GameStatus::LoadGame;
@ -660,11 +755,8 @@ GameStatus HandleMenuCalls(bool isTitle)
else if (doLoad && g_GameFlow->IsLoadSaveEnabled() && g_Gui.GetInventoryMode() != InventoryMode::Load) else if (doLoad && g_GameFlow->IsLoadSaveEnabled() && g_Gui.GetInventoryMode() != InventoryMode::Load)
{ {
SaveGame::LoadHeaders(); SaveGame::LoadHeaders();
g_Gui.SetInventoryMode(InventoryMode::Load); g_Gui.SetInventoryMode(InventoryMode::Load);
g_Gui.CallInventory(LaraItem, false);
if (g_Gui.CallInventory(LaraItem, false))
gameStatus = GameStatus::LoadGame;
} }
else if (doPause && g_Gui.GetInventoryMode() != InventoryMode::Pause) else if (doPause && g_Gui.GetInventoryMode() != InventoryMode::Pause)
{ {

View file

@ -26,6 +26,14 @@ enum class GameStatus
LevelComplete LevelComplete
}; };
enum class FreezeMode
{
None,
Full,
Spectator,
Player
};
enum class LevelLoadType enum class LevelLoadType
{ {
New, New,
@ -64,7 +72,6 @@ extern bool ThreadEnded;
extern int RequiredStartPos; extern int RequiredStartPos;
extern int CurrentLevel; extern int CurrentLevel;
extern int NextLevel; extern int NextLevel;
extern int SystemNameHash;
extern bool InItemControlLoop; extern bool InItemControlLoop;
extern short ItemNewRoomNo; extern short ItemNewRoomNo;

View file

@ -6,8 +6,6 @@ struct MESH_INFO;
namespace TEN::Control::Volumes namespace TEN::Control::Volumes
{ {
constexpr auto NO_CALL_COUNTER = -1;
using Activator = std::variant< using Activator = std::variant<
std::nullptr_t, std::nullptr_t,
short, short,
@ -42,6 +40,7 @@ namespace TEN::Control::Volumes
Start, Start,
End, End,
UseItem, UseItem,
Freeze,
Count Count
}; };
@ -52,7 +51,8 @@ namespace TEN::Control::Volumes
std::string Function = {}; std::string Function = {};
std::string Data = {}; std::string Data = {};
int CallCounter = NO_CALL_COUNTER; bool Enabled = true;
int CallCounter = NO_VALUE;
}; };
struct EventSet struct EventSet

View file

@ -346,6 +346,6 @@ void VoidEffect(ItemInfo* item)
void DoFlipEffect(int number, ItemInfo* item) void DoFlipEffect(int number, ItemInfo* item)
{ {
if (number != -1 && number < NUM_FLIPEFFECTS && effect_routines[number] != nullptr) if (number != NO_VALUE && number < NUM_FLIPEFFECTS && effect_routines[number] != nullptr)
effect_routines[number](item); effect_routines[number](item);
} }

View file

@ -266,13 +266,14 @@ bool GetTargetOnLOS(GameVector* origin, GameVector* target, bool drawTarget, boo
SoundEffect(SFX_TR4_REVOLVER_FIRE, nullptr); SoundEffect(SFX_TR4_REVOLVER_FIRE, nullptr);
} }
bool hasHit = false; bool hitProcessed = false;
MESH_INFO* mesh = nullptr; MESH_INFO* mesh = nullptr;
auto vector = Vector3i::Zero; auto vector = Vector3i::Zero;
int itemNumber = ObjectOnLOS2(origin, target, &vector, &mesh); int itemNumber = ObjectOnLOS2(origin, target, &vector, &mesh);
bool hasHit = itemNumber != NO_LOS_ITEM;
if (itemNumber != NO_LOS_ITEM) if (hasHit)
{ {
target2.x = vector.x - ((vector.x - origin->x) >> 5); target2.x = vector.x - ((vector.x - origin->x) >> 5);
target2.y = vector.y - ((vector.y - origin->y) >> 5); target2.y = vector.y - ((vector.y - origin->y) >> 5);
@ -286,7 +287,7 @@ bool GetTargetOnLOS(GameVector* origin, GameVector* target, bool drawTarget, boo
{ {
if (itemNumber < 0) if (itemNumber < 0)
{ {
if (StaticObjects[mesh->staticNumber].shatterType != ShatterType::None) if (Statics[mesh->staticNumber].shatterType != ShatterType::None)
{ {
const auto& weapon = Weapons[(int)Lara.Control.Weapon.GunType]; const auto& weapon = Weapons[(int)Lara.Control.Weapon.GunType];
mesh->HitPoints -= weapon.Damage; mesh->HitPoints -= weapon.Damage;
@ -294,10 +295,10 @@ bool GetTargetOnLOS(GameVector* origin, GameVector* target, bool drawTarget, boo
ShatterImpactData.impactLocation = Vector3(mesh->pos.Position.x, mesh->pos.Position.y, mesh->pos.Position.z); ShatterImpactData.impactLocation = Vector3(mesh->pos.Position.x, mesh->pos.Position.y, mesh->pos.Position.z);
ShatterObject(nullptr, mesh, 128, target2.RoomNumber, 0); ShatterObject(nullptr, mesh, 128, target2.RoomNumber, 0);
SoundEffect(GetShatterSound(mesh->staticNumber), (Pose*)mesh); SoundEffect(GetShatterSound(mesh->staticNumber), (Pose*)mesh);
hitProcessed = true;
} }
TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y, 3, 0); TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y);
TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y, 3, 0);
} }
else else
{ {
@ -312,7 +313,8 @@ bool GetTargetOnLOS(GameVector* origin, GameVector* target, bool drawTarget, boo
ShatterImpactData.impactDirection = dir; ShatterImpactData.impactDirection = dir;
ShatterImpactData.impactLocation = ShatterItem.sphere.Center; ShatterImpactData.impactLocation = ShatterItem.sphere.Center;
ShatterObject(&ShatterItem, 0, 128, target2.RoomNumber, 0); ShatterObject(&ShatterItem, 0, 128, target2.RoomNumber, 0);
TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y, 3, 0); TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y, false);
hitProcessed = true;
} }
else else
{ {
@ -342,33 +344,21 @@ bool GetTargetOnLOS(GameVector* origin, GameVector* target, bool drawTarget, boo
} }
} }
} }
HitTarget(LaraItem, item, &target2, Weapons[(int)Lara.Control.Weapon.GunType].Damage, false, bestJointIndex); HitTarget(LaraItem, item, &target2, Weapons[(int)Lara.Control.Weapon.GunType].Damage, false, bestJointIndex);
hitProcessed = true;
} }
else else
{ {
// TR5 // TR5
if (object->hitEffect == HitEffect::Richochet) if (object->hitEffect == HitEffect::Richochet)
TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y, 3, 0); TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y);
} }
} }
else else if (item->ObjectNumber >= ID_SMASH_OBJECT1 && item->ObjectNumber <= ID_SMASH_OBJECT8)
{
if (item->ObjectNumber >= ID_SMASH_OBJECT1 && item->ObjectNumber <= ID_SMASH_OBJECT8)
{ {
SmashObject(itemNumber); SmashObject(itemNumber);
} hitProcessed = true;
else
{
const auto& weapon = Weapons[(int)Lara.Control.Weapon.GunType];
if (object->HitRoutine != nullptr)
{
object->HitRoutine(*item, *LaraItem, target2, weapon.Damage, false, NO_VALUE);
}
else
{
DefaultItemHit(*item, *LaraItem, target2, weapon.Damage, false, NO_VALUE);
}
}
} }
} }
} }
@ -418,9 +408,11 @@ bool GetTargetOnLOS(GameVector* origin, GameVector* target, bool drawTarget, boo
item->Status = ITEM_ACTIVE; item->Status = ITEM_ACTIVE;
item->Flags |= IFLAG_ACTIVATION_MASK | 0x40; item->Flags |= IFLAG_ACTIVATION_MASK | 0x40;
} }
hitProcessed = true;
} }
TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y, 3, 0); TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y);
} }
} }
} }
@ -430,8 +422,6 @@ bool GetTargetOnLOS(GameVector* origin, GameVector* target, bool drawTarget, boo
FireCrossBowFromLaserSight(*LaraItem, origin, &target2); FireCrossBowFromLaserSight(*LaraItem, origin, &target2);
} }
} }
hasHit = true;
} }
else else
{ {
@ -447,7 +437,7 @@ bool GetTargetOnLOS(GameVector* origin, GameVector* target, bool drawTarget, boo
target2.z -= (target2.z - origin->z) >> 5; target2.z -= (target2.z - origin->z) >> 5;
if (isFiring && !result) if (isFiring && !result)
TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y, 8, 0); TriggerRicochetSpark(target2, LaraItem->Pose.Orientation.y);
} }
} }
@ -460,7 +450,7 @@ bool GetTargetOnLOS(GameVector* origin, GameVector* target, bool drawTarget, boo
LaserSightZ = target2.z; LaserSightZ = target2.z;
} }
return hasHit; return hitProcessed;
} }
static bool DoRayBox(const GameVector& origin, const GameVector& target, const GameBoundingBox& bounds, static bool DoRayBox(const GameVector& origin, const GameVector& target, const GameBoundingBox& bounds,
@ -602,7 +592,7 @@ int ObjectOnLOS2(GameVector* origin, GameVector* target, Vector3i* vec, MESH_INF
if (priorityObjectID != GAME_OBJECT_ID::ID_NO_OBJECT && item.ObjectNumber != priorityObjectID) if (priorityObjectID != GAME_OBJECT_ID::ID_NO_OBJECT && item.ObjectNumber != priorityObjectID)
continue; continue;
if (item.ObjectNumber != ID_LARA && Objects[item.ObjectNumber].collision == nullptr) if (item.ObjectNumber != ID_LARA && (Objects[item.ObjectNumber].collision == nullptr || !item.Collidable))
continue; continue;
if (item.ObjectNumber == ID_LARA && priorityObjectID != ID_LARA) if (item.ObjectNumber == ID_LARA && priorityObjectID != ID_LARA)

View file

@ -197,13 +197,6 @@ void InitializeSlot(short itemNumber, bool makeTarget)
creature->LOT.Drop = -BLOCK(1); creature->LOT.Drop = -BLOCK(1);
creature->LOT.Zone = ZoneType::Human; creature->LOT.Zone = ZoneType::Human;
break; break;
case LotType::EnemyJeep:
creature->LOT.Step = BLOCK(4);
creature->LOT.Drop = -BLOCK(4);
creature->LOT.CanJump = true;
creature->LOT.Zone = ZoneType::Human;
break;
} }
ClearLOT(&creature->LOT); ClearLOT(&creature->LOT);

View file

@ -414,6 +414,9 @@ void Trigger(short const value, short const flags)
void TestTriggers(int x, int y, int z, FloorInfo* floor, Activator activator, bool heavy, int heavyFlags) void TestTriggers(int x, int y, int z, FloorInfo* floor, Activator activator, bool heavy, int heavyFlags)
{ {
if (g_GameFlow->CurrentFreezeMode != FreezeMode::None)
return;
bool switchOff = false; bool switchOff = false;
bool flipAvailable = false; bool flipAvailable = false;
int flip = NO_VALUE; int flip = NO_VALUE;
@ -592,14 +595,6 @@ void TestTriggers(int x, int y, int z, FloorInfo* floor, Activator activator, bo
&& (item->Flags & ONESHOT)) && (item->Flags & ONESHOT))
break; break;
if (triggerType != TRIGGER_TYPES::ANTIPAD
&& triggerType != TRIGGER_TYPES::ANTITRIGGER
&& triggerType != TRIGGER_TYPES::HEAVYANTITRIGGER)
{
if (item->ObjectNumber == ID_DART_EMITTER && item->Active)
break;
}
item->Timer = timer; item->Timer = timer;
if (timer != 1) if (timer != 1)
item->Timer = FPS * timer; item->Timer = FPS * timer;
@ -609,10 +604,6 @@ void TestTriggers(int x, int y, int z, FloorInfo* floor, Activator activator, bo
{ {
if (heavyFlags >= 0) if (heavyFlags >= 0)
{ {
//if (switchFlag)
//item->Flags |= (flags & CODE_BITS);
//else
item->Flags ^= (flags & CODE_BITS); item->Flags ^= (flags & CODE_BITS);
if (flags & ONESHOT) if (flags & ONESHOT)
@ -867,6 +858,9 @@ void TestTriggers(int x, int y, int z, short roomNumber, bool heavy, int heavyFl
void ProcessSectorFlags(ItemInfo* item) void ProcessSectorFlags(ItemInfo* item)
{ {
if (g_GameFlow->CurrentFreezeMode != FreezeMode::None)
return;
bool isPlayer = item->IsLara(); bool isPlayer = item->IsLara();
// HACK: because of L-shaped portal configurations, we need to fetch room number from Location struct for player. // HACK: because of L-shaped portal configurations, we need to fetch room number from Location struct for player.

View file

@ -87,11 +87,11 @@ namespace TEN::Control::Volumes
bool HandleEvent(Event& event, Activator& activator) bool HandleEvent(Event& event, Activator& activator)
{ {
if (event.Function.empty() || event.CallCounter == 0 || event.CallCounter < NO_CALL_COUNTER) if (!event.Enabled || event.CallCounter == 0 || event.Function.empty())
return false; return false;
g_GameScript->ExecuteFunction(event.Function, activator, event.Data); g_GameScript->ExecuteFunction(event.Function, activator, event.Data);
if (event.CallCounter != NO_CALL_COUNTER) if (event.CallCounter != NO_VALUE)
event.CallCounter--; event.CallCounter--;
return true; return true;
@ -124,18 +124,16 @@ namespace TEN::Control::Volumes
if (eventSet == nullptr) if (eventSet == nullptr)
return false; return false;
auto& event = eventSet->Events[(int)eventType]; eventSet->Events[(int)eventType].Enabled = enabled;
bool disabled = eventSet->Events[(int)eventType].CallCounter < NO_CALL_COUNTER;
// Flip the call counter to indicate that it is currently disabled.
if ((enabled && disabled) || (!enabled && !disabled))
eventSet->Events[(int)eventType].CallCounter += enabled ? EVENT_STATE_MASK : -EVENT_STATE_MASK;
return true; return true;
} }
void TestVolumes(short roomNumber, const BoundingOrientedBox& box, ActivatorFlags activatorFlag, Activator activator) void TestVolumes(short roomNumber, const BoundingOrientedBox& box, ActivatorFlags activatorFlag, Activator activator)
{ {
if (g_GameFlow->CurrentFreezeMode != FreezeMode::None)
return;
if (roomNumber == NO_VALUE) if (roomNumber == NO_VALUE)
return; return;

View file

@ -138,6 +138,7 @@ namespace TEN::Effects::Bubble
{ {
constexpr auto LIFE_FULL_SCALE = std::max(BUBBLE_LIFE_MAX - 0.25f, 0.0f); constexpr auto LIFE_FULL_SCALE = std::max(BUBBLE_LIFE_MAX - 0.25f, 0.0f);
constexpr auto LIFE_START_FADING = std::min(1.0f, BUBBLE_LIFE_MAX); constexpr auto LIFE_START_FADING = std::min(1.0f, BUBBLE_LIFE_MAX);
constexpr int ROOM_UPDATE_INTERVAL = 10;
if (Bubbles.empty()) if (Bubbles.empty())
return; return;
@ -149,19 +150,23 @@ namespace TEN::Effects::Bubble
bubble.StoreInterpolationData(); bubble.StoreInterpolationData();
// Update room number. TODO: Should use GetPointCollision(), but calling it for each bubble is very inefficient.
auto roomVector = RoomVector(bubble.RoomNumber, int(bubble.Position.y - bubble.Gravity));
int roomNumber = GetRoomVector(roomVector, Vector3i(bubble.Position.x, bubble.Position.y - bubble.Gravity, bubble.Position.z)).RoomNumber;
int prevRoomNumber = bubble.RoomNumber; int prevRoomNumber = bubble.RoomNumber;
bubble.RoomNumber = roomNumber;
int updateOffset = (int)(bubble.Position.x + bubble.Position.y + bubble.Position.z) % ROOM_UPDATE_INTERVAL;
if (GlobalCounter % ROOM_UPDATE_INTERVAL == updateOffset)
{
auto roomVector = RoomVector(bubble.RoomNumber, int(bubble.Position.y - bubble.Gravity));
auto testPosition = Vector3i(bubble.Position.x, bubble.Position.y - bubble.Gravity, bubble.Position.z);
bubble.RoomNumber = GetRoomVector(roomVector, testPosition).RoomNumber;;
}
// Out of water. // Out of water.
if (!TestEnvironment(ENV_FLAG_WATER, roomNumber)) if (bubble.RoomNumber != prevRoomNumber && !TestEnvironment(ENV_FLAG_WATER, bubble.RoomNumber))
{ {
// Hit water surface; spawn ripple. // Hit water surface; spawn ripple.
SpawnRipple( SpawnRipple(
Vector3(bubble.Position.x, g_Level.Rooms[prevRoomNumber].TopHeight, bubble.Position.z), Vector3(bubble.Position.x, g_Level.Rooms[prevRoomNumber].TopHeight, bubble.Position.z),
roomNumber, bubble.RoomNumber,
((bubble.SizeMax.x + bubble.SizeMax.y) / 2) * 0.5f, ((bubble.SizeMax.x + bubble.SizeMax.y) / 2) * 0.5f,
(int)RippleFlags::SlowFade); (int)RippleFlags::SlowFade);
@ -169,8 +174,7 @@ namespace TEN::Effects::Bubble
continue; continue;
} }
// Hit ceiling. NOTE: This is a hacky check. New collision fetching should provide fast info on a need-to-know basis. // Hit ceiling. NOTE: This is a hacky check. New collision fetching should provide fast info on a need-to-know basis.
else if (bubble.RoomNumber == prevRoomNumber && else if (bubble.RoomNumber == prevRoomNumber && bubble.Position.y <= g_Level.Rooms[prevRoomNumber].TopHeight)
bubble.Position.y <= g_Level.Rooms[prevRoomNumber].TopHeight)
{ {
bubble.Life = 0.0f; bubble.Life = 0.0f;
continue; continue;

View file

@ -70,7 +70,7 @@ void ShatterObject(SHATTER_ITEM* item, MESH_INFO* mesh, int num, short roomNumbe
return; return;
isStatic = true; isStatic = true;
meshIndex = StaticObjects[mesh->staticNumber].meshNumber; meshIndex = Statics[mesh->staticNumber].meshNumber;
yRot = mesh->pos.Orientation.y; yRot = mesh->pos.Orientation.y;
pos = Vector3(mesh->pos.Position.x, mesh->pos.Position.y, mesh->pos.Position.z); pos = Vector3(mesh->pos.Position.x, mesh->pos.Position.y, mesh->pos.Position.z);
scale = mesh->scale; scale = mesh->scale;

View file

@ -47,7 +47,7 @@ constexpr int WIBBLE_MAX = UCHAR_MAX - WIBBLE_SPEED + 1;
Particle Particles[MAX_PARTICLES]; Particle Particles[MAX_PARTICLES];
ParticleDynamic ParticleDynamics[MAX_PARTICLE_DYNAMICS]; ParticleDynamic ParticleDynamics[MAX_PARTICLE_DYNAMICS];
FX_INFO EffectList[NUM_EFFECTS]; FX_INFO EffectList[MAX_SPAWNED_ITEM_COUNT];
GameBoundingBox DeadlyBounds; GameBoundingBox DeadlyBounds;
SPLASH_SETUP SplashSetup; SPLASH_SETUP SplashSetup;
@ -450,9 +450,11 @@ void UpdateSparks()
} }
} }
void TriggerRicochetSpark(const GameVector& pos, short angle, int count, int unk) void TriggerRicochetSpark(const GameVector& pos, short angle, bool sound)
{ {
int count = Random::GenerateInt(3, 8);
TriggerRicochetSpark(pos, angle, count); TriggerRicochetSpark(pos, angle, count);
SoundEffect(SFX_TR4_WEAPON_RICOCHET, &Pose(pos.ToVector3i()));
} }
void TriggerCyborgSpark(int x, int y, int z, short xv, short yv, short zv) void TriggerCyborgSpark(int x, int y, int z, short xv, short yv, short zv)
@ -1135,8 +1137,7 @@ void Ricochet(Pose& pose)
{ {
short angle = Geometry::GetOrientToPoint(pose.Position.ToVector3(), LaraItem->Pose.Position.ToVector3()).y; short angle = Geometry::GetOrientToPoint(pose.Position.ToVector3(), LaraItem->Pose.Position.ToVector3()).y;
auto target = GameVector(pose.Position); auto target = GameVector(pose.Position);
TriggerRicochetSpark(target, angle / 16, 3, 0); TriggerRicochetSpark(target, angle / 16);
SoundEffect(SFX_TR4_WEAPON_RICOCHET, &pose);
} }
void ControlWaterfallMist(short itemNumber) void ControlWaterfallMist(short itemNumber)

View file

@ -1,5 +1,6 @@
#pragma once #pragma once
#include "Math/Math.h" #include "Math/Math.h"
#include "Game/Items.h"
#include "Renderer/RendererEnums.h" #include "Renderer/RendererEnums.h"
enum class LaraWeaponType; enum class LaraWeaponType;
@ -13,7 +14,6 @@ constexpr auto SD_UWEXPLOSION = 2;
constexpr auto MAX_NODE = 23; constexpr auto MAX_NODE = 23;
constexpr auto MAX_DYNAMICS = 64; constexpr auto MAX_DYNAMICS = 64;
constexpr auto MAX_SPLASHES = 8; constexpr auto MAX_SPLASHES = 8;
constexpr auto NUM_EFFECTS = 256;
constexpr auto MAX_PARTICLES = 1024; constexpr auto MAX_PARTICLES = 1024;
constexpr auto MAX_PARTICLE_DYNAMICS = 8; constexpr auto MAX_PARTICLE_DYNAMICS = 8;
@ -239,7 +239,7 @@ extern SPLASH_STRUCT Splashes[MAX_SPLASHES];
extern Vector3i NodeVectors[ParticleNodeOffsetIDs::NodeMax]; extern Vector3i NodeVectors[ParticleNodeOffsetIDs::NodeMax];
extern NODEOFFSET_INFO NodeOffsets[ParticleNodeOffsetIDs::NodeMax]; extern NODEOFFSET_INFO NodeOffsets[ParticleNodeOffsetIDs::NodeMax];
extern FX_INFO EffectList[NUM_EFFECTS]; extern FX_INFO EffectList[MAX_SPAWNED_ITEM_COUNT];
template <typename TEffect> template <typename TEffect>
TEffect& GetNewEffect(std::vector<TEffect>& effects, unsigned int countMax) TEffect& GetNewEffect(std::vector<TEffect>& effects, unsigned int countMax)
@ -284,7 +284,7 @@ void SetSpriteSequence(Particle& particle, GAME_OBJECT_ID objectID);
void DetatchSpark(int num, SpriteEnumFlag type); void DetatchSpark(int num, SpriteEnumFlag type);
void UpdateSparks(); void UpdateSparks();
void TriggerRicochetSpark(const GameVector& pos, short angle, int count, int unk); void TriggerRicochetSpark(const GameVector& pos, short angle, bool sound = true);
void TriggerCyborgSpark(int x, int y, int z, short xv, short yv, short zv); void TriggerCyborgSpark(int x, int y, int z, short xv, short yv, short zv);
void TriggerExplosionSparks(int x, int y, int z, int extraTrig, int dynamic, int uw, int roomNumber, const Vector3& mainColor = Vector3::Zero, const Vector3& secondColor = Vector3::Zero); void TriggerExplosionSparks(int x, int y, int z, int extraTrig, int dynamic, int uw, int roomNumber, const Vector3& mainColor = Vector3::Zero, const Vector3& secondColor = Vector3::Zero);
void TriggerExplosionSmokeEnd(int x, int y, int z, int uw); void TriggerExplosionSmokeEnd(int x, int y, int z, int uw);

View file

@ -176,6 +176,11 @@ namespace TEN::Effects::Hair
// Calculate absolute orientation. // Calculate absolute orientation.
auto absDir = target - origin; auto absDir = target - origin;
absDir.Normalize(); absDir.Normalize();
// FAILSAFE: Handle case with zero normal (can happen if 2 hair segments have same offset).
if (absDir == Vector3::Zero)
return Quaternion::Identity;
auto absOrient = Geometry::ConvertDirectionToQuat(absDir); auto absOrient = Geometry::ConvertDirectionToQuat(absDir);
// Calculate relative twist rotation. // Calculate relative twist rotation.

View file

@ -1474,93 +1474,6 @@ void TriggerExplosionBubble(int x, int y, int z, short roomNumber)
} }
} }
/*void TriggerExplosionSmokeEnd(int x, int y, int z, int unk)
{
auto* spark = GetFreeParticle();
spark->on = 1;
if (unk)
{
spark->sR = 0;
spark->sG = 0;
spark->sB = 0;
spark->dR = 192;
spark->dG = 192;
spark->dB = 208;
}
else
{
spark->dR = 64;
spark->sR = 144;
spark->sG = 144;
spark->sB = 144;
spark->dG = 64;
spark->dB = 64;
}
spark->colFadeSpeed = 8;
spark->fadeToBlack = 64;
spark->life = spark->sLife = (GetRandomControl() & 0x1F) + 96;
if (unk)
spark->blendMode = BlendMode::Additive;
else
spark->blendMode = 3;
spark->x = (GetRandomControl() & 0x1F) + x - 16;
spark->y = (GetRandomControl() & 0x1F) + y - 16;
spark->z = (GetRandomControl() & 0x1F) + z - 16;
spark->xVel = ((GetRandomControl() & 0xFFF) - 2048) >> 2;
spark->yVel = (GetRandomControl() & 0xFF) - 128;
spark->zVel = ((GetRandomControl() & 0xFFF) - 2048) >> 2;
if (unk)
{
spark->friction = 20;
spark->yVel >>= 4;
spark->y += 32;
}
else
spark->friction = 6;
spark->flags = 538;
spark->rotAng = GetRandomControl() & 0xFFF;
if (GetRandomControl() & 1)
spark->rotAdd = -((GetRandomControl() & 0xF) + 16);
else
spark->rotAdd = (GetRandomControl() & 0xF) + 16;
spark->scalar = 3;
if (unk)
{
spark->maxYvel = 0;
spark->gravity = 0;
}
else
{
spark->gravity = -3 - (GetRandomControl() & 3);
spark->maxYvel = -4 - (GetRandomControl() & 3);
}
int size = (GetRandomControl() & 0x1F) + 128;
spark->dSize = size;
spark->sSize = size >> 2;
spark->size = size >> 2;
}
*/
/*void DrawLensFlares(ItemInfo* item)
{
GameVector pos;
pos.x = item->pos.Position.x;
pos.y = item->pos.Position.y;
pos.z = item->pos.Position.z;
pos.roomNumber = item->roomNumber;
SetUpLensFlare(0, 0, 0, &pos);
}*/
void TriggerFenceSparks(int x, int y, int z, int kill, int crane) void TriggerFenceSparks(int x, int y, int z, int kill, int crane)
{ {
auto* spark = GetFreeParticle(); auto* spark = GetFreeParticle();

View file

@ -3168,9 +3168,7 @@ namespace TEN::Gui
bool GuiController::CallPause() bool GuiController::CallPause()
{ {
ClearAllDisplaySprites(); g_Renderer.DumpGameScene(SceneRenderMode::NoHud);
g_Renderer.PrepareScene();
g_Renderer.DumpGameScene();
PauseAllSounds(SoundPauseMode::Pause); PauseAllSounds(SoundPauseMode::Pause);
SoundEffect(SFX_TR4_MENU_SELECT, nullptr, SoundEnvironment::Always); SoundEffect(SFX_TR4_MENU_SELECT, nullptr, SoundEnvironment::Always);
@ -3251,9 +3249,7 @@ namespace TEN::Gui
player.Inventory.OldBusy = player.Inventory.IsBusy; player.Inventory.OldBusy = player.Inventory.IsBusy;
ClearAllDisplaySprites(); g_Renderer.DumpGameScene(SceneRenderMode::NoHud);
g_Renderer.PrepareScene();
g_Renderer.DumpGameScene();
PauseAllSounds(SoundPauseMode::Inventory); PauseAllSounds(SoundPauseMode::Inventory);
SoundEffect(SFX_TR4_MENU_SELECT, nullptr, SoundEnvironment::Always); SoundEffect(SFX_TR4_MENU_SELECT, nullptr, SoundEnvironment::Always);
@ -3506,7 +3502,7 @@ namespace TEN::Gui
LoadResult GuiController::DoLoad() LoadResult GuiController::DoLoad()
{ {
constexpr auto DEATH_NO_INPUT_LOAD_TIMEOUT = 1 * FPS; constexpr auto DEATH_NO_INPUT_LOAD_TIMEOUT = FPS / 2;
bool canLoop = g_Configuration.MenuOptionLoopingMode == MenuOptionLoopingMode::SaveLoadOnly || bool canLoop = g_Configuration.MenuOptionLoopingMode == MenuOptionLoopingMode::SaveLoadOnly ||
g_Configuration.MenuOptionLoopingMode == MenuOptionLoopingMode::AllMenus; g_Configuration.MenuOptionLoopingMode == MenuOptionLoopingMode::AllMenus;
@ -3524,7 +3520,7 @@ namespace TEN::Gui
else else
{ {
SoundEffect(SFX_TR4_MENU_CHOOSE, nullptr, SoundEnvironment::Always); SoundEffect(SFX_TR4_MENU_CHOOSE, nullptr, SoundEnvironment::Always);
g_GameFlow->SelectedSaveGame = SelectedSaveSlot; NextLevel = -(SelectedSaveSlot + 1);
return LoadResult::Load; return LoadResult::Load;
} }
} }

View file

@ -276,7 +276,7 @@ void KillItem(short const itemNumber)
// AI target generation uses a hack with making a dummy item without ObjectNumber. // AI target generation uses a hack with making a dummy item without ObjectNumber.
// Therefore, a check should be done here to prevent access violation. // Therefore, a check should be done here to prevent access violation.
if (item->ObjectNumber != GAME_OBJECT_ID::ID_NO_OBJECT && item->IsBridge()) if (item->ObjectNumber != GAME_OBJECT_ID::ID_NO_OBJECT && item->IsBridge())
UpdateBridgeItem(*item, true); UpdateBridgeItem(*item, BridgeUpdateType::Remove);
GameScriptHandleKilled(itemNumber, true); GameScriptHandleKilled(itemNumber, true);
@ -479,13 +479,13 @@ void InitializeFXArray()
NextFxActive = NO_VALUE; NextFxActive = NO_VALUE;
NextFxFree = 0; NextFxFree = 0;
for (int i = 0; i < NUM_EFFECTS; i++) for (int i = 0; i < MAX_SPAWNED_ITEM_COUNT; i++)
{ {
auto* fx = &EffectList[i]; auto* fx = &EffectList[i];
fx->nextFx = i + 1; fx->nextFx = i + 1;
} }
EffectList[NUM_EFFECTS - 1].nextFx = NO_VALUE; EffectList[MAX_SPAWNED_ITEM_COUNT - 1].nextFx = NO_VALUE;
} }
void RemoveDrawnItem(short itemNumber) void RemoveDrawnItem(short itemNumber)
@ -763,28 +763,30 @@ void UpdateAllItems()
while (itemNumber != NO_VALUE) while (itemNumber != NO_VALUE)
{ {
auto* item = &g_Level.Items[itemNumber]; auto* item = &g_Level.Items[itemNumber];
short nextItem = item->NextActive; itemNumber = item->NextActive;
if (!Objects.CheckID(item->ObjectNumber)) if (!Objects.CheckID(item->ObjectNumber))
continue; continue;
if (g_GameFlow->LastFreezeMode != FreezeMode::None && !Objects[item->ObjectNumber].AlwaysActive)
continue;
if (item->AfterDeath <= ITEM_DEATH_TIMEOUT) if (item->AfterDeath <= ITEM_DEATH_TIMEOUT)
{ {
if (Objects[item->ObjectNumber].control) if (Objects[item->ObjectNumber].control)
Objects[item->ObjectNumber].control(itemNumber); Objects[item->ObjectNumber].control(item->Index);
TestVolumes(itemNumber); TestVolumes(item->Index);
ProcessEffects(item); ProcessEffects(item);
if (item->AfterDeath > 0 && item->AfterDeath < ITEM_DEATH_TIMEOUT && !(Wibble & 3)) if (item->AfterDeath > 0 && item->AfterDeath < ITEM_DEATH_TIMEOUT && !(Wibble & 3))
item->AfterDeath++; item->AfterDeath++;
if (item->AfterDeath == ITEM_DEATH_TIMEOUT) if (item->AfterDeath == ITEM_DEATH_TIMEOUT)
KillItem(itemNumber); KillItem(item->Index);
} }
else else
KillItem(itemNumber); KillItem(item->Index);
itemNumber = nextItem;
} }
InItemControlLoop = false; InItemControlLoop = false;
@ -893,7 +895,7 @@ void DefaultItemHit(ItemInfo& target, ItemInfo& source, std::optional<GameVector
break; break;
case HitEffect::Richochet: case HitEffect::Richochet:
TriggerRicochetSpark(pos.value(), source.Pose.Orientation.y, 3, 0); TriggerRicochetSpark(pos.value(), source.Pose.Orientation.y);
break; break;
case HitEffect::Smoke: case HitEffect::Smoke:

View file

@ -8,7 +8,7 @@
using namespace TEN::Utils; using namespace TEN::Utils;
constexpr auto ITEM_COUNT_MAX = 1024; constexpr auto MAX_SPAWNED_ITEM_COUNT = 256;
constexpr auto ITEM_FLAG_COUNT = 8; constexpr auto ITEM_FLAG_COUNT = 8;
constexpr auto NOT_TARGETABLE = SHRT_MIN / 2; constexpr auto NOT_TARGETABLE = SHRT_MIN / 2;

View file

@ -50,7 +50,7 @@ void ControlMissile(short fxNumber)
auto& fx = EffectList[fxNumber]; auto& fx = EffectList[fxNumber];
auto isUnderwater = TestEnvironment(ENV_FLAG_WATER, fx.roomNumber); auto isUnderwater = TestEnvironment(ENV_FLAG_WATER, fx.roomNumber);
auto soundFXType = isUnderwater ? SoundEnvironment::ShallowWater : SoundEnvironment::Land; auto soundFXType = isUnderwater ? SoundEnvironment::Underwater : SoundEnvironment::Land;
if (fx.objectNumber == ID_SCUBA_HARPOON && isUnderwater && if (fx.objectNumber == ID_SCUBA_HARPOON && isUnderwater &&
fx.pos.Orientation.x > ANGLE(-67.5f)) fx.pos.Orientation.x > ANGLE(-67.5f))

View file

@ -203,23 +203,6 @@ void RemoveObjectFromInventory(GAME_OBJECT_ID objectID, std::optional<int> count
} }
} }
void CollectCarriedItems(ItemInfo* item)
{
short pickupNumber = item->CarriedItem;
while (pickupNumber != NO_VALUE)
{
auto& pickupItem = g_Level.Items[pickupNumber];
PickedUpObject(pickupItem);
g_Hud.PickupSummary.AddDisplayPickup(pickupItem);
KillItem(pickupNumber);
pickupNumber = pickupItem.CarriedItem;
}
item->CarriedItem = NO_VALUE;
}
static void HideOrDisablePickup(ItemInfo& pickupItem) static void HideOrDisablePickup(ItemInfo& pickupItem)
{ {
if (pickupItem.TriggerFlags & 0xC0) if (pickupItem.TriggerFlags & 0xC0)
@ -234,6 +217,23 @@ static void HideOrDisablePickup(ItemInfo& pickupItem)
} }
} }
void CollectCarriedItems(ItemInfo* item)
{
short pickupNumber = item->CarriedItem;
while (pickupNumber != NO_VALUE)
{
auto& pickupItem = g_Level.Items[pickupNumber];
PickedUpObject(pickupItem);
g_Hud.PickupSummary.AddDisplayPickup(pickupItem);
HideOrDisablePickup(pickupItem);
pickupNumber = pickupItem.CarriedItem;
}
item->CarriedItem = NO_VALUE;
}
void CollectMultiplePickups(int itemNumber) void CollectMultiplePickups(int itemNumber)
{ {
auto& firstItem = g_Level.Items[itemNumber]; auto& firstItem = g_Level.Items[itemNumber];
@ -903,7 +903,7 @@ void DropPickups(ItemInfo* item)
for (auto* staticPtr : collObjects.Statics) for (auto* staticPtr : collObjects.Statics)
{ {
auto& object = StaticObjects[staticPtr->staticNumber]; auto& object = Statics[staticPtr->staticNumber];
auto box = object.collisionBox.ToBoundingOrientedBox(staticPtr->pos); auto box = object.collisionBox.ToBoundingOrientedBox(staticPtr->pos);
if (box.Intersects(sphere)) if (box.Intersects(sphere))
@ -1270,7 +1270,7 @@ void SearchObjectControl(short itemNumber)
{ {
PickedUpObject(*item2); PickedUpObject(*item2);
g_Hud.PickupSummary.AddDisplayPickup(*item2); g_Hud.PickupSummary.AddDisplayPickup(*item2);
KillItem(item->ItemFlags[1]); HideOrDisablePickup(*item2);
} }
else else
{ {

View file

@ -7,14 +7,16 @@
#include "Game/control/lot.h" #include "Game/control/lot.h"
#include "Game/control/volume.h" #include "Game/control/volume.h"
#include "Game/items.h" #include "Game/items.h"
#include "Renderer/Renderer.h"
#include "Math/Math.h" #include "Math/Math.h"
#include "Objects/game_object_ids.h" #include "Objects/game_object_ids.h"
#include "Objects/Generic/Doors/generic_doors.h"
#include "Renderer/Renderer.h"
#include "Specific/trutils.h" #include "Specific/trutils.h"
using namespace TEN::Math; using namespace TEN::Math;
using namespace TEN::Collision::Floordata; using namespace TEN::Collision::Floordata;
using namespace TEN::Collision::Point; using namespace TEN::Collision::Point;
using namespace TEN::Entities::Doors;
using namespace TEN::Renderer; using namespace TEN::Renderer;
using namespace TEN::Utils; using namespace TEN::Utils;
@ -69,10 +71,78 @@ static void RemoveRoomFlipItems(const ROOM_INFO& room)
// Clear bridge. // Clear bridge.
if (item.IsBridge()) if (item.IsBridge())
UpdateBridgeItem(item, true); UpdateBridgeItem(item, BridgeUpdateType::Remove);
} }
} }
static void FlipRooms(int roomNumber, ROOM_INFO& activeRoom, ROOM_INFO& flippedRoom)
{
RemoveRoomFlipItems(activeRoom);
// Swap rooms.
std::swap(activeRoom, flippedRoom);
activeRoom.flippedRoom = flippedRoom.flippedRoom;
flippedRoom.flippedRoom = NO_VALUE;
activeRoom.itemNumber = flippedRoom.itemNumber;
activeRoom.fxNumber = flippedRoom.fxNumber;
AddRoomFlipItems(activeRoom);
// Update active room sectors.
for (auto& sector : activeRoom.Sectors)
sector.RoomNumber = roomNumber;
// Update flipped room sectors.
for (auto& sector : flippedRoom.Sectors)
sector.RoomNumber = activeRoom.flippedRoom;
// Update renderer data.
g_Renderer.FlipRooms(roomNumber, activeRoom.flippedRoom);
}
void ResetRoomData()
{
// Remove all door collisions.
for (const auto& item : g_Level.Items)
{
if (item.ObjectNumber == NO_VALUE || !item.Data.is<DOOR_DATA>())
continue;
auto& doorItem = g_Level.Items[item.Index];
auto& door = *(DOOR_DATA*)doorItem.Data;
if (door.opened)
continue;
OpenThatDoor(&door.d1, &door);
OpenThatDoor(&door.d2, &door);
OpenThatDoor(&door.d1flip, &door);
OpenThatDoor(&door.d2flip, &door);
door.opened = true;
}
// Unflip all rooms and remove all bridges and stopper flags.
for (int roomNumber = 0; roomNumber < g_Level.Rooms.size(); roomNumber++)
{
auto& room = g_Level.Rooms[roomNumber];
if (room.flippedRoom != NO_VALUE && room.flipNumber != NO_VALUE && FlipStats[room.flipNumber])
{
auto& flippedRoom = g_Level.Rooms[room.flippedRoom];
FlipRooms(roomNumber, room, flippedRoom);
}
for (auto& sector : room.Sectors)
{
sector.Stopper = false;
sector.BridgeItemNumbers.clear();
}
}
// Make sure no pathfinding boxes are blocked (either by doors or by other door-like objects).
for (int pathfindingBoxID = 0; pathfindingBoxID < g_Level.PathfindingBoxes.size(); pathfindingBoxID++)
g_Level.PathfindingBoxes[pathfindingBoxID].flags &= ~BLOCKED;
}
void DoFlipMap(int group) void DoFlipMap(int group)
{ {
if (group >= MAX_FLIPMAP) if (group >= MAX_FLIPMAP)
@ -87,30 +157,10 @@ void DoFlipMap(int group)
auto& room = g_Level.Rooms[roomNumber]; auto& room = g_Level.Rooms[roomNumber];
// Handle flipmap. // Handle flipmap.
if (room.flippedRoom >= 0 && room.flipNumber == group) if (room.flippedRoom != NO_VALUE && room.flipNumber == group)
{ {
auto& flippedRoom = g_Level.Rooms[room.flippedRoom]; auto& flippedRoom = g_Level.Rooms[room.flippedRoom];
FlipRooms(roomNumber, room, flippedRoom);
RemoveRoomFlipItems(room);
// Swap rooms.
std::swap(room, flippedRoom);
room.flippedRoom = flippedRoom.flippedRoom;
flippedRoom.flippedRoom = NO_VALUE;
room.itemNumber = flippedRoom.itemNumber;
room.fxNumber = flippedRoom.fxNumber;
AddRoomFlipItems(room);
g_Renderer.FlipRooms(roomNumber, room.flippedRoom);
// Update active room sectors.
for (auto& sector : room.Sectors)
sector.RoomNumber = roomNumber;
// Update flipped room sectors.
for (auto& sector : flippedRoom.Sectors)
sector.RoomNumber = room.flippedRoom;
} }
} }
@ -205,11 +255,11 @@ GameBoundingBox& GetBoundsAccurate(const MESH_INFO& mesh, bool getVisibilityBox)
if (getVisibilityBox) if (getVisibilityBox)
{ {
bounds = StaticObjects[mesh.staticNumber].visibilityBox * mesh.scale; bounds = Statics[mesh.staticNumber].visibilityBox * mesh.scale;
} }
else else
{ {
bounds = StaticObjects[mesh.staticNumber].collisionBox * mesh.scale; bounds = Statics[mesh.staticNumber].collisionBox * mesh.scale;
} }
return bounds; return bounds;
@ -219,6 +269,9 @@ bool IsPointInRoom(const Vector3i& pos, int roomNumber)
{ {
const auto& room = g_Level.Rooms[roomNumber]; const auto& room = g_Level.Rooms[roomNumber];
if (!room.Active())
return false;
if (pos.z >= (room.Position.z + BLOCK(1)) && pos.z <= (room.Position.z + BLOCK(room.ZSize - 1)) && if (pos.z >= (room.Position.z + BLOCK(1)) && pos.z <= (room.Position.z + BLOCK(room.ZSize - 1)) &&
pos.y <= room.BottomHeight && pos.y > room.TopHeight && pos.y <= room.BottomHeight && pos.y > room.TopHeight &&
pos.x >= (room.Position.x + BLOCK(1)) && pos.x <= (room.Position.x + BLOCK(room.XSize - 1))) pos.x >= (room.Position.x + BLOCK(1)) && pos.x <= (room.Position.x + BLOCK(room.XSize - 1)))
@ -237,22 +290,21 @@ int FindRoomNumber(const Vector3i& pos, int startRoomNumber, bool onlyNeighbors)
for (int neighborRoomNumber : room.NeighborRoomNumbers) for (int neighborRoomNumber : room.NeighborRoomNumbers)
{ {
const auto& neighborRoom = g_Level.Rooms[neighborRoomNumber]; const auto& neighborRoom = g_Level.Rooms[neighborRoomNumber];
if (neighborRoomNumber != startRoomNumber && neighborRoom.Active() && if (neighborRoomNumber != startRoomNumber && IsPointInRoom(pos, neighborRoomNumber))
IsPointInRoom(pos, neighborRoomNumber))
{ {
return neighborRoomNumber; return neighborRoomNumber;
} }
} }
} }
if (onlyNeighbors) if (!onlyNeighbors)
return startRoomNumber; {
for (int roomNumber = 0; roomNumber < g_Level.Rooms.size(); roomNumber++) for (int roomNumber = 0; roomNumber < g_Level.Rooms.size(); roomNumber++)
{ {
if (IsPointInRoom(pos, roomNumber) && g_Level.Rooms[roomNumber].Active()) if (IsPointInRoom(pos, roomNumber))
return roomNumber; return roomNumber;
} }
}
return (startRoomNumber != NO_VALUE) ? startRoomNumber : 0; return (startRoomNumber != NO_VALUE) ? startRoomNumber : 0;
} }

View file

@ -23,10 +23,10 @@ enum RoomEnvFlags
{ {
ENV_FLAG_WATER = (1 << 0), ENV_FLAG_WATER = (1 << 0),
ENV_FLAG_SWAMP = (1 << 2), ENV_FLAG_SWAMP = (1 << 2),
ENV_FLAG_OUTSIDE = (1 << 3), ENV_FLAG_SKYBOX = (1 << 3),
ENV_FLAG_DYNAMIC_LIT = (1 << 4), ENV_FLAG_DYNAMIC_LIT = (1 << 4),
ENV_FLAG_WIND = (1 << 5), ENV_FLAG_WIND = (1 << 5),
ENV_FLAG_NOT_NEAR_OUTSIDE = (1 << 6), ENV_FLAG_NOT_NEAR_SKYBOX = (1 << 6),
ENV_FLAG_NO_LENSFLARE = (1 << 7), ENV_FLAG_NO_LENSFLARE = (1 << 7),
ENV_FLAG_MIST = (1 << 8), ENV_FLAG_MIST = (1 << 8),
ENV_FLAG_CAUSTICS = (1 << 9), ENV_FLAG_CAUSTICS = (1 << 9),
@ -125,6 +125,7 @@ struct ROOM_INFO
}; };
void DoFlipMap(int group); void DoFlipMap(int group);
void ResetRoomData();
bool IsObjectInRoom(int roomNumber, GAME_OBJECT_ID objectID); bool IsObjectInRoom(int roomNumber, GAME_OBJECT_ID objectID);
bool IsPointInRoom(const Vector3i& pos, int roomNumber); bool IsPointInRoom(const Vector3i& pos, int roomNumber);
int FindRoomNumber(const Vector3i& pos, int startRoomNumber = NO_VALUE, bool onlyNeighbors = false); int FindRoomNumber(const Vector3i& pos, int startRoomNumber = NO_VALUE, bool onlyNeighbors = false);

View file

@ -247,6 +247,7 @@ const std::vector<byte> SaveGame::Build()
Save::SaveGameHeaderBuilder sghb{ fbb }; Save::SaveGameHeaderBuilder sghb{ fbb };
sghb.add_level_name(levelNameOffset); sghb.add_level_name(levelNameOffset);
sghb.add_level_hash(LastLevelHash);
auto gameTime = GetGameTime(GameTimer); auto gameTime = GetGameTime(GameTimer);
sghb.add_days(gameTime.Days); sghb.add_days(gameTime.Days);
@ -1074,17 +1075,23 @@ const std::vector<byte> SaveGame::Build()
std::vector<flatbuffers::Offset<Save::EventSet>> globalEventSets{}; std::vector<flatbuffers::Offset<Save::EventSet>> globalEventSets{};
for (int j = 0; j < g_Level.GlobalEventSets.size(); j++) for (int j = 0; j < g_Level.GlobalEventSets.size(); j++)
{ {
std::vector<bool> statuses = {};
std::vector<int> callCounters = {}; std::vector<int> callCounters = {};
for (int k = 0; k < g_Level.GlobalEventSets[j].Events.size(); k++) for (int k = 0; k < g_Level.GlobalEventSets[j].Events.size(); k++)
{
statuses.push_back(g_Level.GlobalEventSets[j].Events[k].Enabled);
callCounters.push_back(g_Level.GlobalEventSets[j].Events[k].CallCounter); callCounters.push_back(g_Level.GlobalEventSets[j].Events[k].CallCounter);
}
auto vec = fbb.CreateVector(callCounters); auto vecStatuses = fbb.CreateVector(statuses);
auto vecCounters = fbb.CreateVector(callCounters);
Save::EventSetBuilder eventSet{ fbb }; Save::EventSetBuilder eventSet{ fbb };
eventSet.add_index(j); eventSet.add_index(j);
eventSet.add_call_counters(vec); eventSet.add_statuses(vecStatuses);
eventSet.add_call_counters(vecCounters);
globalEventSets.push_back(eventSet.Finish()); globalEventSets.push_back(eventSet.Finish());
} }
@ -1094,17 +1101,23 @@ const std::vector<byte> SaveGame::Build()
std::vector<flatbuffers::Offset<Save::EventSet>> volumeEventSets{}; std::vector<flatbuffers::Offset<Save::EventSet>> volumeEventSets{};
for (int j = 0; j < g_Level.VolumeEventSets.size(); j++) for (int j = 0; j < g_Level.VolumeEventSets.size(); j++)
{ {
std::vector<bool> statuses = {};
std::vector<int> callCounters = {}; std::vector<int> callCounters = {};
for (int k = 0; k < g_Level.VolumeEventSets[j].Events.size(); k++) for (int k = 0; k < g_Level.VolumeEventSets[j].Events.size(); k++)
{
statuses.push_back(g_Level.VolumeEventSets[j].Events[k].Enabled);
callCounters.push_back(g_Level.VolumeEventSets[j].Events[k].CallCounter); callCounters.push_back(g_Level.VolumeEventSets[j].Events[k].CallCounter);
}
auto vec = fbb.CreateVector(callCounters); auto vecStatuses = fbb.CreateVector(statuses);
auto vecCounters = fbb.CreateVector(callCounters);
Save::EventSetBuilder eventSet{ fbb }; Save::EventSetBuilder eventSet{ fbb };
eventSet.add_index(j); eventSet.add_index(j);
eventSet.add_call_counters(vec); eventSet.add_statuses(vecStatuses);
eventSet.add_call_counters(vecCounters);
volumeEventSets.push_back(eventSet.Finish()); volumeEventSets.push_back(eventSet.Finish());
} }
@ -1395,6 +1408,12 @@ const std::vector<byte> SaveGame::Build()
std::vector<std::string> callbackVecPreLoop; std::vector<std::string> callbackVecPreLoop;
std::vector<std::string> callbackVecPostLoop; std::vector<std::string> callbackVecPostLoop;
std::vector<std::string> callbackVecPreUseItem;
std::vector<std::string> callbackVecPostUseItem;
std::vector<std::string> callbackVecPreFreeze;
std::vector<std::string> callbackVecPostFreeze;
g_GameScript->GetCallbackStrings( g_GameScript->GetCallbackStrings(
callbackVecPreStart, callbackVecPreStart,
callbackVecPostStart, callbackVecPostStart,
@ -1405,7 +1424,11 @@ const std::vector<byte> SaveGame::Build()
callbackVecPreLoad, callbackVecPreLoad,
callbackVecPostLoad, callbackVecPostLoad,
callbackVecPreLoop, callbackVecPreLoop,
callbackVecPostLoop); callbackVecPostLoop,
callbackVecPreUseItem,
callbackVecPostUseItem,
callbackVecPreFreeze,
callbackVecPostFreeze);
auto stringsCallbackPreStart = fbb.CreateVectorOfStrings(callbackVecPreStart); auto stringsCallbackPreStart = fbb.CreateVectorOfStrings(callbackVecPreStart);
auto stringsCallbackPostStart = fbb.CreateVectorOfStrings(callbackVecPostStart); auto stringsCallbackPostStart = fbb.CreateVectorOfStrings(callbackVecPostStart);
@ -1417,6 +1440,10 @@ const std::vector<byte> SaveGame::Build()
auto stringsCallbackPostLoad = fbb.CreateVectorOfStrings(callbackVecPostLoad); auto stringsCallbackPostLoad = fbb.CreateVectorOfStrings(callbackVecPostLoad);
auto stringsCallbackPreLoop = fbb.CreateVectorOfStrings(callbackVecPreLoop); auto stringsCallbackPreLoop = fbb.CreateVectorOfStrings(callbackVecPreLoop);
auto stringsCallbackPostLoop = fbb.CreateVectorOfStrings(callbackVecPostLoop); auto stringsCallbackPostLoop = fbb.CreateVectorOfStrings(callbackVecPostLoop);
auto stringsCallbackPreUseItem = fbb.CreateVectorOfStrings(callbackVecPreUseItem);
auto stringsCallbackPostUseItem = fbb.CreateVectorOfStrings(callbackVecPostUseItem);
auto stringsCallbackPreFreeze = fbb.CreateVectorOfStrings(callbackVecPreFreeze);
auto stringsCallbackPostFreeze = fbb.CreateVectorOfStrings(callbackVecPostFreeze);
Save::SaveGameBuilder sgb{ fbb }; Save::SaveGameBuilder sgb{ fbb };
@ -1483,6 +1510,12 @@ const std::vector<byte> SaveGame::Build()
sgb.add_callbacks_pre_loop(stringsCallbackPreLoop); sgb.add_callbacks_pre_loop(stringsCallbackPreLoop);
sgb.add_callbacks_post_loop(stringsCallbackPostLoop); sgb.add_callbacks_post_loop(stringsCallbackPostLoop);
sgb.add_callbacks_pre_useitem(stringsCallbackPreUseItem);
sgb.add_callbacks_post_useitem(stringsCallbackPostUseItem);
sgb.add_callbacks_pre_freeze(stringsCallbackPreFreeze);
sgb.add_callbacks_post_freeze(stringsCallbackPostFreeze);
auto sg = sgb.Finish(); auto sg = sgb.Finish();
fbb.Finish(sg); fbb.Finish(sg);
@ -1506,15 +1539,18 @@ void SaveGame::SaveHub(int index)
void SaveGame::LoadHub(int index) void SaveGame::LoadHub(int index)
{ {
// Don't attempt to load hub data if it doesn't exist, or level is a title level. // Don't attempt to load hub data if level is a title level.
if (index == 0 || !IsOnHub(index)) if (index == 0)
return; return;
if (IsOnHub(index))
{
// Load hub data. // Load hub data.
TENLog("Loading hub data for level #" + std::to_string(index), LogLevel::Info); TENLog("Loading hub data for level #" + std::to_string(index), LogLevel::Info);
Parse(Hub[index], true); Parse(Hub[index], true);
}
// Restore vehicle. // Restore vehicle (also for cases when no hub data yet exists).
InitializePlayerVehicle(*LaraItem); InitializePlayerVehicle(*LaraItem);
} }
@ -1579,40 +1615,48 @@ bool SaveGame::Save(int slot)
bool SaveGame::Load(int slot) bool SaveGame::Load(int slot)
{ {
if (!IsSaveGameSlotValid(slot)) if (!IsSaveGameSlotValid(slot))
{
TENLog("Savegame slot " + std::to_string(slot) + " is invalid, load is impossible.", LogLevel::Error);
return false; return false;
}
if (!DoesSaveGameExist(slot)) if (!DoesSaveGameExist(slot))
{
TENLog("Savegame in slot " + std::to_string(slot) + " does not exist.", LogLevel::Error);
return false; return false;
}
auto fileName = GetSavegameFilename(slot); auto fileName = GetSavegameFilename(slot);
TENLog("Loading from savegame: " + fileName, LogLevel::Info); TENLog("Loading from savegame: " + fileName, LogLevel::Info);
std::ifstream file; auto file = std::ifstream();
try
{
file.open(fileName, std::ios_base::app | std::ios_base::binary); file.open(fileName, std::ios_base::app | std::ios_base::binary);
int size; int size = 0;
file.read(reinterpret_cast<char*>(&size), sizeof(size)); file.read(reinterpret_cast<char*>(&size), sizeof(size));
// Read current level save data. // Read current level save data.
std::vector<byte> saveData(size); auto saveData = std::vector<byte>(size);
file.read(reinterpret_cast<char*>(saveData.data()), size); file.read(reinterpret_cast<char*>(saveData.data()), size);
// Reset hub data, as it's about to be replaced with saved one. // Reset hub data, as it's about to be replaced with saved one.
ResetHub(); ResetHub();
// Read hub data from savegame. // Read hub data from savegame.
int hubCount; int hubCount = 0;
file.read(reinterpret_cast<char*>(&hubCount), sizeof(hubCount)); file.read(reinterpret_cast<char*>(&hubCount), sizeof(hubCount));
TENLog("Hub count: " + std::to_string(hubCount), LogLevel::Info); TENLog("Hub count: " + std::to_string(hubCount), LogLevel::Info);
for (int i = 0; i < hubCount; i++) for (int i = 0; i < hubCount; i++)
{ {
int index; int index = 0;
file.read(reinterpret_cast<char*>(&index), sizeof(index)); file.read(reinterpret_cast<char*>(&index), sizeof(index));
file.read(reinterpret_cast<char*>(&size), sizeof(size)); file.read(reinterpret_cast<char*>(&size), sizeof(size));
std::vector<byte> hubBuffer(size); auto hubBuffer = std::vector<byte>(size);
file.read(reinterpret_cast<char*>(hubBuffer.data()), size); file.read(reinterpret_cast<char*>(hubBuffer.data()), size);
Hub[index] = hubBuffer; Hub[index] = hubBuffer;
@ -1624,6 +1668,16 @@ bool SaveGame::Load(int slot)
Parse(saveData, false); Parse(saveData, false);
return true; return true;
} }
catch (std::exception& ex)
{
TENLog("Error while loading savegame: " + std::string(ex.what()), LogLevel::Error);
if (file.is_open())
file.close();
}
return false;
}
static void ParseStatistics(const Save::SaveGame* s, bool isHub) static void ParseStatistics(const Save::SaveGame* s, bool isHub)
{ {
@ -1660,9 +1714,12 @@ static void ParseLua(const Save::SaveGame* s)
{ {
auto setSaved = s->volume_event_sets()->Get(i); auto setSaved = s->volume_event_sets()->Get(i);
for (int j = 0; j < setSaved->call_counters()->size(); ++j) for (int j = 0; j < setSaved->call_counters()->size(); ++j)
{
g_Level.VolumeEventSets[setSaved->index()].Events[j].Enabled = setSaved->statuses()->Get(j);
g_Level.VolumeEventSets[setSaved->index()].Events[j].CallCounter = setSaved->call_counters()->Get(j); g_Level.VolumeEventSets[setSaved->index()].Events[j].CallCounter = setSaved->call_counters()->Get(j);
} }
} }
}
if (g_Level.GlobalEventSets.size() == s->global_event_sets()->size()) if (g_Level.GlobalEventSets.size() == s->global_event_sets()->size())
{ {
@ -1670,9 +1727,12 @@ static void ParseLua(const Save::SaveGame* s)
{ {
auto setSaved = s->global_event_sets()->Get(i); auto setSaved = s->global_event_sets()->Get(i);
for (int j = 0; j < setSaved->call_counters()->size(); ++j) for (int j = 0; j < setSaved->call_counters()->size(); ++j)
{
g_Level.GlobalEventSets[setSaved->index()].Events[j].Enabled = setSaved->statuses()->Get(j);
g_Level.GlobalEventSets[setSaved->index()].Events[j].CallCounter = setSaved->call_counters()->Get(j); g_Level.GlobalEventSets[setSaved->index()].Events[j].CallCounter = setSaved->call_counters()->Get(j);
} }
} }
}
auto loadedVars = std::vector<SavedVar>{}; auto loadedVars = std::vector<SavedVar>{};
@ -1776,6 +1836,12 @@ static void ParseLua(const Save::SaveGame* s)
auto callbacksPreLoopVec = populateCallbackVecs(&Save::SaveGame::callbacks_pre_loop); auto callbacksPreLoopVec = populateCallbackVecs(&Save::SaveGame::callbacks_pre_loop);
auto callbacksPostLoopVec = populateCallbackVecs(&Save::SaveGame::callbacks_post_loop); auto callbacksPostLoopVec = populateCallbackVecs(&Save::SaveGame::callbacks_post_loop);
auto callbacksPreUseItemVec = populateCallbackVecs(&Save::SaveGame::callbacks_pre_useitem);
auto callbacksPostUseItemVec = populateCallbackVecs(&Save::SaveGame::callbacks_post_useitem);
auto callbacksPreFreezeVec = populateCallbackVecs(&Save::SaveGame::callbacks_pre_freeze);
auto callbacksPostFreezeVec = populateCallbackVecs(&Save::SaveGame::callbacks_post_freeze);
g_GameScript->SetCallbackStrings( g_GameScript->SetCallbackStrings(
callbacksPreStartVec, callbacksPreStartVec,
callbacksPostStartVec, callbacksPostStartVec,
@ -1786,7 +1852,11 @@ static void ParseLua(const Save::SaveGame* s)
callbacksPreLoadVec, callbacksPreLoadVec,
callbacksPostLoadVec, callbacksPostLoadVec,
callbacksPreLoopVec, callbacksPreLoopVec,
callbacksPostLoopVec); callbacksPostLoopVec,
callbacksPreUseItemVec,
callbacksPostUseItemVec,
callbacksPreFreezeVec,
callbacksPostFreezeVec);
} }
static void ParsePlayer(const Save::SaveGame* s) static void ParsePlayer(const Save::SaveGame* s)
@ -2046,7 +2116,7 @@ static void ParseEffects(const Save::SaveGame* s)
TENAssert(i < (int)SoundTrackType::Count, "Soundtrack type count was changed"); TENAssert(i < (int)SoundTrackType::Count, "Soundtrack type count was changed");
auto track = s->soundtracks()->Get(i); auto track = s->soundtracks()->Get(i);
PlaySoundTrack(track->name()->str(), (SoundTrackType)i, track->position()); PlaySoundTrack(track->name()->str(), (SoundTrackType)i, track->position(), SOUND_XFADETIME_LEVELJUMP);
} }
// Load fish swarm. // Load fish swarm.
@ -2208,6 +2278,8 @@ static void ParseLevel(const Save::SaveGame* s, bool hubMode)
room->mesh[number].flags = staticMesh->flags(); room->mesh[number].flags = staticMesh->flags();
room->mesh[number].HitPoints = staticMesh->hit_points(); room->mesh[number].HitPoints = staticMesh->hit_points();
room->mesh[number].Dirty = true;
if (!room->mesh[number].flags) if (!room->mesh[number].flags)
{ {
short roomNumber = staticMesh->room_number(); short roomNumber = staticMesh->room_number();
@ -2348,6 +2420,10 @@ static void ParseLevel(const Save::SaveGame* s, bool hubMode)
continue; continue;
} }
// If object is bridge - remove it from existing sectors.
if (item->IsBridge())
UpdateBridgeItem(g_Level.Items[i], BridgeUpdateType::Remove);
// Position // Position
item->Pose = ToPose(*savedItem->pose()); item->Pose = ToPose(*savedItem->pose());
item->RoomNumber = savedItem->room_number(); item->RoomNumber = savedItem->room_number();
@ -2415,8 +2491,9 @@ static void ParseLevel(const Save::SaveGame* s, bool hubMode)
item->Animation.AnimNumber = Objects[item->ObjectNumber].animIndex + savedItem->anim_number(); item->Animation.AnimNumber = Objects[item->ObjectNumber].animIndex + savedItem->anim_number();
} }
// Re-add bridges at new position.
if (item->IsBridge()) if (item->IsBridge())
UpdateBridgeItem(g_Level.Items[i]); UpdateBridgeItem(g_Level.Items[i], BridgeUpdateType::Initialize);
// Creature data for intelligent items. // Creature data for intelligent items.
if (item->ObjectNumber != ID_LARA && item->Status == ITEM_ACTIVE && obj->intelligent) if (item->ObjectNumber != ID_LARA && item->Status == ITEM_ACTIVE && obj->intelligent)
@ -2652,6 +2729,7 @@ bool SaveGame::LoadHeader(int slot, SaveGameHeader* header)
header->Level = s->header()->level(); header->Level = s->header()->level();
header->LevelName = s->header()->level_name()->str(); header->LevelName = s->header()->level_name()->str();
header->LevelHash = s->header()->level_hash();
header->Days = s->header()->days(); header->Days = s->header()->days();
header->Hours = s->header()->hours(); header->Hours = s->header()->hours();
header->Minutes = s->header()->minutes(); header->Minutes = s->header()->minutes();

Some files were not shown because too many files have changed in this diff Show more