mirror of
https://github.com/TombEngine/TombEngine.git
synced 2025-04-28 15:57:59 +03:00
Squashed commit of the following:
commit77d0865c8a
Author: Nemoel-Tomo <tomo_669@hotmail.com> Date: Sun Feb 16 08:20:58 2025 +0100 Waterfall emitter formatting fix (#1570) commit92329741ad
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Sat Feb 15 07:46:37 2025 +0100 Clarify EmitSpotLight description commit562637f599
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Fri Feb 14 23:10:40 2025 +0100 Fixed #1574 commita64825b6f1
Author: Sezz <sezzary@outlook.com> Date: Fri Feb 14 04:30:00 2025 +1100 Add missing shift in EmitParticle() commit455d547de7
Author: Sezz <sezzary@outlook.com> Date: Fri Feb 14 04:25:55 2025 +1100 Add lock to parallel task class commit918237113f
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 13 14:59:16 2025 +1100 Make script utils more idiomatic to C++ commitb78376b0ab
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 13 12:44:06 2025 +1100 Use correct angle conversion in EmitPatricle() commit3e00302ade
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 13 05:38:56 2025 +1100 Update Rotation.cpp commitf1c1fd2f63
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 13 04:12:34 2025 +1100 Add Lerp() method to script Rotation class commit6ef9675bcb
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Wed Feb 12 09:08:45 2025 +0100 Update CHANGELOG.md commitca56f62f54
Author: Sezz <sezzary@outlook.com> Date: Wed Feb 12 18:59:54 2025 +1100 Multithreading (#1541) * Create Worker class for multithreading * Update TombEngine.vcxproj * Rename GetWorkerCount() to GetThreadCount() * Add ProcessInParallel template for vectors * Add multiThreaded flag to settings, process sprites in parallel * Update Flow.Settings.html * Refine WorkerManager class conventions; deinit threads properly * Don't require explicit destruction * Address basic PR notes * Update Worker.cpp * Simplify ThreadManager class * Add method for running single task * Use singleton pattern; use more appropriate Controller suffix * Update WorkerController template method * Revise method * Handle exception in ~WorkerController() * Grammar * Correctly init single-threaded mode * Update CHANGELOG.md * Defer thread init until g_GameFlow is valid * unsigned int -> int * Rename class --------- Co-authored-by: Lwmte <3331699+Lwmte@users.noreply.github.com> commitd37ac17a39
Author: Sezz <sezzary@outlook.com> Date: Wed Feb 12 17:36:12 2025 +1100 Formatting commit62ce2f043d
Author: Sezz <sezzary@outlook.com> Date: Tue Feb 11 18:05:07 2025 +1100 Fix bridges moving the player when the player is underwater commit0bb9af9894
Author: Sezz <sezzary@outlook.com> Date: Tue Feb 11 17:31:51 2025 +1100 puzzle_keys.cpp formatting commit7d18d7506f
Author: davidmarr <116632612+davidmarr@users.noreply.github.com> Date: Sun Feb 9 15:58:15 2025 +0100 Update Type module (#1569) * Update VolumeObject.cpp fixed Volume:GetActive() method * Update CHANGELOG.md * function description LevelFuncs.OnUseItem * Revert "function description LevelFuncs.OnUseItem" This reverts commit2478afca68
. * Update Type.lua commit909f631c2f
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Sat Feb 8 11:04:40 2025 +0100 Fixed mistake in electricity rendering commita840c2200c
Merge:2c6331f58
a31faffec
Author: Sezz <sezzary@outlook.com> Date: Sat Feb 8 02:58:13 2025 +1100 Merge branch 'develop' of https://github.com/MontyTRC89/TombEngine into develop commit2c6331f583
Author: Sezz <sezzary@outlook.com> Date: Sat Feb 8 02:58:03 2025 +1100 Deprecate CalculateDistance() script function commita31faffec5
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Fri Feb 7 08:31:14 2025 +0100 Update CHANGELOG.md commit1f81ccf44d
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Thu Feb 6 18:05:25 2025 -0500 Diary module (TEN side) (#1509) * Update to bug report form * Update bug_report.yaml * Update AUTHORS.md - Tomo (general coding, special FX coding, bug fixing) * Update CHANGELOG.md * Update CHANGELOG.md * Update bug_report.yaml * Add files via upload * Add files via upload * Add ID_DIARY_SPRITES (1384) and DIARY_ENTRY_SPRITES (1385) * Delete Scripts/Engine/Diarymodule.lua * Add files via upload * Add files via upload * Add files via upload * Add files via upload * Delete Scripts/Engine/CustomBar.lua * Add files via upload * Update CustomDiary.lua * Add files via upload * Add files via upload * Add files via upload * Update CustomDiary.lua * Upload * Update CHANGELOG.md * Revisions * Doc revisions * Remove GameVars.Engine everywhere. * Added error warnings by integrating type module * Update bug_report.yaml * Fixed the bug with GameVars resetting each level. * Added .Engine back. * Added missing checks. * Removed nil from textOptions loop * Added full TEN name for printlogs. * LatestChanges * Added section for import. --------- Co-authored-by: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> commit34ff933e5b
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 6 18:48:45 2025 +1100 Update LogicHandler.cpp commit5500b13659
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 6 18:47:33 2025 +1100 Update LogicHandler.cpp commitacb1bb1518
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 6 18:46:16 2025 +1100 Enforce proper convention for the few Lua table constants that didn't use it yet commit89d5b74298
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Thu Feb 6 02:09:53 2025 -0500 Fix Trigger Triggerer (#1565) * Fix * Update CHANGELOG.md * Update trigger.cpp --------- Co-authored-by: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> commit8316062e3a
Merge:5f447d95c
599a651b6
Author: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Date: Thu Feb 6 06:03:41 2025 +0000 Merge branch 'develop' of https://github.com/MontyTRC89/TombEngine into develop commit5f447d95c5
Author: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Date: Thu Feb 6 06:03:18 2025 +0000 Fix stopwatch display in inventory (due to removal of trademarked item) Now the trademarked item from Tomb Raider Chronicles has been removed and replaced with the stopwatch from Tomb Raider III commit599a651b6f
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 6 16:56:19 2025 +1100 Update lens flare and starfield Lua docs commit94ede801bc
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 6 16:35:59 2025 +1100 Misc. script doc tidying; move some script classes to namespaces commitbe8048407e
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Wed Feb 5 23:51:35 2025 -0500 Underwater keys/puzzles (#1529) * Update to bug report form * Update bug_report.yaml * Update AUTHORS.md - Tomo (general coding, special FX coding, bug fixing) * Update CHANGELOG.md * Update CHANGELOG.md * Update bug_report.yaml * First Push * Updae LaraStruct to use animation 280 * Update puzzles_keys.cpp * Update CHANGELOG.md * Squashed commit of the following: commite50a4f8c27
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Wed Dec 25 20:07:56 2024 -0500 Doc Revision commit39a6e713ce
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Wed Dec 25 20:02:47 2024 -0500 Doc revisions commitc330343820
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Wed Dec 25 19:52:59 2024 -0500 Update CHANGELOG.md commitad62d7b605
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Wed Dec 25 19:42:32 2024 -0500 Check commite135195641
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Wed Dec 25 19:26:23 2024 -0500 First Commit commit4a6c6ee270
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Wed Dec 25 19:19:05 2024 -0500 Update EffectsFunctions.cpp * Revert "Squashed commit of the following:" This reverts commitff2e49c6ed
. * Formatting. * Formatting. * Update CHANGELOG.md --------- Co-authored-by: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Co-authored-by: Nemoel-Tomo <tomo_669@hotmail.com> Co-authored-by: Jakub <kubabilinski03@gmail.com> Co-authored-by: Jakub <80340234+Jakub768@users.noreply.github.com> Co-authored-by: Lwmte <3331699+Lwmte@users.noreply.github.com> Co-authored-by: TrainWreck <barry@DESKTOP-HC53CPN> commit106787d911
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 6 04:34:28 2025 +1100 Doc corrections commit737f5aa742
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 6 04:28:58 2025 +1100 Make getters const commit2b41ae743a
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 6 02:35:16 2025 +1100 Tidy up Lua doc for Static class commit437ce7c139
Author: Sezz <sezzary@outlook.com> Date: Thu Feb 6 01:22:59 2025 +1100 Complete short -> int conversions for Lua commit237ceca0f4
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Wed Feb 5 08:04:23 2025 +0100 Fixed custom shatter sounds commit64e0c303ba
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Tue Feb 4 20:58:09 2025 +0100 Update CHANGELOG.md commitd2b692cb3b
Author: Sezz <sezzary@outlook.com> Date: Mon Feb 3 16:15:41 2025 +1100 ShadowMode::Lara -> ShadowMode::Player commitebb20121ac
Author: Sezz <sezzary@outlook.com> Date: Sat Feb 1 23:57:54 2025 +1100 -1 -> NO_VALUE and other formatting commit4a6f30a152
Author: Jakub <80340234+Jakub768@users.noreply.github.com> Date: Sat Feb 1 12:07:10 2025 +0000 Update LICENSE commit45d46e0e6b
Author: Sezz <sezzary@outlook.com> Date: Sat Feb 1 22:55:35 2025 +1100 Fix display pickup string not being interpolated in 60FPS mode commit903fdf288f
Author: Sezz <sezzary@outlook.com> Date: Sat Feb 1 22:40:50 2025 +1100 Optimise BitField class (#1511) * Optimise BitField class * DebugBuild -> DEBUG_BUILD * Fix merge error commit48902b00a9
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Sat Feb 1 06:23:04 2025 -0500 Emit air bubble exposed (#1537) * Update to bug report form * Update bug_report.yaml * Update AUTHORS.md - Tomo (general coding, special FX coding, bug fixing) * Update CHANGELOG.md * Update CHANGELOG.md * Update bug_report.yaml * Update EffectsFunctions.cpp * First Commit * Check * Update CHANGELOG.md * Doc revisions * Doc Revision * Update EffectsFunctions.cpp * Remove room from arguements. * Doc clarification. * Make Size and Amplitude Optional * Update EffectsFunctions.cpp --------- Co-authored-by: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Co-authored-by: Nemoel-Tomo <tomo_669@hotmail.com> Co-authored-by: Jakub <kubabilinski03@gmail.com> Co-authored-by: Jakub <80340234+Jakub768@users.noreply.github.com> Co-authored-by: Lwmte <3331699+Lwmte@users.noreply.github.com> Co-authored-by: Sezz <sezzary@outlook.com> commitfa0e125f59
Author: TrainWrack <120750885+TrainWrack@users.noreply.github.com> Date: Sat Feb 1 06:22:49 2025 -0500 Emit particle upgrade (#1542) * Update to bug report form * Update bug_report.yaml * Update AUTHORS.md - Tomo (general coding, special FX coding, bug fixing) * Update CHANGELOG.md * Update CHANGELOG.md * Update bug_report.yaml * Expose ObjectSlot * Docs * Code Update * FinalPush * Update CHANGELOG.md * Update CHANGELOG.md * Update CHANGELOG.md * Expose startRot * Expose startRot * Remove Space. * Code cleanup, revise doc comment * Nicer defaults in doc --------- Co-authored-by: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Co-authored-by: Nemoel-Tomo <tomo_669@hotmail.com> Co-authored-by: Jakub <kubabilinski03@gmail.com> Co-authored-by: Jakub <80340234+Jakub768@users.noreply.github.com> Co-authored-by: Lwmte <3331699+Lwmte@users.noreply.github.com> Co-authored-by: Sezz <sezzary@outlook.com> commitbcbe216508
Author: Sezz <sezzary@outlook.com> Date: Sat Feb 1 20:17:11 2025 +1100 Update Vec3.cpp commit06c33908d9
Author: Sezz <sezzary@outlook.com> Date: Sat Feb 1 20:13:34 2025 +1100 Explicit conversion commitc99b8abf25
Author: Sezz <sezzary@outlook.com> Date: Sat Feb 1 20:01:55 2025 +1100 Add Translate() functions to script Vec2 and Vec3 classes commitd8c646fabd
Author: Sezz <sezzary@outlook.com> Date: Sat Feb 1 17:47:29 2025 +1100 Start restructuring script Moveable class commit98b01ff64a
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Thu Jan 30 22:25:57 2025 +0100 Fixed #1562 commitd163d1ec30
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Mon Jan 27 19:27:08 2025 +0100 Fixed #1558 commit6ef8a562e5
Author: Sezz <sezzary@outlook.com> Date: Tue Jan 28 04:10:12 2025 +1100 Update doc comment for moveable commitd919e16790
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Sat Jan 25 23:03:28 2025 +0100 Fixed player model submerging into the floor while swimming underwater commitfaf17cd03a
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Fri Jan 24 23:18:14 2025 +0100 Fixed #1557 commit5f402e380b
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Fri Jan 24 22:55:08 2025 +0100 Fixed #1556 commitae20a49eb2
Author: Sezz <sezzary@outlook.com> Date: Thu Jan 23 17:02:26 2025 +1100 Update VS hint comments for various classes commitfb97628ac9
Author: Sezz <sezzary@outlook.com> Date: Thu Jan 23 16:48:46 2025 +1100 Add `Scale` field to `Pose` class (#1546) * Reapply "Add functional Scale field to Pose class" This reverts commit92305a5d25
. * Update lara.cpp commitfc0c260ea1
Author: Sezz <sezzary@outlook.com> Date: Thu Jan 23 15:25:09 2025 +1100 Update script Rotation class and its doc commit0dd0061a94
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Tue Jan 21 20:55:57 2025 +0100 Update CHANGELOG.md commit7735f660ab
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Tue Jan 21 20:49:32 2025 +0100 Fixed #1553 commit5764965230
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Tue Jan 21 20:47:06 2025 +0100 Fixed #1554 commitb55675b9ce
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Tue Jan 21 20:46:47 2025 +0100 Fixed #1552 commit7be096f86a
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Sun Jan 19 05:41:05 2025 +0100 Fixed dynamic light shadows not being handled correctly commitdb2649e936
Author: Sezz <sezzary@outlook.com> Date: Sat Jan 18 19:54:04 2025 +1100 Fix two block platform sometimes not traversing room portals correctly; cleanup commitff41900bd9
Author: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Date: Sun Jan 12 16:35:44 2025 +0000 Updated to reflect develop branch after merging Pull Request commit2a89abe66d
Author: Nemoel-Tomo <tomo_669@hotmail.com> Date: Sun Jan 12 17:15:45 2025 +0100 Tr1 electric ball (#1413) Implementation of the Electric Ball from Tomb Raider I, inside Level 5: St Francis Folly commita97548467e
Author: Nemoel-Tomo <tomo_669@hotmail.com> Date: Fri Jan 10 23:27:48 2025 +0100 Waterfall_Emitter (#1359) * waterfall emitter. warning for the test I changed waterfallmist object * test * update * update * update * formatting * formatting * formatting * update mist color * import develop * bugfix sprite * added mor sprite particles * waterfall intensity * update waterfall to be more filled * update * Create a new sprite sequence for waterfall * Fixed texture order * removed GetParticleDistanceFade() from waterfall * Order * Update Particle struct; update waterfall * Update Particle struct * Simplify waterfall emitter * Simplify waterfall emitter * Simplify waterfall emitter * Simplify * Fix waterfall density; move sprite slot * Update Waterfall.cpp * fixed some small bugs with the waterfall after simplify * commit * imported develop 60fps branch * fixed waterfall errors * update * commit * update/test * update Waterfall * fixed last bugs * formatting * added option for sound * update * update, fixing errors * update * formatting * Formatting * fixed color issue, now only savegame is left * formatting * added new fields to savegame * targetpos is now Vector3 * import develop * Fixes according to GH notes + move waterfall-specific code out of effects.cpp * Rollback object ID rename, add missing enum * renamed ID_WATERFALL_ into ID_WATERFALL_SPRITES * fixed SpriteSeqID for spark in spark.cpp * Update CHANGELOG.md * rewritten waterfall code * Update waterfall impact point --------- Co-authored-by: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Co-authored-by: Sezz <sezzary@outlook.com> Co-authored-by: Lwmte <3331699+Lwmte@users.noreply.github.com> commitbfe07f6e21
Author: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Date: Sun Jan 5 16:45:30 2025 +0000 Bump version in Lua API for development commit4dce157665
Author: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Date: Sun Jan 5 16:27:38 2025 +0000 Bump Tomb Editor version for next dev cycle Amended also in the Development branch for TE commitc25c7a1c96
Author: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Date: Sun Jan 5 15:10:17 2025 +0000 Update CHANGELOG.md commit2da7401c28
Author: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Date: Sun Jan 5 15:09:41 2025 +0000 Update changelog with template for the next version. commit66d7e51f5d
Author: Stranger1992 <84292688+Stranger1992@users.noreply.github.com> Date: Sat Jan 4 18:41:11 2025 +0000 Bump dev version to 1.7.2 This has been done to draw a line post-release and any commits after this to form the next release. Version number may change. commitcebc0175c9
Author: Sezz <sezzary@outlook.com> Date: Sat Jan 4 17:03:46 2025 +1100 Move splash effect to its own file commitb81b28039c
Author: Sezz <sezzary@outlook.com> Date: Sat Jan 4 16:03:07 2025 +1100 Fix gravity being applied when vaulting on the same frame as the player lands commit5444ede2a8
Author: Sezz <sezzary@outlook.com> Date: Sat Jan 4 15:51:52 2025 +1100 Reliably stop at edge when running at it while holding Walk commit43d5bb9639
Author: Sezz <sezzary@outlook.com> Date: Fri Jan 3 23:31:59 2025 +1100 Update CHANGELOG.md commitfb7e4dce70
Merge:9baf5222f
12ac1219e
Author: Sezz <sezzary@outlook.com> Date: Fri Jan 3 23:06:28 2025 +1100 Merge branch 'develop' of https://github.com/MontyTRC89/TombEngine into develop commit9baf5222f8
Author: Sezz <sezzary@outlook.com> Date: Fri Jan 3 23:06:25 2025 +1100 Reset IsAirborne flag properly when exiting fly cheat commit12ac1219e9
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Thu Jan 2 13:10:57 2025 +0100 Update spark.cpp commit7f071b5ec5
Author: Lwmte <3331699+Lwmte@users.noreply.github.com> Date: Thu Jan 2 11:15:04 2025 +0100 Port additional ricochet effect from tomb4
This commit is contained in:
parent
cc83cd5db0
commit
f4570211a5
239 changed files with 10560 additions and 5480 deletions
41
CHANGELOG.md
41
CHANGELOG.md
|
@ -3,24 +3,59 @@
|
|||
The dates are in European standard format where date is presented as **YYYY-MM-DD**.
|
||||
TombEngine releases are located in this repository (alongside with Tomb Editor): https://github.com/TombEngine/TombEditorReleases
|
||||
|
||||
## Version 1.7.1 - xxxx-xx-xx
|
||||
## [Version 1.7.X] (link to release) - yyyy-mm-dd
|
||||
|
||||
### Bug fixes
|
||||
* Fixed bridges moving the player when the player is underwater.
|
||||
* Fixed trigger triggerer not working.
|
||||
* Fixed display pickup numeric string not being interpolated in high framerate mode.
|
||||
* Fixed two block platform room portal traversal failing in some cases.
|
||||
* Fixed incorrect handling of dynamic light shadows.
|
||||
* Fixed ricochet flashes after using explosive weapons.
|
||||
* Fixed incorrect flare draw in crawl state.
|
||||
* Fixed starfield remaining active in the next level if next level does not have a starfield specified.
|
||||
* Fixed wetness player attribute not being preserved in savegames.
|
||||
* Fixed invisible HK ammo in the inventory.
|
||||
* Fixed flickering rat emitter.
|
||||
* Fixed player model submerging into the floor while swimming underwater.
|
||||
* Fixed custom shatter sounds with custom sound IDs not playing correctly.
|
||||
* Fixed crashes with sound samples larger than 2 megabytes.
|
||||
|
||||
### New Features
|
||||
* Added multithreading and an option for it to flow system settings.
|
||||
* Added ability to use keys and puzzle items underwater.
|
||||
- You must update your Lara object: https://github.com/TombEngine/Resources/raw/main/Wad2%20Objects/Lara/TEN_Lara.wad2
|
||||
* Added a particle based waterfall emitter object and associated sprite slots.
|
||||
- You must use this version: https://github.com/TombEngine/Resources/raw/refs/heads/main/Wad2%20Objects/Interactables/TEN_Waterfall_Emitter.wad2
|
||||
|
||||
### Lua API changes
|
||||
* Added Lerp() function to the Rotation object to allow linear interpolation between rotations.
|
||||
* Added diary module.
|
||||
* Added Effects.EmitAirBubble() function to spawn air bubbles.
|
||||
* Added additional arguments for Sprite object slot and starting rotation value for EmitParticle function.
|
||||
* Added various Translate() methods to Vec2 and Vec3 script objects.
|
||||
|
||||
## [Version 1.7.1] (https://github.com/TombEngine/TombEditorReleases/releases/tag/v1.7.4) - 2025-04-01
|
||||
|
||||
### Bug fixes
|
||||
* Fixed static meshes with dynamic light mode not accepting room lights.
|
||||
* Fixed silent crashes if no Visual C++ runtimes are installed, and provide a dialog box to download them instead.
|
||||
* Fixed silent crashes if no Visual C++ runtimes are installed and provide a dialog box to download them instead.
|
||||
* Fixed issues with launching the engine from directories with non-Western characters in the path.
|
||||
* Fixed rare case of not being able to start a new game or exit game from the main menu on very slow GPUs.
|
||||
* Fixed occasional crashes with creatures stuck in a sector with no pathfinding set.
|
||||
* Fixed occasional cases of underwater switch animation not playing, if player spams jump key while pulling the switch.
|
||||
* Fixed Lara's blob shadows not rendering on moveables and static meshes.
|
||||
* Fixed player's blob shadows not rendering on moveables and static meshes.
|
||||
* Fixed antialiasing quality not changing after changing it in display settings.
|
||||
* Fixed endless explosion effect for Puna.
|
||||
* Fixed diary pick-up item inventory state not preserved in the savegame.
|
||||
* Fixed gravity being applied underwater when exiting the fly cheat.
|
||||
* Fixed gravity being applied when vaulting on the same frame as the player lands.
|
||||
|
||||
### New Features
|
||||
* Added realtime shader reloading in debug mode by pressing F9 key.
|
||||
* Added load, save, stopwatch and compass as a functional pick-up items with ability to add or remove them from inventory.
|
||||
* Increased particle limit from 1024 to 4096.
|
||||
* Added ability for the player to more reliably stop at an edge when running at it while holding Walk.
|
||||
|
||||
### Lua API changes
|
||||
* Fixed Flow.FreezeMode.FULL drawing incorrect background.
|
||||
|
|
|
@ -12,7 +12,7 @@ new_type("luautil", "5 Lua utility modules", true)
|
|||
|
||||
not_luadoc = true
|
||||
|
||||
local version = "1.7.1"
|
||||
local version = "1.7.2 (Developer)"
|
||||
project = " TombEngine"
|
||||
title = "TombEngine " .. version .. " Lua API"
|
||||
description = "TombEngine " .. version .. " scripting interface"
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -120,7 +122,7 @@
|
|||
<td class="summary">Emit a lightning arc.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#EmitParticle">EmitParticle(pos, velocity, spriteIndex, gravity, rot, startColor, endColor, blendMode, startSize, endSize, lifetime, damage, poison)</a></td>
|
||||
<td class="name" ><a href="#EmitParticle">EmitParticle(pos, vel, spriteID, gravity, rotVel, startColor, endColor, blendMode, startSize, endSize, life, applyDamage, applyPoison, spriteSeqID, startRot)</a></td>
|
||||
<td class="summary">Emit a particle.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
|
@ -140,6 +142,10 @@
|
|||
<td class="summary">Emit blood.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#EmitAirBubble">EmitAirBubble(pos[, size][, amp])</a></td>
|
||||
<td class="summary">Emit air bubble in a water room.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#EmitFire">EmitFire(pos, size)</a></td>
|
||||
<td class="summary">Emit fire for one frame.</td>
|
||||
</tr>
|
||||
|
@ -224,14 +230,10 @@
|
|||
</dd>
|
||||
<dt>
|
||||
<a name = "EmitParticle"></a>
|
||||
<strong>EmitParticle(pos, velocity, spriteIndex, gravity, rot, startColor, endColor, blendMode, startSize, endSize, lifetime, damage, poison)</strong>
|
||||
<strong>EmitParticle(pos, vel, spriteID, gravity, rotVel, startColor, endColor, blendMode, startSize, endSize, life, applyDamage, applyPoison, spriteSeqID, startRot)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Emit a particle. </p>
|
||||
<pre><code> See the sprite editor in WadTool for DEFAULT_SPRITES to see a list of sprite indices.
|
||||
</code></pre>
|
||||
|
||||
Emit a particle.
|
||||
|
||||
|
||||
|
||||
|
@ -239,59 +241,63 @@
|
|||
<ul>
|
||||
<li><span class="parameter">pos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
|
||||
|
||||
|
||||
World position.
|
||||
</li>
|
||||
<li><span class="parameter">velocity</span>
|
||||
<li><span class="parameter">vel</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
|
||||
|
||||
|
||||
Velocity.
|
||||
</li>
|
||||
<li><span class="parameter">spriteIndex</span>
|
||||
<li><span class="parameter">spriteID</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
an index of a sprite in DEFAULT_SPRITES object.
|
||||
ID of the sprite in the sprite sequence object.
|
||||
</li>
|
||||
<li><span class="parameter">gravity</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
(default 0) Specifies whether particle will fall (positive values) or ascend (negative values) over time. Clamped to [-32768, 32767], but values between -1000 and 1000 are recommended; values too high or too low (e.g. under -2000 or above 2000) will cause the velocity of the particle to "wrap around" and switch directions.
|
||||
</li>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
(default 0) specifies a speed with which it will rotate (0 = no rotation, negative = anticlockwise rotation, positive = clockwise rotation).
|
||||
Specifies if the particle will fall over time. Positive values ascend, negative values descend. Recommended range: [-1000 and 1000]. <strong>Default: 0</strong>
|
||||
</li>
|
||||
<li><span class="parameter">rotVel</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Rotational velocity in degrees. <strong>Default: 0</strong>
|
||||
</li>
|
||||
<li><span class="parameter">startColor</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
(default Color(255, 255, 255)) color at start of life
|
||||
Color at start of life. <strong>Default: Color(255, 255, 255)</strong>
|
||||
</li>
|
||||
<li><span class="parameter">endColor</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
(default Color(255, 255, 255)) color to fade to - at the time of writing this fade will finish long before the end of the particle's life due to internal maths
|
||||
Color to fade toward. This will finish long before the end of the particle's life due to internal math. <strong>Default: Color(255, 255, 255)</strong>
|
||||
</li>
|
||||
<li><span class="parameter">blendMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Effects.BlendID.html#">BlendID</a></span>
|
||||
(default TEN.Effects.BlendID.ALPHABLEND) How will we blend this with its surroundings?
|
||||
Render blend mode. <strong>TEN.Effects.BlendID.ALPHABLEND</strong>
|
||||
</li>
|
||||
<li><span class="parameter">startSize</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
(default 10) Size on spawn. A value of 15 is approximately the size of Lara's head.
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Size at start of life. <strong>Default: 10</strong>
|
||||
</li>
|
||||
<li><span class="parameter">endSize</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
(default 0) Size on death - the particle will linearly shrink or grow to this size during its lifespan
|
||||
</li>
|
||||
<li><span class="parameter">lifetime</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
(default 2) Lifespan in seconds
|
||||
Size at end of life. The particle will linearly shrink or grow toward this size over its lifespan. <strong>Default: 0</strong>
|
||||
</li>
|
||||
<li><span class="parameter">damage</span>
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
(default false) specifies whether particle can damage Lara (does a very small amount of damage, like the small lava emitters in TR1)
|
||||
<li><span class="parameter">life</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Lifespan in seconds. <strong>Default: 2</strong>
|
||||
</li>
|
||||
<li><span class="parameter">poison</span>
|
||||
<li><span class="parameter">applyDamage</span>
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
(default false) specifies whether particle can poison Lara
|
||||
Specify if the particle will harm the player on collision. <strong>Default: false</strong>
|
||||
</li>
|
||||
<li><span class="parameter">applyPoison</span>
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
Specify if the particle will poison the player on collision. <strong>Default: false</strong>
|
||||
</li>
|
||||
<li><span class="parameter">spriteSeqID</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Objects.ObjID.html#">ObjID</a></span>
|
||||
ID of the sprite sequence object. <strong>Default: Objects.ObjID.DEFAULT_SPRITES</strong>
|
||||
</li>
|
||||
<li><span class="parameter">startRot</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Rotation at start of life. <strong>Default: random</strong>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
@ -301,19 +307,21 @@
|
|||
<h3>Usage:</h3>
|
||||
<ul>
|
||||
<pre class="example">EmitParticle(
|
||||
yourPositionVarHere,
|
||||
pos,
|
||||
Vec3(<span class="global">math</span>.random(), <span class="global">math</span>.random(), <span class="global">math</span>.random()),
|
||||
<span class="number">22</span>, <span class="comment">-- spriteIndex
|
||||
<span class="number">22</span>, <span class="comment">-- spriteID
|
||||
</span> <span class="number">0</span>, <span class="comment">-- gravity
|
||||
</span> -<span class="number">2</span>, <span class="comment">-- rot
|
||||
</span> -<span class="number">2</span>, <span class="comment">-- rotVel
|
||||
</span> Color(<span class="number">255</span>, <span class="number">0</span>, <span class="number">0</span>), <span class="comment">-- startColor
|
||||
</span> Color(<span class="number">0</span>, <span class="number">255</span>, <span class="number">0</span>), <span class="comment">-- endColor
|
||||
</span> TEN.Effects.BlendID.ADDITIVE, <span class="comment">-- blendMode
|
||||
</span> <span class="number">15</span>, <span class="comment">-- startSize
|
||||
</span> <span class="number">50</span>, <span class="comment">-- endSize
|
||||
</span> <span class="number">20</span>, <span class="comment">-- lifetime
|
||||
</span> <span class="keyword">false</span>, <span class="comment">-- damage
|
||||
</span> <span class="keyword">true</span> <span class="comment">-- poison
|
||||
</span> <span class="number">20</span>, <span class="comment">-- life
|
||||
</span> <span class="keyword">false</span>, <span class="comment">-- applyDamage
|
||||
</span> <span class="keyword">true</span>, <span class="comment">-- applyPoison
|
||||
</span> Objects.ObjID.DEFAULT_SPRITES, <span class="comment">-- spriteSeqID
|
||||
</span> <span class="number">180</span> <span class="comment">-- startRot
|
||||
</span> )</pre>
|
||||
</ul>
|
||||
|
||||
|
@ -495,13 +503,45 @@
|
|||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "EmitAirBubble"></a>
|
||||
<strong>EmitAirBubble(pos[, size][, amp])</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Emit air bubble in a water room.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
World position where the effect will be spawned. Must be in a water room.
|
||||
</li>
|
||||
<li><span class="parameter">size</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Sprite size. <strong>Default: 32</strong>
|
||||
(<em>optional</em>)
|
||||
</li>
|
||||
<li><span class="parameter">amp</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Oscillation amplitude. <strong>Default: 32</strong>
|
||||
(<em>optional</em>)
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "EmitFire"></a>
|
||||
<strong>EmitFire(pos, size)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Emit fire for one frame. Will not hurt Lara. Call this each frame if you want a continuous fire.
|
||||
Emit fire for one frame. Will not hurt player. Call this each frame if you want a continuous fire.
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -179,29 +181,29 @@ designer to add calls to <code>OnStart</code>, <code>OnLoad</code>, etc. in thei
|
|||
|
||||
<p>Possible values for <code>point</code>:</p>
|
||||
<pre class="example"><span class="comment">-- These take functions which accept no arguments
|
||||
</span>PRESTART <span class="comment">-- will be called immediately before OnStart
|
||||
</span>POSTSTART <span class="comment">-- will be called immediately after OnStart
|
||||
</span>PRE_START <span class="comment">-- will be called immediately before OnStart
|
||||
</span>POST_START <span class="comment">-- will be called immediately after OnStart
|
||||
</span>
|
||||
PRESAVE <span class="comment">-- will be called immediately before OnSave
|
||||
</span>POSTSAVE <span class="comment">-- will be called immediately after OnSave
|
||||
PRE_SAVE <span class="comment">-- will be called immediately before OnSave
|
||||
</span>POST_SAVE <span class="comment">-- will be called immediately after OnSave
|
||||
</span>
|
||||
PRELOAD <span class="comment">-- will be called immediately before OnLoad
|
||||
</span>POSTLOAD <span class="comment">-- will be called immediately after OnLoad
|
||||
PRE_LOAD <span class="comment">-- will be called immediately before OnLoad
|
||||
</span>POST_LOAD <span class="comment">-- will be called immediately after OnLoad
|
||||
</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
|
||||
PRE_FREEZE <span class="comment">-- will be called before entering freeze mode
|
||||
</span>POST_FREEZE <span class="comment">-- will be called immediately after exiting freeze mode
|
||||
</span>
|
||||
<span class="comment">-- These take a LevelEndReason arg, like OnEnd
|
||||
</span>PREEND <span class="comment">-- will be called immediately before OnEnd
|
||||
</span>POSTEND <span class="comment">-- will be called immediately after OnEnd
|
||||
</span>PRE_END <span class="comment">-- will be called immediately before OnEnd
|
||||
</span>POST_END <span class="comment">-- will be called immediately after OnEnd
|
||||
</span>
|
||||
<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>POSTLOOP <span class="comment">-- will be called at the end of game loop
|
||||
</span>PRE_LOOP <span class="comment">-- will be called in the beginning of game loop
|
||||
</span>POST_LOOP <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_USE_ITEM <span class="comment">-- will be called immediately before OnUseItem
|
||||
</span>POST_USE_ITEM <span class="comment">-- will be called immediately after OnUseItem
|
||||
</span></pre>
|
||||
<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>
|
||||
|
@ -278,7 +280,7 @@ SAVE
|
|||
START
|
||||
END
|
||||
LOOP
|
||||
USEITEM
|
||||
USE_ITEM
|
||||
MENU</pre>
|
||||
|
||||
|
||||
|
@ -508,9 +510,9 @@ and provides the delta time (a float representing game time since last call) via
|
|||
|
||||
<p>(EndReason) Will be called when leaving a level. This includes finishing it, exiting to the menu, or loading a save in a different level. It can take an <code>EndReason</code> arg:</p>
|
||||
|
||||
<pre><code>EXITTOTITLE
|
||||
LEVELCOMPLETE
|
||||
LOADGAME
|
||||
<pre><code>EXIT_TO_TITLE
|
||||
LEVEL_COMPLETE
|
||||
LOAD_GAME
|
||||
DEATH
|
||||
OTHER
|
||||
</code></pre>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -107,7 +109,7 @@
|
|||
<div id="content">
|
||||
|
||||
<h1>Table <code>Objects</code></h1>
|
||||
<p>Moveables, statics, cameras, and so on.</p>
|
||||
<p>Objects including moveables, statics, cameras, and others.</p>
|
||||
<p>
|
||||
|
||||
</p>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -120,10 +122,6 @@
|
|||
<td class="summary">Determine if there is a clear line of sight between two positions.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CalculateDistance">CalculateDistance(posA, posB)</a></td>
|
||||
<td class="summary">Calculate the distance between two positions.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CalculateHorizontalDistance">CalculateHorizontalDistance(posA, posB)</a></td>
|
||||
<td class="summary">Calculate the horizontal distance between two positions.</td>
|
||||
</tr>
|
||||
|
@ -201,38 +199,6 @@
|
|||
<span class="global">print</span>(Misc.HasLineOfSight(enemyHead:GetRoomNumber(), enemyHead:GetPosition(), flamePlinthPos))</pre>
|
||||
</ul>
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CalculateDistance"></a>
|
||||
<strong>CalculateDistance(posA, posB)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Calculate the distance between two positions.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">posA</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
First position.
|
||||
</li>
|
||||
<li><span class="parameter">posB</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
Second position.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Distance between two positions.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CalculateHorizontalDistance"></a>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -303,6 +305,10 @@
|
|||
<td class="summary">How should the application respond to script errors?</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#multiThreaded">multiThreaded</a></td>
|
||||
<td class="summary">Use multithreading in certain calculations.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#fastReload">fastReload</a></td>
|
||||
<td class="summary">Can the game utilize the fast reload feature?</td>
|
||||
</tr>
|
||||
|
@ -1251,6 +1257,29 @@
|
|||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "multiThreaded"></a>
|
||||
<strong>multiThreaded</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Use multithreading in certain calculations. <br>
|
||||
When set to <code>true</code>, some performance-critical calculations will be performed in parallel, which can give
|
||||
a significant performance boost. Don't disable unless you have problems with launching or using TombEngine.
|
||||
|
||||
|
||||
|
||||
<ul>
|
||||
<li><span class="parameter">multiThreaded</span>
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
determines whether to use multithreading or not. */
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "fastReload"></a>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -107,17 +109,16 @@
|
|||
<div id="content">
|
||||
|
||||
<h1>Class <code>Objects.LaraObject</code></h1>
|
||||
<p>Class for extra Lara-only functions.</p>
|
||||
<p>Do not try to create an object of this type; use the built-in <em>Lara</em> variable instead.</p>
|
||||
|
||||
<p>In addition, LaraObject inherits all the functions of <a href="../2 classes/Objects.Moveable.html#">Moveable</a>.</p>
|
||||
<p>Class for extra player-only functions.</p>
|
||||
<p> Do not try to create an object of this type. Use the built-in <em>Lara</em> variable instead.
|
||||
LaraObject inherits all the functions of <a href="../2 classes/Objects.Moveable.html#">Moveable</a>.</p>
|
||||
|
||||
|
||||
<h2><a href="#Functions">Functions</a></h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" ><a href="#LaraObject:SetPoison">LaraObject:SetPoison([Poison])</a></td>
|
||||
<td class="summary">Set Lara poison</td>
|
||||
<td class="summary">Set player poison.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LaraObject:GetPoison">LaraObject:GetPoison()</a></td>
|
||||
|
@ -213,7 +214,7 @@
|
|||
<strong>LaraObject:SetPoison([Poison])</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set Lara poison
|
||||
Set player poison.
|
||||
|
||||
|
||||
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -107,7 +109,7 @@
|
|||
<div id="content">
|
||||
|
||||
<h1>Class <code>Objects.Sink</code></h1>
|
||||
<p>Sink</p>
|
||||
<p>Represents a sink object.</p>
|
||||
<p>
|
||||
|
||||
</p>
|
||||
|
@ -115,31 +117,29 @@
|
|||
|
||||
<h2><a href="#Functions">Functions</a></h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" ><a href="#Sink:GetPosition">Sink:GetPosition()</a></td>
|
||||
<td class="summary">Get the sink's position</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Sink:SetPosition">Sink:SetPosition(position)</a></td>
|
||||
<td class="summary">Set the sink's position</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Sink:GetName">Sink:GetName()</a></td>
|
||||
<td class="summary">Get the sink's unique string identifier
|
||||
e.g.</td>
|
||||
<td class="summary">Get this sink's unique string identifier.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Sink:SetName">Sink:SetName(name)</a></td>
|
||||
<td class="summary">Set the sink's name (its unique string identifier)</td>
|
||||
<td class="name" ><a href="#Sink:GetPosition">Sink:GetPosition()</a></td>
|
||||
<td class="summary">Get this sink's world position.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Sink:GetStrength">Sink:GetStrength()</a></td>
|
||||
<td class="summary">Get the sink's strength</td>
|
||||
<td class="summary">Get this sink's strength.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Sink:SetName">Sink:SetName(name)</a></td>
|
||||
<td class="summary">Set this sink's unique string identifier.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Sink:SetPosition">Sink:SetPosition(pos)</a></td>
|
||||
<td class="summary">Set this sink's world position.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Sink:SetStrength">Sink:SetStrength(strength)</a></td>
|
||||
<td class="summary">Set the strength of the sink
|
||||
Higher numbers provide stronger currents.</td>
|
||||
<td class="summary">Set this sink's strength.</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
@ -150,56 +150,12 @@
|
|||
<h2 class="section-header "><a name="Functions"></a>Functions</h2>
|
||||
|
||||
<dl class="function">
|
||||
<dt>
|
||||
<a name = "Sink:GetPosition"></a>
|
||||
<strong>Sink:GetPosition()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the sink's position
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
a copy of the sink's position
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Sink:SetPosition"></a>
|
||||
<strong>Sink:SetPosition(position)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the sink's position
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">position</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
the new position of the sink
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Sink:GetName"></a>
|
||||
<strong>Sink:GetName()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the sink's unique string identifier
|
||||
e.g. "strong_river_current" or "propeller_death_sink"
|
||||
Get this sink's unique string identifier.
|
||||
|
||||
|
||||
|
||||
|
@ -208,7 +164,49 @@
|
|||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
the sink's name
|
||||
Name.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Sink:GetPosition"></a>
|
||||
<strong>Sink:GetPosition()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this sink's world position.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
World position.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Sink:GetStrength"></a>
|
||||
<strong>Sink:GetStrength()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this sink's strength.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
Strength.
|
||||
</ol>
|
||||
|
||||
|
||||
|
@ -220,7 +218,7 @@
|
|||
<strong>Sink:SetName(name)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the sink's name (its unique string identifier)
|
||||
Set this sink's unique string identifier.
|
||||
|
||||
|
||||
|
||||
|
@ -228,7 +226,7 @@
|
|||
<ul>
|
||||
<li><span class="parameter">name</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
The sink's new name
|
||||
New name.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
@ -238,21 +236,22 @@
|
|||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Sink:GetStrength"></a>
|
||||
<strong>Sink:GetStrength()</strong>
|
||||
<a name = "Sink:SetPosition"></a>
|
||||
<strong>Sink:SetPosition(pos)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the sink's strength
|
||||
Set this sink's world position.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
New world position.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
the sink's current strength
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
@ -263,8 +262,8 @@
|
|||
<strong>Sink:SetStrength(strength)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the strength of the sink
|
||||
Higher numbers provide stronger currents. Will be clamped to [1, 32].
|
||||
Set this sink's strength.
|
||||
Higher numbers provide stronger currents. Clamped to the range [1, 32].
|
||||
|
||||
|
||||
|
||||
|
@ -272,7 +271,7 @@
|
|||
<ul>
|
||||
<li><span class="parameter">strength</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
The sink's new strength
|
||||
New strength.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -107,7 +109,7 @@
|
|||
<div id="content">
|
||||
|
||||
<h1>Class <code>Objects.Static</code></h1>
|
||||
<p>Statics</p>
|
||||
<p>Represents a static object in the game world.</p>
|
||||
<p>
|
||||
|
||||
</p>
|
||||
|
@ -115,88 +117,85 @@
|
|||
|
||||
<h2><a href="#Functions">Functions</a></h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:Enable">Static:Enable()</a></td>
|
||||
<td class="summary">Enable the static, for cases when it was shattered or manually disabled before.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:Disable">Static:Disable()</a></td>
|
||||
<td class="summary">Disable the static</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetActive">Static:GetActive()</a></td>
|
||||
<td class="summary">Get static mesh visibility</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetSolid">Static:GetSolid()</a></td>
|
||||
<td class="summary">Get static mesh solid collision state</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetSolid">Static:SetSolid(solidState)</a></td>
|
||||
<td class="summary">Set static mesh solid collision state</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetPosition">Static:GetPosition()</a></td>
|
||||
<td class="summary">Get the static's position</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetPosition">Static:SetPosition(position)</a></td>
|
||||
<td class="summary">Set the static's position</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetRotation">Static:GetRotation()</a></td>
|
||||
<td class="summary">Get the static's rotation</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetRotation">Static:SetRotation(rotation)</a></td>
|
||||
<td class="summary">Set the static's rotation</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetScale">Static:GetScale()</a></td>
|
||||
<td class="summary">Get the static's scale</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetScale">Static:SetScale(scale)</a></td>
|
||||
<td class="summary">Set the static's scale</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetHP">Static:GetHP()</a></td>
|
||||
<td class="summary">Get current HP (hit points/health points)
|
||||
Used only with shatterable static meshes.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetHP">Static:SetHP(HP)</a></td>
|
||||
<td class="summary">Set current HP (hit points/health points)
|
||||
Used only with shatterable static meshes.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetName">Static:GetName()</a></td>
|
||||
<td class="summary">Get the static's unique string identifier</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetName">Static:SetName(name)</a></td>
|
||||
<td class="summary">Set the static's name (its unique string identifier)
|
||||
e.g.</td>
|
||||
<td class="summary">Get this static's unique string identifier.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetSlot">Static:GetSlot()</a></td>
|
||||
<td class="summary">Get the static's slot number (as listed in Tomb Editor and WadTool)</td>
|
||||
<td class="summary">Get this static's slot ID.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetSlot">Static:SetSlot(slot)</a></td>
|
||||
<td class="summary">Set the static's slot number (as listed in Tomb Editor and WadTool)</td>
|
||||
<td class="name" ><a href="#Static:GetPosition">Static:GetPosition()</a></td>
|
||||
<td class="summary">Get this static's world position.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetRotation">Static:GetRotation()</a></td>
|
||||
<td class="summary">Get this static's world rotation.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetScale">Static:GetScale()</a></td>
|
||||
<td class="summary">Get this static's world scale.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetColor">Static:GetColor()</a></td>
|
||||
<td class="summary">Get the static's color</td>
|
||||
<td class="summary">Get this static's color.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetHP">Static:GetHP()</a></td>
|
||||
<td class="summary">Get this static's hit points.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetActive">Static:GetActive()</a></td>
|
||||
<td class="summary">Get this static's visibility status.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:GetSolid">Static:GetSolid()</a></td>
|
||||
<td class="summary">Get this static's solid collision status.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetName">Static:SetName(name)</a></td>
|
||||
<td class="summary">Set this static's unique identifier string.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetSlot">Static:SetSlot(slotID)</a></td>
|
||||
<td class="summary">Set this static's slot ID.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetPosition">Static:SetPosition(pos)</a></td>
|
||||
<td class="summary">Set this static's world position.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetRotation">Static:SetRotation(rot)</a></td>
|
||||
<td class="summary">Set this static's rotation.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetScale">Static:SetScale(scale)</a></td>
|
||||
<td class="summary">Set this static's world scale.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetColor">Static:SetColor(color)</a></td>
|
||||
<td class="summary">Set the static's color</td>
|
||||
<td class="summary">Set this static's color.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetHP">Static:SetHP(hitPoints)</a></td>
|
||||
<td class="summary">Set this static's hit points.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:SetSolid">Static:SetSolid(status)</a></td>
|
||||
<td class="summary">Set this static's solid collision status.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:Enable">Static:Enable()</a></td>
|
||||
<td class="summary">Enable this static.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:Disable">Static:Disable()</a></td>
|
||||
<td class="summary">Disable this static.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Static:Shatter">Static:Shatter()</a></td>
|
||||
<td class="summary">Shatter static mesh</td>
|
||||
<td class="summary">Shatter this static.</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
@ -207,12 +206,377 @@
|
|||
<h2 class="section-header "><a name="Functions"></a>Functions</h2>
|
||||
|
||||
<dl class="function">
|
||||
<dt>
|
||||
<a name = "Static:GetName"></a>
|
||||
<strong>Static:GetName()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this static's unique string identifier.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
Name string.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetSlot"></a>
|
||||
<strong>Static:GetSlot()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this static's slot ID.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
Slot ID.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetPosition"></a>
|
||||
<strong>Static:GetPosition()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this static's world position.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
World position.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetRotation"></a>
|
||||
<strong>Static:GetRotation()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this static's world rotation.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Rotation.html#">Rotation</a></span>
|
||||
World rotation.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetScale"></a>
|
||||
<strong>Static:GetScale()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this static's world scale.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
World scale.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetColor"></a>
|
||||
<strong>Static:GetColor()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this static's color.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
Color.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetHP"></a>
|
||||
<strong>Static:GetHP()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this static's hit points. Used only with shatterable statics.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
Hit points.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetActive"></a>
|
||||
<strong>Static:GetActive()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this static's visibility status.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
Status. <strong>true: visible</strong>, <strong>false: invisible</strong>
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetSolid"></a>
|
||||
<strong>Static:GetSolid()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this static's solid collision status.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
Solid Status. <strong>true: solid</strong>, <strong>false: soft</strong>
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetName"></a>
|
||||
<strong>Static:SetName(name)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set this static's unique identifier string.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">name</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
New name.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetSlot"></a>
|
||||
<strong>Static:SetSlot(slotID)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set this static's slot ID.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">slotID</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
New slot ID.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetPosition"></a>
|
||||
<strong>Static:SetPosition(pos)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set this static's world position.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
New world position.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetRotation"></a>
|
||||
<strong>Static:SetRotation(rot)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set this static's rotation.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Rotation.html#">Rotation</a></span>
|
||||
New rotation.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetScale"></a>
|
||||
<strong>Static:SetScale(scale)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set this static's world scale.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">scale</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
New world scale.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetColor"></a>
|
||||
<strong>Static:SetColor(color)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set this static's color.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">color</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
New color.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetHP"></a>
|
||||
<strong>Static:SetHP(hitPoints)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set this static's hit points. Used only with shatterable statics.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">hitPoints</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
New hit points.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetSolid"></a>
|
||||
<strong>Static:SetSolid(status)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set this static's solid collision status.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">status</span>
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
New status. <strong>true: solid</strong>, <strong>false: soft</strong>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:Enable"></a>
|
||||
<strong>Static:Enable()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Enable the static, for cases when it was shattered or manually disabled before.
|
||||
Enable this static. Used when previously shattered disabled manually.
|
||||
|
||||
|
||||
|
||||
|
@ -227,7 +591,7 @@
|
|||
<strong>Static:Disable()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Disable the static
|
||||
Disable this static.
|
||||
|
||||
|
||||
|
||||
|
@ -236,381 +600,13 @@
|
|||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetActive"></a>
|
||||
<strong>Static:GetActive()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get static mesh visibility
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
visibility state
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetSolid"></a>
|
||||
<strong>Static:GetSolid()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get static mesh solid collision state
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
solid collision state (true if solid, false if soft)
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetSolid"></a>
|
||||
<strong>Static:SetSolid(solidState)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set static mesh solid collision state
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">solidState</span>
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
if set, collision will be solid, if not, will be soft
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetPosition"></a>
|
||||
<strong>Static:GetPosition()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the static's position
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
a copy of the static's position
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetPosition"></a>
|
||||
<strong>Static:SetPosition(position)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the static's position
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">position</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
the new position of the static
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetRotation"></a>
|
||||
<strong>Static:GetRotation()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the static's rotation
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Rotation.html#">Rotation</a></span>
|
||||
a copy of the static's rotation
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetRotation"></a>
|
||||
<strong>Static:SetRotation(rotation)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the static's rotation
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">rotation</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Rotation.html#">Rotation</a></span>
|
||||
the static's new rotation
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetScale"></a>
|
||||
<strong>Static:GetScale()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the static's scale
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
current static scale
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetScale"></a>
|
||||
<strong>Static:SetScale(scale)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the static's scale
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">scale</span>
|
||||
<span class="types"><span class="type">Scale</span></span>
|
||||
the static's new scale
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetHP"></a>
|
||||
<strong>Static:GetHP()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get current HP (hit points/health points)
|
||||
Used only with shatterable static meshes.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
the amount of HP the static currently has
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetHP"></a>
|
||||
<strong>Static:SetHP(HP)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set current HP (hit points/health points)
|
||||
Used only with shatterable static meshes.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">HP</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
the amount of HP to give the static
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetName"></a>
|
||||
<strong>Static:GetName()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the static's unique string identifier
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
the static's name
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetName"></a>
|
||||
<strong>Static:SetName(name)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the static's name (its unique string identifier)
|
||||
e.g. "my_vase" or "oldrubble"
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">name</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
The static's new name
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetSlot"></a>
|
||||
<strong>Static:GetSlot()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the static's slot number (as listed in Tomb Editor and WadTool)
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
the static's slot number
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetSlot"></a>
|
||||
<strong>Static:SetSlot(slot)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the static's slot number (as listed in Tomb Editor and WadTool)
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">slot</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
The static's slot number
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:GetColor"></a>
|
||||
<strong>Static:GetColor()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the static's color
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
a copy of the static's color
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:SetColor"></a>
|
||||
<strong>Static:SetColor(color)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the static's color
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">color</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
the new color of the static
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Static:Shatter"></a>
|
||||
<strong>Static:Shatter()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Shatter static mesh
|
||||
Shatter this static.
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -108,7 +110,7 @@
|
|||
|
||||
<h1>Primitive Class <code>Color</code></h1>
|
||||
<p>Represents an RGBA or RGB color.</p>
|
||||
<p> Components are specified in bytes. All values are clamped to the range [0, 255].</p>
|
||||
<p> Components are specified as values clamped to the range [0, 255].</p>
|
||||
|
||||
|
||||
<h2><a href="#Members">Members</a></h2>
|
||||
|
@ -278,7 +280,7 @@
|
|||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
A string representing the r, g, b, and a values of the color.
|
||||
A string representing R, G, B, and A values.
|
||||
</ol>
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -107,7 +109,7 @@
|
|||
<div id="content">
|
||||
|
||||
<h1>Primitive Class <code>Flow.LensFlare</code></h1>
|
||||
<p>Represents a global lens flare (not to be confused with lensflare object).</p>
|
||||
<p>Represents a global lens flare (not to be confused with the lens flare object).</p>
|
||||
<p>
|
||||
|
||||
</p>
|
||||
|
@ -120,40 +122,40 @@
|
|||
<td class="summary">Create a LensFlare object.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LensFlare:GetEnabled">LensFlare:GetEnabled()</a></td>
|
||||
<td class="summary">Get the lens flare's enabled status.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LensFlare:GetSunSpriteID">LensFlare:GetSunSpriteID()</a></td>
|
||||
<td class="summary">Get the sun's sprite ID.</td>
|
||||
<td class="summary">Get this lens flare's sun sprite ID.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LensFlare:GetPitch">LensFlare:GetPitch()</a></td>
|
||||
<td class="summary">Get the lens flare's pitch angle in degrees.</td>
|
||||
<td class="summary">Get this lens flare's pitch angle in degrees.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LensFlare:GetYaw">LensFlare:GetYaw()</a></td>
|
||||
<td class="summary">Get the lens flare's yaw angle in degrees.</td>
|
||||
<td class="summary">Get this lens flare's yaw angle in degrees.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LensFlare:SetColor">LensFlare:SetColor()</a></td>
|
||||
<td class="name" ><a href="#LensFlare:GetColor">LensFlare:GetColor()</a></td>
|
||||
<td class="summary">Get the lens flare's color.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LensFlare:GetEnabled">LensFlare:GetEnabled()</a></td>
|
||||
<td class="summary">Get this lens flare's enabled status.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LensFlare:SetSunSpriteID">LensFlare:SetSunSpriteID(New)</a></td>
|
||||
<td class="summary">Set the lens flare's sun sprite ID.</td>
|
||||
<td class="summary">Set this lens flare's sun sprite ID.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LensFlare:SetPitch">LensFlare:SetPitch(New)</a></td>
|
||||
<td class="summary">Set the lens flare's pitch angle.</td>
|
||||
<td class="summary">Set this lens flare's pitch angle.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LensFlare:SetYaw">LensFlare:SetYaw(New)</a></td>
|
||||
<td class="summary">Set the lens flare's yaw angle.</td>
|
||||
<td class="summary">Set this lens flare's yaw angle.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#LensFlare:SetColor">LensFlare:SetColor(New)</a></td>
|
||||
<td class="summary">Set the lens flare's color.</td>
|
||||
<td class="summary">Set this lens flare's color.</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
@ -169,7 +171,7 @@
|
|||
<strong>LensFlare(Pitch, Yaw, Color.)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Create a LensFlare object. ()
|
||||
Create a LensFlare object.
|
||||
|
||||
|
||||
|
||||
|
@ -201,34 +203,13 @@
|
|||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "LensFlare:GetEnabled"></a>
|
||||
<strong>LensFlare:GetEnabled()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the lens flare's enabled status. ()
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
Lens flare's enabled status.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "LensFlare:GetSunSpriteID"></a>
|
||||
<strong>LensFlare:GetSunSpriteID()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the sun's sprite ID. ()
|
||||
Get this lens flare's sun sprite ID.
|
||||
|
||||
|
||||
|
||||
|
@ -249,7 +230,7 @@
|
|||
<strong>LensFlare:GetPitch()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the lens flare's pitch angle in degrees. ()
|
||||
Get this lens flare's pitch angle in degrees.
|
||||
|
||||
|
||||
|
||||
|
@ -270,7 +251,7 @@
|
|||
<strong>LensFlare:GetYaw()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the lens flare's yaw angle in degrees. ()
|
||||
Get this lens flare's yaw angle in degrees.
|
||||
|
||||
|
||||
|
||||
|
@ -287,11 +268,11 @@
|
|||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "LensFlare:SetColor"></a>
|
||||
<strong>LensFlare:SetColor()</strong>
|
||||
<a name = "LensFlare:GetColor"></a>
|
||||
<strong>LensFlare:GetColor()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the lens flare's color. ()
|
||||
Get the lens flare's color.
|
||||
|
||||
|
||||
|
||||
|
@ -300,13 +281,34 @@
|
|||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "LensFlare:GetEnabled"></a>
|
||||
<strong>LensFlare:GetEnabled()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this lens flare's enabled status.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
Enabled status. <strong>true: enabled</strong>, <strong>false: disabled</strong>
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "LensFlare:SetSunSpriteID"></a>
|
||||
<strong>LensFlare:SetSunSpriteID(New)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the lens flare's sun sprite ID. ()
|
||||
Set this lens flare's sun sprite ID.
|
||||
|
||||
|
||||
|
||||
|
@ -314,7 +316,7 @@
|
|||
<ul>
|
||||
<li><span class="parameter">New</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
sprite ID.
|
||||
sun sprite ID.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
@ -328,7 +330,7 @@
|
|||
<strong>LensFlare:SetPitch(New)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the lens flare's pitch angle. (float)
|
||||
Set this lens flare's pitch angle.
|
||||
|
||||
|
||||
|
||||
|
@ -350,7 +352,7 @@
|
|||
<strong>LensFlare:SetYaw(New)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the lens flare's yaw angle. (float)
|
||||
Set this lens flare's yaw angle.
|
||||
|
||||
|
||||
|
||||
|
@ -372,7 +374,7 @@
|
|||
<strong>LensFlare:SetColor(New)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the lens flare's color. (Color)
|
||||
Set this lens flare's color.
|
||||
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -107,7 +109,7 @@
|
|||
<div id="content">
|
||||
|
||||
<h1>Primitive Class <code>Flow.Starfield</code></h1>
|
||||
<p>Represents a starfield.</p>
|
||||
<p>Represents a starfield in the sky.</p>
|
||||
<p>
|
||||
|
||||
</p>
|
||||
|
@ -124,44 +126,44 @@
|
|||
<td class="summary">Create a starfield object with stars and meteors.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:GetStarsEnabled">Starfield:GetStarsEnabled()</a></td>
|
||||
<td class="summary">Get the starfield's enabled status of stars.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:GetMeteorsEnabled">Starfield:GetMeteorsEnabled()</a></td>
|
||||
<td class="summary">Get the starfield's enabled status of meteors.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:GetStarCount">Starfield:GetStarCount()</a></td>
|
||||
<td class="summary">Get the starfield's number of stars.</td>
|
||||
<td class="summary">Get this starfield's number of stars.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:GetMeteorCount">Starfield:GetMeteorCount()</a></td>
|
||||
<td class="summary">Get the starfield's number of meteors.</td>
|
||||
<td class="summary">Get this starfield's number of meteors.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:GetMeteorSpawnDensity">Starfield:GetMeteorSpawnDensity()</a></td>
|
||||
<td class="summary">Get the starfield's meteor spawn density.</td>
|
||||
<td class="summary">Get this starfield's meteor spawn density.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:GetMeteorVelocity">Starfield:GetMeteorVelocity()</a></td>
|
||||
<td class="summary">Get the starfield's meteor velocity.</td>
|
||||
<td class="summary">Get this starfield's meteor velocity.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:GetStarsEnabled">Starfield:GetStarsEnabled()</a></td>
|
||||
<td class="summary">Get this starfield's stars enabled status.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:GetMeteorsEnabled">Starfield:GetMeteorsEnabled()</a></td>
|
||||
<td class="summary">Get this starfield's meteors enabled status.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:SetStarCount">Starfield:SetStarCount(New)</a></td>
|
||||
<td class="summary">Set the starfield's number of stars (6000 max).</td>
|
||||
<td class="summary">Set this starfield's number of stars.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:SetMeteorCount">Starfield:SetMeteorCount(New)</a></td>
|
||||
<td class="summary">Set the starfield's number of meteors (100 max).</td>
|
||||
<td class="summary">Set this starfield's number of meteors.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:SetMeteorSpawnDensity">Starfield:SetMeteorSpawnDensity(New)</a></td>
|
||||
<td class="summary">Set the starfield's meteor spawn density.</td>
|
||||
<td class="summary">Set this starfield's meteor spawn density.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Starfield:SetMeteorVelocity">Starfield:SetMeteorVelocity(New)</a></td>
|
||||
<td class="summary">Set the starfield's meteor velocity.</td>
|
||||
<td class="summary">Set this starfield's meteor velocity.</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
@ -177,7 +179,7 @@
|
|||
<strong>Starfield(starCount)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Create a starfield object with only stars. ()
|
||||
Create a starfield object with only stars.
|
||||
|
||||
|
||||
|
||||
|
@ -205,7 +207,7 @@
|
|||
<strong>Starfield(starCount, meteorCount)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Create a starfield object with stars and meteors. ()
|
||||
Create a starfield object with stars and meteors.
|
||||
|
||||
|
||||
|
||||
|
@ -213,11 +215,11 @@
|
|||
<ul>
|
||||
<li><span class="parameter">starCount</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
Star count (6000 max).
|
||||
Star count. <strong>Max: 6000</strong>
|
||||
</li>
|
||||
<li><span class="parameter">meteorCount</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
Meteor count (100 max).
|
||||
Meteor count. <strong>Max: 100</strong>
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
@ -231,55 +233,13 @@
|
|||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Starfield:GetStarsEnabled"></a>
|
||||
<strong>Starfield:GetStarsEnabled()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the starfield's enabled status of stars. ()
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
Stars enabled status.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Starfield:GetMeteorsEnabled"></a>
|
||||
<strong>Starfield:GetMeteorsEnabled()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the starfield's enabled status of meteors. ()
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
Meteors enabled status.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Starfield:GetStarCount"></a>
|
||||
<strong>Starfield:GetStarCount()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the starfield's number of stars. ()
|
||||
Get this starfield's number of stars.
|
||||
|
||||
|
||||
|
||||
|
@ -300,7 +260,7 @@
|
|||
<strong>Starfield:GetMeteorCount()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the starfield's number of meteors. ()
|
||||
Get this starfield's number of meteors.
|
||||
|
||||
|
||||
|
||||
|
@ -321,7 +281,7 @@
|
|||
<strong>Starfield:GetMeteorSpawnDensity()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the starfield's meteor spawn density. ()
|
||||
Get this starfield's meteor spawn density.
|
||||
|
||||
|
||||
|
||||
|
@ -342,7 +302,7 @@
|
|||
<strong>Starfield:GetMeteorVelocity()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get the starfield's meteor velocity. ()
|
||||
Get this starfield's meteor velocity.
|
||||
|
||||
|
||||
|
||||
|
@ -357,13 +317,55 @@
|
|||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Starfield:GetStarsEnabled"></a>
|
||||
<strong>Starfield:GetStarsEnabled()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this starfield's stars enabled status.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
Stars enabled status. <strong>true: enabled</strong>, <strong>false: disabled</strong>
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Starfield:GetMeteorsEnabled"></a>
|
||||
<strong>Starfield:GetMeteorsEnabled()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get this starfield's meteors enabled status.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
Meteors enabled status. <strong>true: enabled</strong>, <strong>false: disabled</strong>
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Starfield:SetStarCount"></a>
|
||||
<strong>Starfield:SetStarCount(New)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the starfield's number of stars (6000 max). (int)
|
||||
Set this starfield's number of stars.
|
||||
|
||||
|
||||
|
||||
|
@ -371,7 +373,7 @@
|
|||
<ul>
|
||||
<li><span class="parameter">New</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
count.
|
||||
star count.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
@ -385,7 +387,7 @@
|
|||
<strong>Starfield:SetMeteorCount(New)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the starfield's number of meteors (100 max). (int)
|
||||
Set this starfield's number of meteors.
|
||||
|
||||
|
||||
|
||||
|
@ -393,7 +395,7 @@
|
|||
<ul>
|
||||
<li><span class="parameter">New</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
count.
|
||||
meteor count.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
@ -407,7 +409,7 @@
|
|||
<strong>Starfield:SetMeteorSpawnDensity(New)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the starfield's meteor spawn density. (int)
|
||||
Set this starfield's meteor spawn density.
|
||||
|
||||
|
||||
|
||||
|
@ -415,7 +417,7 @@
|
|||
<ul>
|
||||
<li><span class="parameter">New</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
spawn density.
|
||||
meteor spawn density.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
@ -429,15 +431,15 @@
|
|||
<strong>Starfield:SetMeteorVelocity(New)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Set the starfield's meteor velocity. (float)
|
||||
Set this starfield's meteor velocity.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">New</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
velocity.
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
meteor velocity.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -108,38 +110,36 @@
|
|||
|
||||
<h1>Primitive Class <code>Rotation</code></h1>
|
||||
<p>Represents a degree-based 3D rotation.</p>
|
||||
<p> All values are clamped to the range [0.0, 360.0].</p>
|
||||
<p> All angle components are in degrees clamped to the range [0.0, 360.0].</p>
|
||||
|
||||
|
||||
<h2><a href="#Members">Members</a></h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" ><a href="#x">x</a></td>
|
||||
<td class="summary">(float) X angle component.</td>
|
||||
<td class="summary">(float) X angle component in degrees.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#y">y</a></td>
|
||||
<td class="summary">(float) Y angle component.</td>
|
||||
<td class="summary">(float) Y angle component in degrees.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#z">z</a></td>
|
||||
<td class="summary">(float) Z angle component.</td>
|
||||
<td class="summary">(float) Z angle component in degrees.</td>
|
||||
</tr>
|
||||
</table>
|
||||
<h2><a href="#Functions">Functions</a></h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" ><a href="#Rotation">Rotation(x, y, z)</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
<td class="summary">Create a Rotation object.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Direction">Direction()</a></td>
|
||||
<td class="summary">Converts rotation to a direction normal.</td>
|
||||
<td class="summary">Get the normalized direction vector of this Rotation.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#__tostring">__tostring(rotation)</a></td>
|
||||
<td class="name" ><a href="#__tostring">__tostring(rot)</a></td>
|
||||
<td class="summary">
|
||||
|
||||
</td>
|
||||
|
@ -158,7 +158,7 @@
|
|||
<strong>x</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
(float) X angle component.
|
||||
(float) X angle component in degrees.
|
||||
|
||||
|
||||
|
||||
|
@ -173,7 +173,7 @@
|
|||
<strong>y</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
(float) Y angle component.
|
||||
(float) Y angle component in degrees.
|
||||
|
||||
|
||||
|
||||
|
@ -188,7 +188,7 @@
|
|||
<strong>z</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
(float) Z angle component.
|
||||
(float) Z angle component in degrees.
|
||||
|
||||
|
||||
|
||||
|
@ -207,9 +207,7 @@
|
|||
<strong>Rotation(x, y, z)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
||||
|
||||
Create a Rotation object.
|
||||
|
||||
|
||||
|
||||
|
@ -217,15 +215,15 @@
|
|||
<ul>
|
||||
<li><span class="parameter">x</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
X angle component.
|
||||
X angle component in degrees.
|
||||
</li>
|
||||
<li><span class="parameter">y</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Y angle component.
|
||||
Y angle component in degrees.
|
||||
</li>
|
||||
<li><span class="parameter">z</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Z angle component.
|
||||
Z angle component in degrees.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
@ -233,7 +231,7 @@
|
|||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Rotation.html#">Rotation</a></span>
|
||||
A Rotation.
|
||||
A new Rotation object.
|
||||
</ol>
|
||||
|
||||
|
||||
|
@ -245,7 +243,7 @@
|
|||
<strong>Direction()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Converts rotation to a direction normal.
|
||||
Get the normalized direction vector of this Rotation.
|
||||
|
||||
|
||||
|
||||
|
@ -254,7 +252,7 @@
|
|||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
resulting normal calculated from this rotation.
|
||||
Normalized direction vector.
|
||||
</ol>
|
||||
|
||||
|
||||
|
@ -263,7 +261,7 @@
|
|||
</dd>
|
||||
<dt>
|
||||
<a name = "__tostring"></a>
|
||||
<strong>__tostring(rotation)</strong>
|
||||
<strong>__tostring(rot)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
|
@ -274,9 +272,9 @@
|
|||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">rotation</span>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Rotation.html#">Rotation</a></span>
|
||||
this Rotation.
|
||||
This Rotation.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
@ -284,7 +282,7 @@
|
|||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
A string showing the X, Y, and Z angle components of the Rotation.
|
||||
A string showing the X, Y, and Z angle components of this Rotation.
|
||||
</ol>
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -143,6 +145,18 @@
|
|||
<td class="summary">Get a copy of this Vec2 normalized to length 1.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Translate">Translate(dir, dist)</a></td>
|
||||
<td class="summary">Get a copy of this Vec2 translated in the input Vec2 direction by the input distance.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Translate">Translate(rot, dist)</a></td>
|
||||
<td class="summary">Get a copy of this Vec2 translated in the direction of the input rotation in degrees by the input distance.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Translate">Translate(rot, relOffset)</a></td>
|
||||
<td class="summary">Get a copy of this Vec2 translated by an offset, where the input relative offset Vec2 is rotated according to the input rotation in degrees.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Vec2:Rotate">Vec2:Rotate(rot)</a></td>
|
||||
<td class="summary">Get a copy of this Vec2 rotated by the input rotation in degrees.</td>
|
||||
</tr>
|
||||
|
@ -317,6 +331,102 @@
|
|||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Translate"></a>
|
||||
<strong>Translate(dir, dist)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get a copy of this Vec2 translated in the input Vec2 direction by the input distance.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">dir</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
Direction vector. Normalized automatically to length 1.
|
||||
</li>
|
||||
<li><span class="parameter">dist</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Distance.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
Translated vector.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Translate"></a>
|
||||
<strong>Translate(rot, dist)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get a copy of this Vec2 translated in the direction of the input rotation in degrees by the input distance.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Rotation.html#">Rotation</a></span>
|
||||
Rotation in degrees defining the direction.
|
||||
</li>
|
||||
<li><span class="parameter">dist</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Distance.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
Translated vector.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Translate"></a>
|
||||
<strong>Translate(rot, relOffset)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get a copy of this Vec2 translated by an offset, where the input relative offset Vec2 is rotated according to the input rotation in degrees.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Rotation in degrees rotating the input relative offset vector.
|
||||
</li>
|
||||
<li><span class="parameter">relOffset</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
Relative offset vector before rotation.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
Translated vector.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Vec2:Rotate"></a>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -143,6 +145,18 @@
|
|||
<td class="summary">Get a copy of this Vec3 normalized to length 1.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Translate">Translate(dir, dist)</a></td>
|
||||
<td class="summary">Get a copy of this Vec3 translated in the input Vec3 direction by the input distance.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Translate">Translate(rot, dist)</a></td>
|
||||
<td class="summary">Get a copy of this Vec3 translated in the direction of the input Rotation object by the input distance.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Translate">Translate(rot, relOffset)</a></td>
|
||||
<td class="summary">Get a copy of this Vec3 translated by an offset, where the input relative offset Vec3 is rotated according to the input Rotation object.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#Vec3:Rotate">Vec3:Rotate(rot)</a></td>
|
||||
<td class="summary">Get a copy of this Vec3 rotated by the input Rotation object.</td>
|
||||
</tr>
|
||||
|
@ -312,6 +326,102 @@
|
|||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Translate"></a>
|
||||
<strong>Translate(dir, dist)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get a copy of this Vec3 translated in the input Vec3 direction by the input distance.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">dir</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
Direction vector. Normalized automatically to length 1.
|
||||
</li>
|
||||
<li><span class="parameter">dist</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Distance.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
Translated vector.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Translate"></a>
|
||||
<strong>Translate(rot, dist)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get a copy of this Vec3 translated in the direction of the input Rotation object by the input distance.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Rotation.html#">Rotation</a></span>
|
||||
Rotation object defining the direction.
|
||||
</li>
|
||||
<li><span class="parameter">dist</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
Distance.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
Translated vector.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Translate"></a>
|
||||
<strong>Translate(rot, relOffset)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Get a copy of this Vec3 translated by an offset, where the input relative offset Vec3 is rotated according to the input Rotation object.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Rotation.html#">Rotation</a></span>
|
||||
Rotation object rotating the input relative offset vector.
|
||||
</li>
|
||||
<li><span class="parameter">relOffset</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
Relative offset vector before rotation.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec3.html#">Vec3</a></span>
|
||||
Translated vector.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "Vec3:Rotate"></a>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -117,7 +119,7 @@
|
|||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" ><a href="#Effects.BlendID">Effects.BlendID</a></td>
|
||||
<td class="summary">Table of Effects.BlendID constants (for use with particles).</td>
|
||||
<td class="summary">Table of Effects.BlendID constants.</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
@ -134,17 +136,18 @@
|
|||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Table of Effects.BlendID constants (for use with particles). </p>
|
||||
<p>Table of Effects.BlendID constants. </p>
|
||||
|
||||
<ul>
|
||||
<li><code>OPAQUE</code></li>
|
||||
<li><code>ALPHATEST</code></li>
|
||||
<li><code>ALPHA_TEST</code></li>
|
||||
<li><code>ADDITIVE</code></li>
|
||||
<li><code>NO_DEPTH_TEST</code></li>
|
||||
<li><code>SUBTRACTIVE</code></li>
|
||||
<li><code>EXCLUDE</code></li>
|
||||
<li><code>SCREEN</code></li>
|
||||
<li><code>LIGHTEN</code></li>
|
||||
<li><code>ALPHABLEND</code></li>
|
||||
<li><code>ALPHA_BLEND</code></li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -135,15 +137,15 @@
|
|||
<dd>
|
||||
|
||||
<p>Table of Effects.EffectID constants.
|
||||
To be used with <a href="../2 classes/Objects.Moveable.html#Moveable:SetEffect">Objects.Moveable.SetEffect</a> and <a href="../2 classes/Objects.Moveable.html#Moveable:GetEffect">Objects.Moveable.GetEffect</a> functions.</p>
|
||||
To be used with <a href="../2 classes/Objects.Moveable.html#Moveable:SetEffect">Objects.Moveable.SetEffect</a> and <a href="../2 classes/Objects.Moveable.html#Moveable:GetEffect">Objects.Moveable.GetEffect</a> functions.</p>
|
||||
|
||||
<ul>
|
||||
<li><code>NONE</code></li>
|
||||
<li><code>FIRE</code></li>
|
||||
<li><code>SPARKS</code></li>
|
||||
<li><code>SMOKE</code></li>
|
||||
<li><code>ELECTRICIGNITE</code></li>
|
||||
<li><code>REDIGNITE</code></li>
|
||||
<li><code>ELECTRIC_IGNITE</code></li>
|
||||
<li><code>RED_IGNITE</code></li>
|
||||
<li><code>CADAVER</code></li>
|
||||
<li><code>CUSTOM</code></li>
|
||||
</ul>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<li> <here>Flow.GameStatus</here></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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<li> <a href="../4 enums/Flow.GameStatus.html">Flow.GameStatus</a></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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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> <here>Objects.AmmoType</here></li>
|
||||
<li> <a href="../4 enums/Objects.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -135,7 +137,7 @@
|
|||
<dd>
|
||||
|
||||
<p>Table of Objects.AmmoType constants.
|
||||
To be used with <a href="../2 classes/Objects.LaraObject.html#LaraObject:GetAmmoType">Objects.LaraObject.GetAmmoType</a> function.</p>
|
||||
To be used with <a href="../2 classes/Objects.LaraObject.html#LaraObject:GetAmmoType">Objects.LaraObject.GetAmmoType</a> function.</p>
|
||||
|
||||
<ul>
|
||||
<li><code>NONE</code></li>
|
||||
|
|
169
Documentation/doc/4 enums/Objects.HandStatus.html
Normal file
169
Documentation/doc/4 enums/Objects.HandStatus.html
Normal file
|
@ -0,0 +1,169 @@
|
|||
<!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.7.2 (Developer) 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/Flow.Level.html">Flow.Level</a></li>
|
||||
<li> <a href="../2 classes/Flow.Settings.html">Flow.Settings</a></li>
|
||||
<li> <a href="../2 classes/Flow.Statistics.html">Flow.Statistics</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>
|
||||
<li> <a href="../2 classes/View.DisplaySprite.html">View.DisplaySprite</a></li>
|
||||
</ul>
|
||||
<h2>3 Primitive Classes</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../3 primitive classes/Flow.Fog.html">Flow.Fog</a></li>
|
||||
<li> <a href="../3 primitive classes/Flow.InventoryItem.html">Flow.InventoryItem</a></li>
|
||||
<li> <a href="../3 primitive classes/Flow.LensFlare.html">Flow.LensFlare</a></li>
|
||||
<li> <a href="../3 primitive classes/Flow.SkyLayer.html">Flow.SkyLayer</a></li>
|
||||
<li> <a href="../3 primitive classes/Flow.Starfield.html">Flow.Starfield</a></li>
|
||||
<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/Time.html">Time</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.ErrorMode.html">Flow.ErrorMode</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> <here>Objects.HandStatus</here></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="content">
|
||||
|
||||
<h1>Enum <code>Objects.HandStatus</code></h1>
|
||||
<p>Constants for player hand statuses.</p>
|
||||
<p>
|
||||
|
||||
</p>
|
||||
|
||||
|
||||
<h2><a href="#Tables">Tables</a></h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" ><a href="#Objects.HandStatus">Objects.HandStatus</a></td>
|
||||
<td class="summary">Table of Objects.HandStatus constants.</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
|
||||
<h2 class="section-header "><a name="Tables"></a>Tables</h2>
|
||||
|
||||
<dl class="function">
|
||||
<dt>
|
||||
<a name = "Objects.HandStatus"></a>
|
||||
<strong>Objects.HandStatus</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Table of Objects.HandStatus constants.
|
||||
To be used with <a href="../2 classes/Objects.LaraObject.html#LaraObject:GetAmmoType">Objects.LaraObject.GetAmmoType</a> function.</p>
|
||||
|
||||
<ul>
|
||||
<li><code>FREE</code></li>
|
||||
<li><code>BUSY</code></li>
|
||||
<li><code>WEAPON_DRAW</code></li>
|
||||
<li><code>WEAPON_READY</code></li>
|
||||
<li><code>SPECIAL</code></li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</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>
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</a></li>
|
||||
<li> <here>Objects.MoveableStatus</here></li>
|
||||
<li> <a href="../4 enums/Objects.ObjID.html">Objects.ObjID</a></li>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -136,13 +138,13 @@
|
|||
|
||||
<p>Table of Objects.MoveableStatus constants. </p>
|
||||
|
||||
<p>To be used with <a href="../2 classes/Objects.Moveable.html#Moveable:GetStatus">Objects.Moveable.GetStatus</a> and <a href="../2 classes/Objects.Moveable.html#Moveable:SetStatus">Objects.Moveable.SetStatus</a> functions.</p>
|
||||
<p> To be used with <a href="../2 classes/Objects.Moveable.html#Moveable:GetStatus">Objects.Moveable.GetStatus</a> and <a href="../2 classes/Objects.Moveable.html#Moveable:SetStatus">Objects.Moveable.SetStatus</a> functions.</p>
|
||||
|
||||
<ul>
|
||||
<li><code>INACTIVE</code> - object was never activated.</li>
|
||||
<li><code>ACTIVE</code> - object is active.</li>
|
||||
<li><code>DEACTIVATED</code> - object was active before and was deactivated.</li>
|
||||
<li><code>INVISIBLE</code> - object is invisible.</li>
|
||||
<li><code>INACTIVE</code> - moveable is inactive (was never activated).</li>
|
||||
<li><code>ACTIVE</code> - moveable is active.</li>
|
||||
<li><code>DEACTIVATED</code> - moveable is deactivated (was previously active and later deactivated).</li>
|
||||
<li><code>INVISIBLE</code> - moveable is invisible.</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</a></li>
|
||||
<li> <a href="../4 enums/Objects.MoveableStatus.html">Objects.MoveableStatus</a></li>
|
||||
<li> <here>Objects.ObjID</here></li>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -1114,8 +1116,11 @@ AIR_BAR_TEXTURE
|
|||
DASH_BAR_TEXTURE
|
||||
SFX_BAR_TEXTURE
|
||||
SPEEDOMETER
|
||||
WATERFALL
|
||||
CUSTOM_BAR_GRAPHIC
|
||||
CUSTOM_AMMO_GRAPHIC
|
||||
DIARY_SPRITES
|
||||
DIARY_ENTRY_SPRITES
|
||||
|
||||
PANEL_BORDER
|
||||
PANEL_MIDDLE
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <here>Objects.WeaponType</here></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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -117,7 +119,7 @@
|
|||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" ><a href="#Objects.WeaponType">Objects.WeaponType</a></td>
|
||||
<td class="summary">Objects.WeaponType constants.</td>
|
||||
<td class="summary">Table of Objects.WeaponType constants.</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
@ -134,10 +136,10 @@
|
|||
</dt>
|
||||
<dd>
|
||||
|
||||
<p>Objects.WeaponType constants. To be used with <a href="../2 classes/Objects.LaraObject.html#LaraObject:GetWeaponType">Objects.LaraObject.GetWeaponType</a> and <a href="../2 classes/Objects.LaraObject.html#LaraObject:SetWeaponType">Objects.LaraObject.SetWeaponType</a> functions.</p>
|
||||
<p>Table of Objects.WeaponType constants.
|
||||
To be used with <a href="../2 classes/Objects.LaraObject.html#LaraObject:GetWeaponType">Objects.LaraObject.GetWeaponType</a> and <a href="../2 classes/Objects.LaraObject.html#LaraObject:SetWeaponType">Objects.LaraObject.SetWeaponType</a> functions.</p>
|
||||
|
||||
<p> Note that this enumeration also contains flare and torch - these are counted as "weapon" internally by the engine, and indicate
|
||||
an object that is currently in Lara's hands.</p>
|
||||
<p> Note that this table also contains the flare and torch, as they are internally counted as "weapons" the engine.</p>
|
||||
|
||||
<ul>
|
||||
<li><code>NONE</code></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
983
Documentation/doc/5 lua utility modules/Diary.html
Normal file
983
Documentation/doc/5 lua utility modules/Diary.html
Normal file
|
@ -0,0 +1,983 @@
|
|||
<!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.7.2 (Developer) 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/Flow.Level.html">Flow.Level</a></li>
|
||||
<li> <a href="../2 classes/Flow.Settings.html">Flow.Settings</a></li>
|
||||
<li> <a href="../2 classes/Flow.Statistics.html">Flow.Statistics</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>
|
||||
<li> <a href="../2 classes/View.DisplaySprite.html">View.DisplaySprite</a></li>
|
||||
</ul>
|
||||
<h2>3 Primitive Classes</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../3 primitive classes/Flow.Fog.html">Flow.Fog</a></li>
|
||||
<li> <a href="../3 primitive classes/Flow.InventoryItem.html">Flow.InventoryItem</a></li>
|
||||
<li> <a href="../3 primitive classes/Flow.LensFlare.html">Flow.LensFlare</a></li>
|
||||
<li> <a href="../3 primitive classes/Flow.SkyLayer.html">Flow.SkyLayer</a></li>
|
||||
<li> <a href="../3 primitive classes/Flow.Starfield.html">Flow.Starfield</a></li>
|
||||
<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/Time.html">Time</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.ErrorMode.html">Flow.ErrorMode</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.WeaponType.html">Objects.WeaponType</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> <here>Diary</here></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
<div id="content">
|
||||
|
||||
<h1>Lua utility module <code>Diary</code></h1>
|
||||
<p>Diaries:
|
||||
The module provides functions to create and manage Diaries.</p>
|
||||
<p>
|
||||
<p> It maintains diary definitions and entries through all levels and hubs.
|
||||
Each diary is accessed by the object that was used to create it. </p>
|
||||
|
||||
<p> Example usage:</p>
|
||||
|
||||
|
||||
<pre>
|
||||
<span class="keyword">local</span> CustomDiary = <span class="global">require</span>(<span class="string">"Engine.CustomDiary"</span>)
|
||||
|
||||
<span class="comment">--This function creates a diary from the DiarySetup.lua template file in script folder
|
||||
</span>CustomDiary.ImportDiary(<span class="string">"DiarySetup"</span>)
|
||||
|
||||
<span class="comment">--This method gets the diary that was created with the DIARY_ITEM object and stores it in variable diary.
|
||||
</span><span class="keyword">local</span> diary = CustomDiary.Get(TEN.Objects.ObjID.DIARY_ITEM)
|
||||
<span class="comment">--This method opens the diary on the 3rd page
|
||||
</span>diary:showDiary(<span class="number">3</span>)
|
||||
</pre>
|
||||
|
||||
</p>
|
||||
|
||||
|
||||
<h2><a href="#Functions">Functions</a></h2>
|
||||
<table class="function_list">
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary.ImportDiary">CustomDiary.ImportDiary(fileName)</a></td>
|
||||
<td class="summary">Imports diary from an external file.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary.Create">CustomDiary.Create(object, objectIdBg, spriteIdBg, colorBg, pos, rot, scale, alignMode, scaleMode, blendMode, alpha, pageSound, exitSound)</a></td>
|
||||
<td class="summary">Creates a diary with extensive configuration options.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary.Get">CustomDiary.Get(object)</a></td>
|
||||
<td class="summary">The function retrieves a diary by its unique object.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary.Delete">CustomDiary.Delete(object)</a></td>
|
||||
<td class="summary">The function removes a custom diary and its associated data from the system.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary.Status">CustomDiary.Status(value)</a></td>
|
||||
<td class="summary">The function adds the callback to enable diaries in levels.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:IsVisible">CustomDiary:IsVisible()</a></td>
|
||||
<td class="summary">The function checks whether the specified diary is currently visible.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:ShowDiary">CustomDiary:ShowDiary(pageIndex)</a></td>
|
||||
<td class="summary">The function displays the specified diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:GetUnlockedPageCount">CustomDiary:GetUnlockedPageCount()</a></td>
|
||||
<td class="summary">The function returns the number of unlocked pages in the diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:UnlockPages">CustomDiary:UnlockPages(pageIndex, notification)</a></td>
|
||||
<td class="summary">The function unlocks the specified diary up to the given page number.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:ClearPage">CustomDiary:ClearPage(pageIndex)</a></td>
|
||||
<td class="summary">The function clears the page for the diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:AddTextEntry">CustomDiary:AddTextEntry(pageIndex, text, textPos, textOptions, textScale, textColor)</a></td>
|
||||
<td class="summary">Adds a text entry to the specified page for the diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:AddImageEntry">CustomDiary:AddImageEntry(pageIndex, objectId, spriteId, color, pos, rot, scale, alignMode, scaleMode, blendMode)</a></td>
|
||||
<td class="summary">Adds an image entry to the specified page for the diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:AddNarration">CustomDiary:AddNarration(pageIndex, trackName)</a></td>
|
||||
<td class="summary">Add a narration track in the voice channel to the page.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:RemoveNarration">CustomDiary:RemoveNarration(pageIndex)</a></td>
|
||||
<td class="summary">Remove the narration track from the page of the specified diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:AddBackground">CustomDiary:AddBackground(objectId, spriteId, color, pos, rot, scale, alignMode, scaleMode, blendMode, alpha)</a></td>
|
||||
<td class="summary">Add a background image for the diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:ClearBackground">CustomDiary:ClearBackground()</a></td>
|
||||
<td class="summary">Clears settings for the background for the specified diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:CustomizeNotification">CustomDiary:CustomizeNotification(notificationTime, objectId, spriteId, color, pos, rot, scale, alignMode, scaleMode, blendMode, notificationSound)</a></td>
|
||||
<td class="summary">Customizes the notification icon and sound for the diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:ClearNotification">CustomDiary:ClearNotification()</a></td>
|
||||
<td class="summary">Clears settings for the notification system for the specified diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:CustomizePageNumbers">CustomDiary:CustomizePageNumbers(pageNoType, prefix, separator, textPos, textOptions, textScale, textColor)</a></td>
|
||||
<td class="summary">Customizes the page numbers for the diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:ClearPageNumbers">CustomDiary:ClearPageNumbers()</a></td>
|
||||
<td class="summary">Clears settings for the page numbers for the specified diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:CustomizeControls">CustomDiary:CustomizeControls(textPos, textOptions, textScale, textColor)</a></td>
|
||||
<td class="summary">Customizes the controls text for the diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:CustomizeControlsText">CustomDiary:CustomizeControlsText(string1, string2, string3, string4, separator)</a></td>
|
||||
<td class="summary">Customizes the display text for controls for specified diary.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="#CustomDiary:ClearControls">CustomDiary:ClearControls()</a></td>
|
||||
<td class="summary">Clears settings for the specified diary's controls text.</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
<br/>
|
||||
<br/>
|
||||
|
||||
|
||||
<h2 class="section-header "><a name="Functions"></a>Functions</h2>
|
||||
|
||||
<dl class="function">
|
||||
<dt>
|
||||
<a name = "CustomDiary.ImportDiary"></a>
|
||||
<strong>CustomDiary.ImportDiary(fileName)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Imports diary from an external file. There are different types that must be defined. (diary, background, controls, pageNumbers, notification, image, text, narration). Each of the section's arguements are the same as the functions described in this documentation.
|
||||
Refer to DiarySetup.lua file for a sample script.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">fileName</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
Name of file in the script folder without extension to import the diary from.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary.Create"></a>
|
||||
<strong>CustomDiary.Create(object, objectIdBg, spriteIdBg, colorBg, pos, rot, scale, alignMode, scaleMode, blendMode, alpha, pageSound, exitSound)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Creates a diary with extensive configuration options.
|
||||
Parameters:
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">object</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Objects.ObjID.html#">ObjID</a></span>
|
||||
The pickup object that will be used to create the diary. The diary can be created using PICKUP<em>ITEMX (596-611) or DIARY</em>ITEM (986). Access the diary by selecting the item in the inventory.
|
||||
</li>
|
||||
<li><span class="parameter">objectIdBg</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Objects.ObjID.html#">ObjID</a></span>
|
||||
Object ID for the diary's sprite.
|
||||
</li>
|
||||
<li><span class="parameter">spriteIdBg</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
SpriteID from the specified object for the diary's sprite.
|
||||
</li>
|
||||
<li><span class="parameter">colorBg</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
Color of diary's sprite.
|
||||
</li>
|
||||
<li><span class="parameter">pos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y position of the bar's background in screen percent (0-100).
|
||||
</li>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
rotation of the diary's sprite (0-360).
|
||||
</li>
|
||||
<li><span class="parameter">scale</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y Scaling factor for the bar's background sprite.
|
||||
</li>
|
||||
<li><span class="parameter">alignMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/View.AlignMode.html#">AlignMode</a></span>
|
||||
Alignment for the diary's sprite.
|
||||
</li>
|
||||
<li><span class="parameter">scaleMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/View.ScaleMode.html#">ScaleMode</a></span>
|
||||
Scaling for the diary's sprite.
|
||||
</li>
|
||||
<li><span class="parameter">blendMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Effects.BlendID.html#">BlendID</a></span>
|
||||
Blending modes for the diary's sprite.
|
||||
</li>
|
||||
<li><span class="parameter">alpha</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
alpha value for the diary's sprite (0-255).
|
||||
</li>
|
||||
<li><span class="parameter">pageSound</span>
|
||||
<span class="types"><a class="type" href="../1 modules/Sound.html#">Sound</a></span>
|
||||
Sound to play with page turn.
|
||||
</li>
|
||||
<li><span class="parameter">exitSound</span>
|
||||
<span class="types"><a class="type" href="../1 modules/Sound.html#">Sound</a></span>
|
||||
Sound to play when existing the diary.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">CustomDiary</span></span>
|
||||
|
||||
|
||||
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary.Get"></a>
|
||||
<strong>CustomDiary.Get(object)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
The function retrieves a diary by its unique object. This function is useful when you need to access or manipulate a diary that has already been created .
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">object</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Objects.ObjID.html#">ObjID</a></span>
|
||||
The pickup object that was used to create the diary (596-611,986).
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">CustomDiary</span></span>
|
||||
The diary created using the object.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary.Delete"></a>
|
||||
<strong>CustomDiary.Delete(object)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
The function removes a custom diary and its associated data from the system. It ensures that the diary is no longer tracked or accessible in the LevelVars.Engine.Diaries.
|
||||
Please call this once a diary has served its purpose. It helps reduce the savegame size.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">object</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Objects.ObjID.html#">ObjID</a></span>
|
||||
The pickup object that was used to create the diary (596-611,986).
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary.Status"></a>
|
||||
<strong>CustomDiary.Status(value)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
The function adds the callback to enable diaries in levels. This needs to be added to every level preferably in the LevelFuncs.OnStart.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">value</span>
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
True enables the diaries to be activated. False would disable the diaries.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:IsVisible"></a>
|
||||
<strong>CustomDiary:IsVisible()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
The function checks whether the specified diary is currently visible.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
true if the diary is visible and false if it is not.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:ShowDiary"></a>
|
||||
<strong>CustomDiary:ShowDiary(pageIndex)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
The function displays the specified diary. Can be used to call the diary directly using volume or classic triggers.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pageIndex</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
The page number at which diary should be opened.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:GetUnlockedPageCount"></a>
|
||||
<strong>CustomDiary:GetUnlockedPageCount()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
The function returns the number of unlocked pages in the diary.
|
||||
|
||||
|
||||
|
||||
|
||||
<h3>Returns:</h3>
|
||||
<ol>
|
||||
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
total number of unlocked pages in the diary.
|
||||
</ol>
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:UnlockPages"></a>
|
||||
<strong>CustomDiary:UnlockPages(pageIndex, notification)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
The function unlocks the specified diary up to the given page number. <br/>
|
||||
This value can be overridden to lock or unlock pages as needed.
|
||||
A lower number can be set to restrict access to previously unlocked pages.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pageIndex</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
The page number up to which the diary should be unlocked.
|
||||
</li>
|
||||
<li><span class="parameter">notification</span>
|
||||
<span class="types"><span class="type">bool</span></span>
|
||||
If true, and notification has been defined, a notification icon and sound will be played.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:ClearPage"></a>
|
||||
<strong>CustomDiary:ClearPage(pageIndex)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
The function clears the page for the diary.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pageIndex</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
The page number to be cleared.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:AddTextEntry"></a>
|
||||
<strong>CustomDiary:AddTextEntry(pageIndex, text, textPos, textOptions, textScale, textColor)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Adds a text entry to the specified page for the diary.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pageIndex</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
page number to add the text entry to.
|
||||
</li>
|
||||
<li><span class="parameter">text</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
Text entry to be added to the page.
|
||||
</li>
|
||||
<li><span class="parameter">textPos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y position of the text.
|
||||
</li>
|
||||
<li><span class="parameter">textOptions</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Strings.DisplayStringOption.html#">DisplayStringOption</a></span>
|
||||
alignment and effects for the text. Default: None. Please note text is automatically aligned to the LEFT
|
||||
</li>
|
||||
<li><span class="parameter">textScale</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
Scale factor for the text.
|
||||
</li>
|
||||
<li><span class="parameter">textColor</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
Color of the text.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:AddImageEntry"></a>
|
||||
<strong>CustomDiary:AddImageEntry(pageIndex, objectId, spriteId, color, pos, rot, scale, alignMode, scaleMode, blendMode)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Adds an image entry to the specified page for the diary.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pageIndex</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
page number to add the image entry to.
|
||||
</li>
|
||||
<li><span class="parameter">objectId</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Objects.ObjID.html#">ObjID</a></span>
|
||||
Object ID for the image entry sprite.
|
||||
</li>
|
||||
<li><span class="parameter">spriteId</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
SpriteID from the specified object for the image entry.
|
||||
</li>
|
||||
<li><span class="parameter">color</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
Color of image entry.
|
||||
</li>
|
||||
<li><span class="parameter">pos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y position of the image entry in screen percent (0-100).
|
||||
</li>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
rotation of the image entry (0-360).
|
||||
</li>
|
||||
<li><span class="parameter">scale</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y Scaling factor for the image entry.
|
||||
</li>
|
||||
<li><span class="parameter">alignMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/View.AlignMode.html#">AlignMode</a></span>
|
||||
Alignment for the image entry.
|
||||
</li>
|
||||
<li><span class="parameter">scaleMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/View.ScaleMode.html#">ScaleMode</a></span>
|
||||
Scaling for the image entry.
|
||||
</li>
|
||||
<li><span class="parameter">blendMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Effects.BlendID.html#">BlendID</a></span>
|
||||
Blending modes for the image entry.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:AddNarration"></a>
|
||||
<strong>CustomDiary:AddNarration(pageIndex, trackName)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Add a narration track in the voice channel to the page. Track is played with the draw button.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pageIndex</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
page number to add the narration track to.
|
||||
</li>
|
||||
<li><span class="parameter">trackName</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.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:RemoveNarration"></a>
|
||||
<strong>CustomDiary:RemoveNarration(pageIndex)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Remove the narration track from the page of the specified diary.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pageIndex</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
page number to remove the narration track from.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:AddBackground"></a>
|
||||
<strong>CustomDiary:AddBackground(objectId, spriteId, color, pos, rot, scale, alignMode, scaleMode, blendMode, alpha)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Add a background image for the diary.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">objectId</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Objects.ObjID.html#">ObjID</a></span>
|
||||
Object ID for the diary's background.
|
||||
</li>
|
||||
<li><span class="parameter">spriteId</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
SpriteID from the specified object for the diary's background.
|
||||
</li>
|
||||
<li><span class="parameter">color</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
Color of diary's background.
|
||||
</li>
|
||||
<li><span class="parameter">pos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y position of the diary's background in screen percent (0-100).
|
||||
</li>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><span class="type">float</span></span>
|
||||
rotation of the diary's background sprite (0-360).
|
||||
</li>
|
||||
<li><span class="parameter">scale</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y Scaling factor for the diary's background.
|
||||
</li>
|
||||
<li><span class="parameter">alignMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/View.AlignMode.html#">AlignMode</a></span>
|
||||
Alignment for the diary's background.
|
||||
</li>
|
||||
<li><span class="parameter">scaleMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/View.ScaleMode.html#">ScaleMode</a></span>
|
||||
Scaling for the diary's background.
|
||||
</li>
|
||||
<li><span class="parameter">blendMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Effects.BlendID.html#">BlendID</a></span>
|
||||
Blending modes for the diary's background.
|
||||
</li>
|
||||
<li><span class="parameter">alpha</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
alpha value for the diary's background (0-255).
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:ClearBackground"></a>
|
||||
<strong>CustomDiary:ClearBackground()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Clears settings for the background for the specified diary.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:CustomizeNotification"></a>
|
||||
<strong>CustomDiary:CustomizeNotification(notificationTime, objectId, spriteId, color, pos, rot, scale, alignMode, scaleMode, blendMode, notificationSound)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Customizes the notification icon and sound for the diary.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">notificationTime</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
Time in seconds the notification icon will show on screen.
|
||||
</li>
|
||||
<li><span class="parameter">objectId</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Objects.ObjID.html#">ObjID</a></span>
|
||||
Object ID for the notification icon.
|
||||
</li>
|
||||
<li><span class="parameter">spriteId</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
SpriteID from the specified object for the notification icon.
|
||||
</li>
|
||||
<li><span class="parameter">color</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
Color of notification icon.
|
||||
</li>
|
||||
<li><span class="parameter">pos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y position of the notification icon in screen percent (0-100).
|
||||
</li>
|
||||
<li><span class="parameter">rot</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
rotation of the notification icon (0-360).
|
||||
</li>
|
||||
<li><span class="parameter">scale</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y Scaling factor for the notification icon.
|
||||
</li>
|
||||
<li><span class="parameter">alignMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/View.AlignMode.html#">AlignMode</a></span>
|
||||
Alignment for the notification icon.
|
||||
</li>
|
||||
<li><span class="parameter">scaleMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/View.ScaleMode.html#">ScaleMode</a></span>
|
||||
Scaling for the notification icon.
|
||||
</li>
|
||||
<li><span class="parameter">blendMode</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Effects.BlendID.html#">BlendID</a></span>
|
||||
Blending modes for the notification icon.
|
||||
</li>
|
||||
<li><span class="parameter">notificationSound</span>
|
||||
<span class="types"><a class="type" href="../1 modules/Sound.html#">Sound</a></span>
|
||||
Sound to play with notification icon.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:ClearNotification"></a>
|
||||
<strong>CustomDiary:ClearNotification()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Clears settings for the notification system for the specified diary.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:CustomizePageNumbers"></a>
|
||||
<strong>CustomDiary:CustomizePageNumbers(pageNoType, prefix, separator, textPos, textOptions, textScale, textColor)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Customizes the page numbers for the diary.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">pageNoType</span>
|
||||
<span class="types"><span class="type">int</span></span>
|
||||
Specifies the format for page numbers (1 or 2). 1: Displays only the current page number. 2: Formats the page number as: [Prefix][CurrentPage][Separator][UnlockedPages].
|
||||
</li>
|
||||
<li><span class="parameter">prefix</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
Prefix to be added for type 2 of page numbers.
|
||||
</li>
|
||||
<li><span class="parameter">separator</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
Separator to be added for type 2 of page numbers.
|
||||
</li>
|
||||
<li><span class="parameter">textPos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y position of the page numbers.
|
||||
</li>
|
||||
<li><span class="parameter">textOptions</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Strings.DisplayStringOption.html#">DisplayStringOption</a></span>
|
||||
alignment and effects for the text. Default: None. Please note text is automatically aligned to the LEFT
|
||||
</li>
|
||||
<li><span class="parameter">textScale</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
Scale factor for the page numbers.
|
||||
</li>
|
||||
<li><span class="parameter">textColor</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
Color of the page numbers.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:ClearPageNumbers"></a>
|
||||
<strong>CustomDiary:ClearPageNumbers()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Clears settings for the page numbers for the specified diary.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:CustomizeControls"></a>
|
||||
<strong>CustomDiary:CustomizeControls(textPos, textOptions, textScale, textColor)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Customizes the controls text for the diary.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">textPos</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Vec2.html#">Vec2</a></span>
|
||||
X,Y position of the controls text.
|
||||
</li>
|
||||
<li><span class="parameter">textOptions</span>
|
||||
<span class="types"><a class="type" href="../4 enums/Strings.DisplayStringOption.html#">DisplayStringOption</a></span>
|
||||
alignment and effects for the text. Default: None. Please note text is automatically aligned to the LEFT.
|
||||
</li>
|
||||
<li><span class="parameter">textScale</span>
|
||||
<span class="types"><span class="type">number</span></span>
|
||||
Scale factor for the controls.
|
||||
</li>
|
||||
<li><span class="parameter">textColor</span>
|
||||
<span class="types"><a class="type" href="../3 primitive classes/Color.html#">Color</a></span>
|
||||
Color of the page controls.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:CustomizeControlsText"></a>
|
||||
<strong>CustomDiary:CustomizeControlsText(string1, string2, string3, string4, separator)</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Customizes the display text for controls for specified diary.
|
||||
|
||||
|
||||
|
||||
<h3>Parameters:</h3>
|
||||
<ul>
|
||||
<li><span class="parameter">string1</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
Text for Space key controls text.
|
||||
</li>
|
||||
<li><span class="parameter">string2</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
Text for Left key controls text.
|
||||
</li>
|
||||
<li><span class="parameter">string3</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
Text for Right key controls text.
|
||||
</li>
|
||||
<li><span class="parameter">string4</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
Text for Esc key controls text.
|
||||
</li>
|
||||
<li><span class="parameter">separator</span>
|
||||
<span class="types"><a class="type" href="https://www.lua.org/manual/5.4/manual.html#6.4">string</a></span>
|
||||
Text for separator between controls text.
|
||||
</li>
|
||||
</ul>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</dd>
|
||||
<dt>
|
||||
<a name = "CustomDiary:ClearControls"></a>
|
||||
<strong>CustomDiary:ClearControls()</strong>
|
||||
</dt>
|
||||
<dd>
|
||||
Clears settings for the specified diary's controls text.
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</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>
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <here>EventSequence</here></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <here>Timer</here></li>
|
||||
<li> <a href="../5 lua utility modules/Type.html">Type</a></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="../ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="../4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="../5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="../5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="../5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <here>Type</here></li>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
<html>
|
||||
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
|
||||
<head>
|
||||
<title>TombEngine 1.7.1 Lua API</title>
|
||||
<title>TombEngine 1.7.2 (Developer) Lua API</title>
|
||||
<link rel="stylesheet" href="ldoc.css" type="text/css" />
|
||||
</head>
|
||||
<body>
|
||||
|
@ -82,6 +82,7 @@
|
|||
<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.HandStatus.html">Objects.HandStatus</a></li>
|
||||
<li> <a href="4 enums/Objects.WeaponType.html">Objects.WeaponType</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>
|
||||
|
@ -97,6 +98,7 @@
|
|||
</ul>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<ul class="nowrap">
|
||||
<li> <a href="5 lua utility modules/Diary.html">Diary</a></li>
|
||||
<li> <a href="5 lua utility modules/EventSequence.html">EventSequence</a></li>
|
||||
<li> <a href="5 lua utility modules/Timer.html">Timer</a></li>
|
||||
<li> <a href="5 lua utility modules/Type.html">Type</a></li>
|
||||
|
@ -107,7 +109,7 @@
|
|||
<div id="content">
|
||||
|
||||
|
||||
<h2>TombEngine 1.7.1 scripting interface</h2>
|
||||
<h2>TombEngine 1.7.2 (Developer) 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>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>
|
||||
|
@ -153,7 +155,7 @@ local door = GetMoveableByName("door_type4_14")
|
|||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="1 modules/Objects.html">Objects</a></td>
|
||||
<td class="summary">Moveables, statics, cameras, and so on.</td>
|
||||
<td class="summary">Objects including moveables, statics, cameras, and others.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="1 modules/Sound.html">Sound</a></td>
|
||||
|
@ -196,11 +198,11 @@ local door = GetMoveableByName("door_type4_14")
|
|||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="2 classes/Objects.LaraObject.html">Objects.LaraObject</a></td>
|
||||
<td class="summary">Class for extra Lara-only functions.</td>
|
||||
<td class="summary">Class for extra player-only functions.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="2 classes/Objects.Moveable.html">Objects.Moveable</a></td>
|
||||
<td class="summary">Represents any object inside the game world.</td>
|
||||
<td class="summary">Represents a moveable object in the game world.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="2 classes/Objects.Room.html">Objects.Room</a></td>
|
||||
|
@ -208,7 +210,7 @@ local door = GetMoveableByName("door_type4_14")
|
|||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="2 classes/Objects.Sink.html">Objects.Sink</a></td>
|
||||
<td class="summary">Sink</td>
|
||||
<td class="summary">Represents a sink object.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="2 classes/Objects.SoundSource.html">Objects.SoundSource</a></td>
|
||||
|
@ -216,7 +218,7 @@ local door = GetMoveableByName("door_type4_14")
|
|||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="2 classes/Objects.Static.html">Objects.Static</a></td>
|
||||
<td class="summary">Statics</td>
|
||||
<td class="summary">Represents a static object in the game world.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="2 classes/Objects.Volume.html">Objects.Volume</a></td>
|
||||
|
@ -243,7 +245,7 @@ local door = GetMoveableByName("door_type4_14")
|
|||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="3 primitive classes/Flow.LensFlare.html">Flow.LensFlare</a></td>
|
||||
<td class="summary">Represents a global lens flare (not to be confused with lensflare object).</td>
|
||||
<td class="summary">Represents a global lens flare (not to be confused with the lens flare object).</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="3 primitive classes/Flow.SkyLayer.html">Flow.SkyLayer</a></td>
|
||||
|
@ -251,7 +253,7 @@ local door = GetMoveableByName("door_type4_14")
|
|||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="3 primitive classes/Flow.Starfield.html">Flow.Starfield</a></td>
|
||||
<td class="summary">Represents a starfield.</td>
|
||||
<td class="summary">Represents a starfield in the sky.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="3 primitive classes/Color.html">Color</a></td>
|
||||
|
@ -304,6 +306,10 @@ local door = GetMoveableByName("door_type4_14")
|
|||
<td class="name" ><a href="4 enums/Objects.AmmoType.html">Objects.AmmoType</a></td>
|
||||
<td class="summary">Constants for player weapon ammo types.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="4 enums/Objects.HandStatus.html">Objects.HandStatus</a></td>
|
||||
<td class="summary">Constants for player hand statuses.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="4 enums/Objects.WeaponType.html">Objects.WeaponType</a></td>
|
||||
<td class="summary">Constants for weapon types.</td>
|
||||
|
@ -355,6 +361,11 @@ local door = GetMoveableByName("door_type4_14")
|
|||
</table>
|
||||
<h2>5 Lua utility modules</h2>
|
||||
<table class="module_list">
|
||||
<tr>
|
||||
<td class="name" ><a href="5 lua utility modules/Diary.html">Diary</a></td>
|
||||
<td class="summary">Diaries:
|
||||
The module provides functions to create and manage Diaries.</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td class="name" ><a href="5 lua utility modules/EventSequence.html">EventSequence</a></td>
|
||||
<td class="summary">Event sequence - a chain of functions to call at specified times, modeled after TRNG's organizers.</td>
|
||||
|
|
2
LICENSE
2
LICENSE
|
@ -1,6 +1,6 @@
|
|||
MIT License
|
||||
|
||||
Copyright (c) 2024 TombEngine Team
|
||||
Copyright (c) 2025 TombEngine Team
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy
|
||||
of this software and associated documentation files (the "Software"), to deal
|
||||
|
|
216
Scripts/DiarySetup.lua
Normal file
216
Scripts/DiarySetup.lua
Normal file
|
@ -0,0 +1,216 @@
|
|||
|
||||
|
||||
return {
|
||||
{
|
||||
type = "diary",
|
||||
object = TEN.Objects.ObjID.DIARY_ITEM,
|
||||
objectIdBg = TEN.Objects.ObjID.DIARY_SPRITES,
|
||||
spriteIdBg = 0,
|
||||
colorBg = TEN.Color(255, 255, 255),
|
||||
pos = TEN.Vec2(50,47.5),
|
||||
rot = 0,
|
||||
scale = TEN.Vec2(100,95),
|
||||
alignMode = TEN.View.AlignMode.CENTER,
|
||||
scaleMode = TEN.View.ScaleMode.FIT,
|
||||
blendMode = TEN.Effects.BlendID.ALPHABLEND,
|
||||
alpha = 255,
|
||||
pageSound=369,
|
||||
exitSound=369,
|
||||
pagesToUnlock = 1
|
||||
},
|
||||
{
|
||||
type = "background",
|
||||
objectIdBg = TEN.Objects.ObjID.DIARY_SPRITES,
|
||||
spriteIdBg = 1,
|
||||
colorBg = TEN.Color(255,0, 0),
|
||||
pos = TEN.Vec2(50,50),
|
||||
rot = 0,
|
||||
scale = TEN.Vec2(100,100),
|
||||
alignMode = TEN.View.AlignMode.CENTER,
|
||||
scaleMode = TEN.View.ScaleMode.STRETCH,
|
||||
blendMode = TEN.Effects.BlendID.ALPHABLEND,
|
||||
alpha = 160
|
||||
},
|
||||
{
|
||||
type = "pageNumbers",
|
||||
pageNoType = 2,
|
||||
prefix = "Page: ",
|
||||
separator = " of ",
|
||||
textPos = TEN.Vec2(98,95),
|
||||
textOptions = {TEN.Strings.DisplayStringOption.RIGHT, TEN.Strings.DisplayStringOption.SHADOW},
|
||||
textScale = 0.5,
|
||||
textColor = TEN.Color(255, 255, 255)
|
||||
},
|
||||
{
|
||||
type = "controls",
|
||||
string1 = "Space: Play Voice Note",
|
||||
string2 = "Left Key: Previous Page",
|
||||
string3 = "Right Key: Next Page",
|
||||
string4 = "Esc: Back",
|
||||
separator = " | ",
|
||||
textPos = TEN.Vec2(5,95),
|
||||
textOptions = {TEN.Strings.DisplayStringOption.SHADOW},
|
||||
textScale = 0.5,
|
||||
textColor = TEN.Color(255, 255, 255)
|
||||
},
|
||||
{
|
||||
type = "notification",
|
||||
notificationTime = 3,
|
||||
objectId = TEN.Objects.ObjID.DIARY_SPRITES,
|
||||
spriteId = 2,
|
||||
color = TEN.Color(255,255,255),
|
||||
pos = TEN.Vec2(90,90),
|
||||
rot = 0,
|
||||
scale = TEN.Vec2(5,5),
|
||||
alignMode = TEN.View.AlignMode.CENTER,
|
||||
scaleMode = TEN.View.ScaleMode.FIT,
|
||||
blendMode = TEN.Effects.BlendID.ALPHABLEND,
|
||||
notificationSound = 114
|
||||
},
|
||||
{
|
||||
type = "image",
|
||||
pageIndex = 1,
|
||||
objectId = TEN.Objects.ObjID.DIARY_ENTRY_SPRITES,
|
||||
spriteId = 0,
|
||||
color = TEN.Color(255, 255, 255),
|
||||
pos = TEN.Vec2(35,47.5),
|
||||
rot = 0,
|
||||
scale = TEN.Vec2(40,40),
|
||||
alignMode = TEN.View.AlignMode.CENTER,
|
||||
scaleMode = TEN.View.ScaleMode.FIT,
|
||||
blendMode = TEN.Effects.BlendID.ALPHABLEND
|
||||
},
|
||||
{
|
||||
type = "text",
|
||||
pageIndex = 1,
|
||||
text = "Welcome to TEN diary.",
|
||||
textPos = TEN.Vec2(52,47.5),
|
||||
textOptions = {TEN.Strings.DisplayStringOption.SHADOW},
|
||||
textScale = 1,
|
||||
textColor = TEN.Color(255, 255, 255)
|
||||
},
|
||||
{
|
||||
type = "image",
|
||||
pageIndex = 2,
|
||||
objectId = TEN.Objects.ObjID.DIARY_ENTRY_SPRITES,
|
||||
spriteId = 1,
|
||||
color = TEN.Color(255, 255, 255),
|
||||
pos = TEN.Vec2(35,47.5),
|
||||
rot = 0,
|
||||
scale = TEN.Vec2(40,40),
|
||||
alignMode = TEN.View.AlignMode.CENTER,
|
||||
scaleMode = TEN.View.ScaleMode.FIT,
|
||||
blendMode = TEN.Effects.BlendID.ALPHABLEND
|
||||
},
|
||||
{
|
||||
type = "text",
|
||||
pageIndex = 2,
|
||||
text = "You can edit the diary by\nediting the file\nDiarySetup.lua in script\nfolder.",
|
||||
textPos = TEN.Vec2(52,10),
|
||||
textOptions = {TEN.Strings.DisplayStringOption.SHADOW},
|
||||
textScale = 1,
|
||||
textColor = TEN.Color(128, 255, 128)
|
||||
},
|
||||
{
|
||||
type = "image",
|
||||
pageIndex = 3,
|
||||
objectId = TEN.Objects.ObjID.DIARY_ENTRY_SPRITES,
|
||||
spriteId = 2,
|
||||
color = TEN.Color(255, 255, 255),
|
||||
pos = TEN.Vec2(35,47.5),
|
||||
rot = 0,
|
||||
scale = TEN.Vec2(30,30),
|
||||
alignMode = TEN.View.AlignMode.CENTER,
|
||||
scaleMode = TEN.View.ScaleMode.FIT,
|
||||
blendMode = TEN.Effects.BlendID.ALPHABLEND
|
||||
},
|
||||
{
|
||||
type = "text",
|
||||
pageIndex = 3,
|
||||
text = "You can also use nodes\nto unlock pages.\nAdd additional text or\nimage entries.\nAdd or update narration.",
|
||||
textPos = TEN.Vec2(52,10),
|
||||
textOptions = {TEN.Strings.DisplayStringOption.SHADOW},
|
||||
textScale = 1,
|
||||
textColor = TEN.Color(128, 255, 128)
|
||||
},
|
||||
{
|
||||
type = "image",
|
||||
pageIndex = 4,
|
||||
objectId = TEN.Objects.ObjID.DIARY_ENTRY_SPRITES,
|
||||
spriteId = 4,
|
||||
color = TEN.Color(255, 255, 255),
|
||||
pos = TEN.Vec2(25.5,40),
|
||||
rot = 0,
|
||||
scale = TEN.Vec2(15,15),
|
||||
alignMode = TEN.View.AlignMode.CENTER_BOTTOM,
|
||||
scaleMode = TEN.View.ScaleMode.FIT,
|
||||
blendMode = TEN.Effects.BlendID.ALPHABLEND
|
||||
},
|
||||
{
|
||||
type = "image",
|
||||
pageIndex = 4,
|
||||
objectId = TEN.Objects.ObjID.DIARY_ENTRY_SPRITES,
|
||||
spriteId = 5,
|
||||
color = TEN.Color(255, 255, 255),
|
||||
pos = TEN.Vec2(41.5,40),
|
||||
rot = 0,
|
||||
scale = TEN.Vec2(15,15),
|
||||
alignMode = TEN.View.AlignMode.CENTER_BOTTOM,
|
||||
scaleMode = TEN.View.ScaleMode.FIT,
|
||||
blendMode = TEN.Effects.BlendID.ALPHABLEND
|
||||
},
|
||||
{
|
||||
type = "image",
|
||||
pageIndex = 4,
|
||||
objectId = TEN.Objects.ObjID.DIARY_ENTRY_SPRITES,
|
||||
spriteId = 3,
|
||||
color = TEN.Color(255, 255, 255),
|
||||
pos = TEN.Vec2(33.5,80),
|
||||
rot = 0,
|
||||
scale = TEN.Vec2(30,30),
|
||||
alignMode = TEN.View.AlignMode.CENTER_BOTTOM,
|
||||
scaleMode = TEN.View.ScaleMode.FIT,
|
||||
blendMode = TEN.Effects.BlendID.ALPHABLEND
|
||||
},
|
||||
{
|
||||
type = "text",
|
||||
pageIndex = 4,
|
||||
text = "Funerary Mask",
|
||||
textPos = TEN.Vec2(25.5,42),
|
||||
textOptions = {TEN.Strings.DisplayStringOption.CENTER, TEN.Strings.DisplayStringOption.SHADOW},
|
||||
textScale = 0.3,
|
||||
textColor = TEN.Color(255, 184, 47)
|
||||
},
|
||||
{
|
||||
type = "text",
|
||||
pageIndex = 4,
|
||||
text = "Queen's Bust",
|
||||
textPos = TEN.Vec2(41.5,42),
|
||||
textOptions = {TEN.Strings.DisplayStringOption.CENTER, TEN.Strings.DisplayStringOption.SHADOW},
|
||||
textScale = 0.3,
|
||||
textColor = TEN.Color(255, 184, 47)
|
||||
},
|
||||
{
|
||||
type = "text",
|
||||
pageIndex = 4,
|
||||
text = "Amulet",
|
||||
textPos = TEN.Vec2(33.5,82),
|
||||
textOptions = {TEN.Strings.DisplayStringOption.CENTER, TEN.Strings.DisplayStringOption.SHADOW},
|
||||
textScale = 0.3,
|
||||
textColor = TEN.Color(255, 184, 47)
|
||||
},
|
||||
{
|
||||
type = "text",
|
||||
pageIndex = 4,
|
||||
text = "You can create quite\ncomplex pages.\n\nThis page has 3 images\nand text.\n\nIt also has a narration\nthat can be played\nwith Space.",
|
||||
textPos = TEN.Vec2(52,10),
|
||||
textOptions = {TEN.Strings.DisplayStringOption.SHADOW},
|
||||
textScale = 1,
|
||||
textColor = TEN.Color(255, 128, 128)
|
||||
},
|
||||
{
|
||||
type = "narration",
|
||||
pageIndex = 4,
|
||||
trackName = "027",
|
||||
},
|
||||
}
|
1574
Scripts/Engine/CustomDiary.lua
Normal file
1574
Scripts/Engine/CustomDiary.lua
Normal file
File diff suppressed because it is too large
Load diff
|
@ -26,180 +26,186 @@
|
|||
-- end
|
||||
-- @luautil Type
|
||||
|
||||
local color = TEN.Color(0,0,0)
|
||||
local rotation = TEN.Rotation(0, 0, 0)
|
||||
local time = TEN.Time()
|
||||
local vec2 = TEN.Vec2(0,0)
|
||||
local vec3 = TEN.Vec3(0,0,0)
|
||||
LevelFuncs.TypeControlLevelFunc = function () end
|
||||
|
||||
local Type = {}
|
||||
|
||||
|
||||
--- Check if the variable is a number.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a number, false if it isn't a number
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- local num = 255
|
||||
-- if Type.IsNumber(num) then
|
||||
-- num = num + 1
|
||||
-- end
|
||||
--- Check if the variable is a number.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a number, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- local num = 255
|
||||
-- if Type.IsNumber(num) then
|
||||
-- num = num + 1
|
||||
-- end
|
||||
Type.IsNumber = function (variable)
|
||||
return type(variable) == "number"
|
||||
end
|
||||
|
||||
--- Check if the variable is a string.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a string, false if it isn't a string
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- local str = "Hi"
|
||||
-- if Type.IsString(str) then
|
||||
-- TEN.Util.PrintLog(str .. "everyone!", Util.LogLevel.INFO)
|
||||
-- end
|
||||
--- Check if the variable is a string.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a string, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- local str = "Hi"
|
||||
-- if Type.IsString(str) then
|
||||
-- TEN.Util.PrintLog(str .. "everyone!", Util.LogLevel.INFO)
|
||||
-- end
|
||||
Type.IsString = function (variable)
|
||||
return type(variable) == "string"
|
||||
end
|
||||
|
||||
|
||||
--- Check if the variable is a boolean.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a boolean, false if it isn't a boolean
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.test = function (test)
|
||||
-- if Type.IsBoolean(test) then
|
||||
-- LevelVars.test = test
|
||||
-- else
|
||||
-- TEN.Util.PrintLog("Error!", Util.LogLevel.ERROR)
|
||||
-- end
|
||||
-- end
|
||||
--- Check if the variable is a boolean.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a boolean, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.test = function (test)
|
||||
-- if Type.IsBoolean(test) then
|
||||
-- LevelVars.test = test
|
||||
-- else
|
||||
-- TEN.Util.PrintLog("Error!", Util.LogLevel.ERROR)
|
||||
-- end
|
||||
-- end
|
||||
Type.IsBoolean = function (variable)
|
||||
return type(variable) == "boolean"
|
||||
end
|
||||
|
||||
--- Check if the variable is a table.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a table, false if it isn't a table
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.PairsTable = function (table)
|
||||
-- if Type.IsTable(table) then
|
||||
-- for k, v in pairs(table) do
|
||||
-- TEN.Util.PrintLog(tostring(k) .. " - " .. tostring(v), Util.LogLevel.INFO)
|
||||
-- end
|
||||
-- end
|
||||
-- end
|
||||
--- Check if the variable is a table.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a table, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.PairsTable = function (table)
|
||||
-- if Type.IsTable(table) then
|
||||
-- for k, v in pairs(table) do
|
||||
-- TEN.Util.PrintLog(tostring(k) .. " - " .. tostring(v), Util.LogLevel.INFO)
|
||||
-- end
|
||||
-- end
|
||||
-- end
|
||||
Type.IsTable = function (variable)
|
||||
return type(variable) == "table"
|
||||
end
|
||||
|
||||
--- Check if the variable has a null value.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a null, false if it isn't a null
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.AddProp = function (prop)
|
||||
-- if Type.IsNull(prop) then
|
||||
-- TEN.Util.PrintLog("Error!", Util.LogLevel.ERROR)
|
||||
-- else
|
||||
-- LevelVars.property = prop
|
||||
-- end
|
||||
-- end
|
||||
--- Check if the variable has a null value.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a null, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.AddProp = function (prop)
|
||||
-- if Type.IsNull(prop) then
|
||||
-- TEN.Util.PrintLog("Error!", Util.LogLevel.ERROR)
|
||||
-- else
|
||||
-- LevelVars.property = prop
|
||||
-- end
|
||||
-- end
|
||||
Type.IsNull = function (variable)
|
||||
return type(variable) == "nil"
|
||||
end
|
||||
|
||||
--- Check if the variable is a function.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a function, false if it isn't a function
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.RunFunc = function (func)
|
||||
-- if Type.IsFunction(func) then
|
||||
-- func()
|
||||
-- end
|
||||
-- end
|
||||
--- Check if the variable is a function.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a function, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.RunFunc = function (func)
|
||||
-- if Type.IsFunction(func) then
|
||||
-- func()
|
||||
-- end
|
||||
-- end
|
||||
Type.IsFunction = function (variable)
|
||||
return type(variable) == "function"
|
||||
end
|
||||
|
||||
--- Check if the variable is a @{Color}.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a color, false if it isn't a color
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.SetColor = function(color)
|
||||
-- if Type.IsColor(color) then
|
||||
-- string:SetColor(color)
|
||||
-- end
|
||||
-- end
|
||||
--- Check if the variable is a @{Color}.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a Color, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.SetColor = function(color)
|
||||
-- if Type.IsColor(color) then
|
||||
-- string:SetColor(color)
|
||||
-- end
|
||||
-- end
|
||||
Type.IsColor = function (variable)
|
||||
return variable ~= nil and type(variable) == "userdata" and variable.__type.name == "ScriptColor"
|
||||
return getmetatable(variable) == getmetatable(color)
|
||||
end
|
||||
|
||||
--- Check if the variable is a @{Rotation}.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a rotation, false if it isn't a rotation
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.SetRotation = function (rot)
|
||||
-- if Type.IsRotation(rot) then
|
||||
-- Lara:SetRotation(rot)
|
||||
-- end
|
||||
-- end
|
||||
--- Check if the variable is a @{Rotation}.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a Rotation, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.SetRotation = function (rot)
|
||||
-- if Type.IsRotation(rot) then
|
||||
-- Lara:SetRotation(rot)
|
||||
-- end
|
||||
-- end
|
||||
Type.IsRotation = function (variable)
|
||||
return variable ~= nil and type(variable) == "userdata" and variable.__type.name == "Rotation"
|
||||
return getmetatable(variable) == getmetatable(rotation)
|
||||
end
|
||||
|
||||
--- Check if the variable is a @{Vec2}.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a vec2, false if it isn't a vec2
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.SetSpritePos = function (pos)
|
||||
-- if Type.IsVec2(pos) then
|
||||
-- sprite:SetPosition(pos)
|
||||
-- end
|
||||
-- end
|
||||
--- Check if the variable is a @{Vec2}.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a Vec2, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.SetSpritePos = function (pos)
|
||||
-- if Type.IsVec2(pos) then
|
||||
-- sprite:SetPosition(pos)
|
||||
-- end
|
||||
-- end
|
||||
Type.IsVec2 = function (variable)
|
||||
return variable ~= nil and type(variable) == "userdata" and variable.__type.name == "Vec2"
|
||||
return getmetatable(variable) == getmetatable(vec2)
|
||||
end
|
||||
|
||||
--- Check if the variable is a @{Vec3}.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a vec3, false if it isn't a vec3
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.SetLaraPos = function (pos)
|
||||
-- if Type.IsVec3(pos) then
|
||||
-- Lara:SetPosition(pos)
|
||||
-- end
|
||||
-- end
|
||||
--- Check if the variable is a @{Vec3}.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a Vec3, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.SetLaraPos = function (pos)
|
||||
-- if Type.IsVec3(pos) then
|
||||
-- Lara:SetPosition(pos)
|
||||
-- end
|
||||
-- end
|
||||
Type.IsVec3 = function (variable)
|
||||
return variable ~= nil and type(variable) == "userdata" and variable.__type.name == "Vec3"
|
||||
return getmetatable(variable) == getmetatable(vec3)
|
||||
end
|
||||
|
||||
--- Check if the variable is a @{Time} object.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a Time object, false if it isn't a Time object
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.IncreaseTime = function (time)
|
||||
-- if Type.IsTime(time) then
|
||||
-- time + 1
|
||||
-- end
|
||||
-- end
|
||||
--- Check if the variable is a @{Time} object.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a Time object, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.IncreaseTime = function (time)
|
||||
-- if Type.IsTime(time) then
|
||||
-- time + 1
|
||||
-- end
|
||||
-- end
|
||||
Type.IsTime = function (variable)
|
||||
return variable ~= nil and type(variable) == "userdata" and variable.__type.name == "TEN::Scripting::Time"
|
||||
return getmetatable(variable) == getmetatable(time)
|
||||
end
|
||||
|
||||
--- Check if the variable is a LevelFunc.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean true if the variable is a LevelFunc, false if it isn't a IsLevelFunc
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.SetCallback = function (func)
|
||||
-- if Type.IsFunction(func) then
|
||||
-- TEN.Logic.AddCallback(TEN.Logic.CallbackPoint.PRELOOP, func)
|
||||
-- end
|
||||
-- end
|
||||
--- Check if the variable is a LevelFunc.
|
||||
-- @tparam variable variable to be check
|
||||
-- @treturn boolean *true* if the variable is a LevelFunc, *false* otherwise
|
||||
-- @usage
|
||||
-- --example of use
|
||||
-- LevelFuncs.SetCallback = function (func)
|
||||
-- if Type.IsFunction(func) then
|
||||
-- TEN.Logic.AddCallback(TEN.Logic.CallbackPoint.PRELOOP, func)
|
||||
-- end
|
||||
-- end
|
||||
Type.IsLevelFunc = function (variable)
|
||||
return variable ~= nil and type(variable) == "userdata" and variable.__type.name == "LevelFunc"
|
||||
return getmetatable(variable) == getmetatable(LevelFuncs.TypeControlLevelFunc)
|
||||
end
|
||||
|
||||
return Type
|
|
@ -38,10 +38,10 @@ namespace TEN::Gui
|
|||
{ ID_CROSSBOW_AMMO3_ITEM, 0, 0.5f, EulerAngles(0, ANGLE(-90.0f), 0), OPT_USE, STRING_CROSSBOW_AMMO_3, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_HK_ITEM, 0, 0.5f, EulerAngles(ANGLE(280.0f), 0, 0), OPT_EQUIP | OPT_COMBINABLE | OPT_CHOOSE_AMMO_HK, STRING_HK, 0x01, INV_ROT_Y },
|
||||
{ ID_HK_ITEM, 0, 0.5f, EulerAngles(ANGLE(280.0f), ANGLE(-45.0f), 0), OPT_EQUIP | OPT_SEPERABLE | OPT_CHOOSE_AMMO_HK, STRING_HK_LASERSIGHT, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_HK_AMMO_ITEM, 3, 0.5f, EulerAngles(0, ANGLE(90.0f), 0), OPT_USE, STRING_HK_AMMO, 0x02, INV_ROT_Y },
|
||||
{ ID_HK_AMMO_ITEM, 3, 0.5f, EulerAngles(0, ANGLE(90.0f), 0), OPT_USE, STRING_HK_RAPID_MODE, 0x03, INV_ROT_Y },
|
||||
{ ID_HK_AMMO_ITEM, 3, 0.5f, EulerAngles(0, ANGLE(90.0f), 0), OPT_USE, STRING_HK_BURST_MODE, 0x04, INV_ROT_Y },
|
||||
{ ID_HK_AMMO_ITEM, 3, 0.5f, EulerAngles(0, ANGLE(90.0f), 0), OPT_USE, STRING_HK_SNIPER_MODE, 0x05, INV_ROT_Y },
|
||||
{ ID_HK_AMMO_ITEM, 3, 0.5f, EulerAngles(0, ANGLE(90.0f), 0), OPT_USE, STRING_HK_AMMO, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_HK_AMMO_ITEM, 3, 0.5f, EulerAngles(0, ANGLE(90.0f), 0), OPT_USE, STRING_HK_RAPID_MODE, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_HK_AMMO_ITEM, 3, 0.5f, EulerAngles(0, ANGLE(90.0f), 0), OPT_USE, STRING_HK_BURST_MODE, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_HK_AMMO_ITEM, 3, 0.5f, EulerAngles(0, ANGLE(90.0f), 0), OPT_USE, STRING_HK_SNIPER_MODE, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_GRENADE_GUN_ITEM, 0, 0.5f, EulerAngles(0, ANGLE(90.0f), ANGLE(65)), OPT_EQUIP | OPT_COMBINABLE | OPT_CHOOSE_AMMO_GRENADEGUN, STRING_GRENADE_LAUNCHER, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_GRENADE_AMMO1_ITEM, 3, 0.5f, EulerAngles(0, ANGLE(-90.0f), 0), OPT_USE, STRING_GRENADE_LAUNCHER_AMMO_1, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_GRENADE_AMMO2_ITEM, 3, 0.5f, EulerAngles(0, ANGLE(-90.0f), 0), OPT_USE, STRING_GRENADE_LAUNCHER_AMMO_2, NO_JOINT_BITS, INV_ROT_Y },
|
||||
|
@ -58,7 +58,7 @@ namespace TEN::Gui
|
|||
{ ID_SMALLMEDI_ITEM, 0, 0.7f, EulerAngles(ANGLE(112.0f), ANGLE(180.0f), 0), OPT_USE, STRING_SMALL_MEDIPACK, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_BINOCULARS_ITEM, -1, 0.5f, EulerAngles(ANGLE(10.0f), ANGLE(180.0f), 0), OPT_USE, STRING_BINOCULARS, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_FLARE_INV_ITEM, 52, 0.8f, EulerAngles::Identity, OPT_USE, STRING_FLARES, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_STOPWATCH_ITEM, 2, 0.4f, EulerAngles::Identity, OPT_STATS, STRING_STATISTICS, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_STOPWATCH_ITEM, 2, 0.8f, EulerAngles::Identity, OPT_STATS, STRING_STATISTICS, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_PC_LOAD_INV_ITEM, 52, 0.3f, EulerAngles(0, ANGLE(180.0f), 0), OPT_LOAD, STRING_LOAD_GAME, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_PC_SAVE_INV_ITEM, 52, 0.3f, EulerAngles(0, ANGLE(180.0f), 0), OPT_SAVE, STRING_SAVE_GAME, NO_JOINT_BITS, INV_ROT_Y },
|
||||
{ ID_BURNING_TORCH_ITEM, 14, 0.5f, EulerAngles(ANGLE(90.0f), 0, 0), OPT_USE, STRING_TORCH, NO_JOINT_BITS, INV_ROT_Y },
|
||||
|
|
|
@ -11,13 +11,15 @@ namespace TEN::Hud
|
|||
class HudController
|
||||
{
|
||||
public:
|
||||
// Members
|
||||
// Fields
|
||||
|
||||
StatusBarsController StatusBars = {};
|
||||
PickupSummaryController PickupSummary = {};
|
||||
SpeedometerController Speedometer = {};
|
||||
TargetHighlighterController TargetHighlighter = {};
|
||||
|
||||
// Utilities
|
||||
|
||||
void Update(const ItemInfo& playerItem);
|
||||
void Draw(const ItemInfo& playerItem) const;
|
||||
void Clear();
|
||||
|
|
|
@ -50,7 +50,7 @@ namespace TEN::Hud
|
|||
static constexpr auto DISPLAY_PICKUP_COUNT_MAX = 64;
|
||||
static constexpr auto DISPLAY_PICKUP_COUNT_ARG_DEFAULT = 1;
|
||||
|
||||
// Members
|
||||
// Fields
|
||||
|
||||
std::vector<DisplayPickup> _displayPickups = {};
|
||||
|
||||
|
|
|
@ -9,7 +9,7 @@ namespace TEN::Hud
|
|||
|
||||
static constexpr auto LIFE_MAX = 0.75f;
|
||||
|
||||
// Members
|
||||
// Fields
|
||||
|
||||
bool _hasValueUpdated = false;
|
||||
|
||||
|
|
|
@ -25,7 +25,7 @@ namespace TEN::Hud
|
|||
class StatusBarsController
|
||||
{
|
||||
private:
|
||||
// Members
|
||||
// Fields
|
||||
|
||||
StatusBar _airBar = {};
|
||||
StatusBar _exposureBar = {};
|
||||
|
|
|
@ -20,7 +20,7 @@ namespace TEN::Hud
|
|||
static constexpr auto COLOR_GRAY = Color(0.7f, 0.7f, 0.7f, 0.7f);
|
||||
static constexpr auto SEGMENT_COUNT = 4;
|
||||
|
||||
// Members
|
||||
// Fields
|
||||
|
||||
bool IsActive = false;
|
||||
bool IsPrimary = false;
|
||||
|
|
|
@ -615,6 +615,7 @@ void LaraCheat(ItemInfo* item, CollisionInfo* coll)
|
|||
|
||||
ResetPlayerFlex(item);
|
||||
InitializeLaraMeshes(item);
|
||||
item->Animation.IsAirborne = false;
|
||||
item->HitPoints = LARA_HEALTH_MAX;
|
||||
player.Control.HandStatus = HandStatus::Free;
|
||||
}
|
||||
|
|
|
@ -46,6 +46,7 @@ constexpr auto LARA_HEIGHT_TREAD = 700; // Height in water tread states.
|
|||
constexpr auto LARA_HEIGHT_STRETCH = 870; // Height in jump up and ledge hang states.
|
||||
constexpr auto LARA_HEIGHT_REACH = 820; // Height in reach state.
|
||||
constexpr auto LARA_HEIGHT_SURFACE = 800; // Height when resurfacing water.
|
||||
constexpr auto LARA_HEIGHT_UNDERWATER = 254; // Minimum height underwater.
|
||||
constexpr auto LARA_HEADROOM = 160; // Reasonable space above head.
|
||||
constexpr auto LARA_RADIUS = 100;
|
||||
constexpr auto LARA_RADIUS_CRAWL = 200;
|
||||
|
|
|
@ -328,10 +328,12 @@ void lara_col_run_forward(ItemInfo* item, CollisionInfo* coll)
|
|||
player.Control.MoveAngle = item->Pose.Orientation.y;
|
||||
item->Animation.IsAirborne = false;
|
||||
item->Animation.Velocity.y = 0;
|
||||
coll->Setup.LowerFloorBound = NO_LOWER_BOUND;
|
||||
coll->Setup.LowerFloorBound = IsHeld(In::Walk) ? STEPUP_HEIGHT : NO_LOWER_BOUND;
|
||||
coll->Setup.UpperFloorBound = -STEPUP_HEIGHT;
|
||||
coll->Setup.LowerCeilingBound = 0;
|
||||
coll->Setup.BlockFloorSlopeUp = true;
|
||||
coll->Setup.BlockFloorSlopeDown = IsHeld(In::Walk);
|
||||
coll->Setup.BlockDeathFloorDown = IsHeld(In::Walk);
|
||||
coll->Setup.ForwardAngle = player.Control.MoveAngle;
|
||||
GetCollisionInfo(coll, item);
|
||||
LaraResetGravityStatus(item, coll);
|
||||
|
|
|
@ -540,13 +540,9 @@ void LaraSwimCollision(ItemInfo* item, CollisionInfo* coll)
|
|||
coll->Setup.ForwardAngle = item->Pose.Orientation.y;
|
||||
}
|
||||
|
||||
int height = abs(LARA_HEIGHT * phd_sin(item->Pose.Orientation.x));
|
||||
int height = std::max((int)abs(LARA_HEIGHT * phd_sin(item->Pose.Orientation.x)), LARA_HEIGHT_UNDERWATER);
|
||||
auto offset = Vector3i(0, height / 2, 0);
|
||||
|
||||
auto level = g_GameFlow->GetLevel(CurrentLevel);
|
||||
if (height < ((level->GetLaraType() == LaraType::Divesuit) << 6) + 200)
|
||||
height = ((level->GetLaraType() == LaraType::Divesuit) << 6) + 200;
|
||||
|
||||
coll->Setup.UpperFloorBound = -CLICK(0.25f);
|
||||
coll->Setup.Height = height;
|
||||
|
||||
|
|
|
@ -421,7 +421,7 @@ void lara_as_crawl_idle(ItemInfo* item, CollisionInfo* coll)
|
|||
}
|
||||
|
||||
if ((IsHeld(In::Sprint) && CanCrouchRoll(*item, *coll)) ||
|
||||
((IsHeld(In::Draw) || IsHeld(In::Flare)) &&
|
||||
((IsHeld(In::Draw) || (IsHeld(In::Flare) && player.Inventory.TotalFlares)) &&
|
||||
!IsStandingWeapon(item, player.Control.Weapon.GunType) && HasStateDispatch(item, LS_CROUCH_IDLE)))
|
||||
{
|
||||
item->Animation.TargetState = LS_CROUCH_IDLE;
|
||||
|
|
|
@ -574,7 +574,7 @@ void HandleWeapon(ItemInfo& laraItem)
|
|||
}
|
||||
else if (player.Inventory.TotalFlares && !player.Control.Look.IsUsingBinoculars)
|
||||
{
|
||||
if (player.Inventory.TotalFlares != -1)
|
||||
if (player.Inventory.TotalFlares != NO_VALUE)
|
||||
player.Inventory.TotalFlares--;
|
||||
|
||||
player.Control.Weapon.RequestGunType = LaraWeaponType::Flare;
|
||||
|
@ -648,8 +648,14 @@ void HandleWeapon(ItemInfo& laraItem)
|
|||
laraItem.Animation.ActiveState == LS_CRAWL_IDLE &&
|
||||
laraItem.Animation.AnimNumber == LA_CRAWL_IDLE)
|
||||
{
|
||||
if (player.Inventory.TotalFlares)
|
||||
{
|
||||
if (player.Inventory.TotalFlares != NO_VALUE)
|
||||
player.Inventory.TotalFlares--;
|
||||
|
||||
player.Control.Weapon.RequestGunType = LaraWeaponType::Flare;
|
||||
}
|
||||
}
|
||||
|
||||
switch (player.Control.HandStatus)
|
||||
{
|
||||
|
|
|
@ -1421,6 +1421,7 @@ void SetLaraVault(ItemInfo* item, CollisionInfo* coll, const VaultTestResult& va
|
|||
auto& player = GetLaraInfo(*item);
|
||||
|
||||
ResetPlayerTurnRateY(*item);
|
||||
item->Animation.IsAirborne = false;
|
||||
player.Context.ProjectedFloorHeight = vaultResult.Height;
|
||||
|
||||
if (vaultResult.SetBusyHands)
|
||||
|
@ -1449,7 +1450,8 @@ void SetLaraLand(ItemInfo* item, CollisionInfo* coll)
|
|||
if (item->Animation.TargetState != LS_RUN_FORWARD)
|
||||
item->Animation.Velocity.z = 0.0f;
|
||||
|
||||
//item->IsAirborne = false; // TODO: Removing this avoids an unusual landing bug. I hope to find a proper solution later. -- Sezz 2022.02.18
|
||||
// TODO: Commenting this avoids an unusual bug where if the player hits a ceiling, they won't land. I hope to find a proper solution later. -- Sezz 2022.02.18
|
||||
//item->Animation.IsAirborne = false;
|
||||
item->Animation.Velocity.y = 0.0f;
|
||||
LaraSnapToHeight(item, coll);
|
||||
}
|
||||
|
|
|
@ -14,6 +14,7 @@
|
|||
#include "Game/effects/effects.h"
|
||||
#include "Game/effects/item_fx.h"
|
||||
#include "Game/effects/Ripple.h"
|
||||
#include "Game/effects/Splash.h"
|
||||
#include "Game/effects/tomb4fx.h"
|
||||
#include "Game/effects/weather.h"
|
||||
#include "Game/items.h"
|
||||
|
@ -38,6 +39,7 @@ using namespace TEN::Effects::Drip;
|
|||
using namespace TEN::Effects::Environment;
|
||||
using namespace TEN::Effects::Items;
|
||||
using namespace TEN::Effects::Ripple;
|
||||
using namespace TEN::Effects::Splash;
|
||||
using namespace TEN::Entities::Switches;
|
||||
using namespace TEN::Input;
|
||||
using namespace TEN::Math;
|
||||
|
@ -1084,7 +1086,7 @@ void FireCrossbow(ItemInfo& laraItem, const std::optional<Pose>& pose)
|
|||
void FireCrossBowFromLaserSight(ItemInfo& laraItem, GameVector* origin, GameVector* target)
|
||||
{
|
||||
auto orient = Geometry::GetOrientToPoint(origin->ToVector3(), target->ToVector3());
|
||||
auto boltPose = Pose(origin->x, origin->y, origin->z, orient);
|
||||
auto boltPose = Pose(origin->ToVector3i(), orient);
|
||||
FireCrossbow(laraItem, boltPose);
|
||||
}
|
||||
|
||||
|
@ -1584,7 +1586,7 @@ void HandleProjectile(ItemInfo& projectile, ItemInfo& emitter, const Vector3i& p
|
|||
continue;
|
||||
|
||||
TriggerExplosionSparks(staticPtr->pos.Position.x, staticPtr->pos.Position.y, staticPtr->pos.Position.z, 3, -2, 0, projectile.RoomNumber);
|
||||
auto pose = Pose(staticPtr->pos.Position.x, staticPtr->pos.Position.y - 128, staticPtr->pos.Position.z, 0, staticPtr->pos.Orientation.y, 0);
|
||||
auto pose = Pose(Vector3i(staticPtr->pos.Position.x, staticPtr->pos.Position.y - 128, staticPtr->pos.Position.z), EulerAngles(0, staticPtr->pos.Orientation.y, 0));
|
||||
TriggerShockwave(&pose, 40, 176, 64, 0, 96, 128, 16, EulerAngles::Identity, 0, true, false, false, (int)ShockwaveStyle::Normal);
|
||||
}
|
||||
|
||||
|
|
|
@ -520,7 +520,7 @@ enum LaraAnim
|
|||
LA_CRAWL_BACK_TO_IDLE_RIGHT = 277, // Crawl back > crawl idle, right foot first
|
||||
LA_REMOVE_PUZZLE = 278, // Remove puzzle item > idle
|
||||
LA_CRAWL_BACK_TO_IDLE_LEFT = 279, // Crawl back > crawl idle, left foot first
|
||||
LA_CRAWL_BACK_TO_IDLE_LEFT_END = 280, // Unused.
|
||||
LA_REMOVE_PUZZLE_UNDERWATER = 280, // Remove puzzle item > underwater idle
|
||||
LA_CRAWL_TURN_LEFT_TO_IDLE_EARLY = 281, // Crawl rotate left > crawl idle, early opportunity
|
||||
LA_CRAWL_TURN_RIGHT_TO_IDLE_EARLY = 282, // Crawl rotate right > crawl idle, early opportunity
|
||||
LA_MONKEY_TURN_LEFT_TO_IDLE_EARLY = 283, // Turn left on monkey swing > monkey swing idle, 1st opportunity
|
||||
|
@ -828,7 +828,6 @@ enum LaraAnim
|
|||
NUM_LARA_ANIMS
|
||||
|
||||
// TRASHED ANIMS (reuse slots before going any higher and remove entries from this list when you do):
|
||||
// 280,
|
||||
// 368, 370,
|
||||
// 442
|
||||
};
|
||||
|
|
|
@ -78,38 +78,38 @@ ObjectInfo& ObjectHandler::GetFirstAvailableObject()
|
|||
|
||||
void StaticHandler::Initialize()
|
||||
{
|
||||
_lookupTable.resize(0);
|
||||
_lookupTable.reserve(_defaultLUTSize);
|
||||
_lut.resize(0);
|
||||
_lut.reserve(LUT_SIZE);
|
||||
_statics.resize(0);
|
||||
}
|
||||
|
||||
int StaticHandler::GetIndex(int staticID)
|
||||
{
|
||||
if (staticID < 0 || staticID >= _lookupTable.size())
|
||||
if (staticID < 0 || staticID >= _lut.size())
|
||||
{
|
||||
TENLog("Attempt to get nonexistent static mesh ID slot index (" + std::to_string(staticID) + ")", LogLevel::Warning);
|
||||
return _lookupTable.front();
|
||||
TENLog("Attempted to get index of missing static object " + std::to_string(staticID) + ".", LogLevel::Warning);
|
||||
return _lut.front();
|
||||
}
|
||||
|
||||
return _lookupTable[staticID];
|
||||
return _lut[staticID];
|
||||
}
|
||||
|
||||
StaticInfo& StaticHandler::operator [](int staticID)
|
||||
{
|
||||
if (staticID < 0)
|
||||
{
|
||||
TENLog("Attempt to access illegal static mesh ID slot info", LogLevel::Warning);
|
||||
TENLog("Attempted to access missing static object " + std::to_string(staticID) + ".", LogLevel::Warning);
|
||||
return _statics.front();
|
||||
}
|
||||
|
||||
if (staticID >= _lookupTable.size())
|
||||
_lookupTable.resize(staticID + 1, NO_VALUE);
|
||||
if (staticID >= _lut.size())
|
||||
_lut.resize(staticID + 1, NO_VALUE);
|
||||
|
||||
if (_lookupTable[staticID] != NO_VALUE)
|
||||
return _statics[_lookupTable[staticID]];
|
||||
if (_lut[staticID] != NO_VALUE)
|
||||
return _statics[_lut[staticID]];
|
||||
|
||||
_statics.emplace_back();
|
||||
_lookupTable[staticID] = (int)_statics.size() - 1;
|
||||
_lut[staticID] = (int)_statics.size() - 1;
|
||||
|
||||
return _statics.back();
|
||||
}
|
||||
|
@ -183,7 +183,6 @@ void InitializeSpecialEffects()
|
|||
memset(&SmokeSparks, 0, MAX_SPARKS_SMOKE * sizeof(SMOKE_SPARKS));
|
||||
memset(&Gunshells, 0, MAX_GUNSHELL * sizeof(GUNSHELL_STRUCT));
|
||||
memset(&Blood, 0, MAX_SPARKS_BLOOD * sizeof(BLOOD_STRUCT));
|
||||
memset(&Splashes, 0, MAX_SPLASHES * sizeof(SPLASH_STRUCT));
|
||||
memset(&ShockWaves, 0, MAX_SHOCKWAVE * sizeof(SHOCKWAVE_STRUCT));
|
||||
memset(&Particles, 0, MAX_PARTICLES * sizeof(Particle));
|
||||
|
||||
|
|
|
@ -135,10 +135,10 @@ struct StaticInfo
|
|||
class StaticHandler
|
||||
{
|
||||
private:
|
||||
static const int _defaultLUTSize = 256;
|
||||
static constexpr auto LUT_SIZE = 256;
|
||||
|
||||
std::vector<StaticInfo> _statics = {};
|
||||
std::vector<int> _lookupTable = {};
|
||||
std::vector<int> _lut = {};
|
||||
|
||||
public:
|
||||
void Initialize();
|
||||
|
@ -147,6 +147,7 @@ public:
|
|||
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
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
#include "Game/effects/debris.h"
|
||||
#include "Game/effects/effects.h"
|
||||
#include "Game/effects/simple_particle.h"
|
||||
#include "Game/effects/Splash.h"
|
||||
#include "Game/effects/tomb4fx.h"
|
||||
#include "Game/items.h"
|
||||
#include "Game/Lara/lara.h"
|
||||
|
@ -25,6 +26,7 @@
|
|||
using namespace TEN::Collision::Floordata;
|
||||
using namespace TEN::Collision::Point;
|
||||
using namespace TEN::Collision::Sphere;
|
||||
using namespace TEN::Effects::Splash;
|
||||
using namespace TEN::Math;
|
||||
|
||||
constexpr auto ANIMATED_ALIGNMENT_FRAME_COUNT_THRESHOLD = 6;
|
||||
|
@ -890,7 +892,8 @@ void CollideBridgeItems(ItemInfo& item, CollisionInfo& coll, PointCollisionData&
|
|||
auto deltaPose = Pose(deltaPos, deltaOrient);
|
||||
|
||||
// Item is grounded and bridge position changed; set shift.
|
||||
if (deltaPose != Pose::Zero && !item.Animation.IsAirborne)
|
||||
if (deltaPose != Pose::Zero && !item.Animation.IsAirborne &&
|
||||
item.IsLara() ? (GetLaraInfo(item).Control.WaterStatus != WaterStatus::Underwater && GetLaraInfo(item).Control.WaterStatus != WaterStatus::FlyCheat) : true)
|
||||
{
|
||||
const auto& bridgePos = bridgeItem.Pose.Position;
|
||||
|
||||
|
|
|
@ -1,9 +1,6 @@
|
|||
#include "framework.h"
|
||||
#include "Game/control/control.h"
|
||||
|
||||
#include <process.h>
|
||||
#include <filesystem>
|
||||
|
||||
#include "Game/camera.h"
|
||||
#include "Game/collision/collide_room.h"
|
||||
#include "Game/control/flipeffect.h"
|
||||
|
@ -23,6 +20,7 @@
|
|||
#include "Game/effects/simple_particle.h"
|
||||
#include "Game/effects/smoke.h"
|
||||
#include "Game/effects/spark.h"
|
||||
#include "Game/effects/Splash.h"
|
||||
#include "Game/effects/Streamer.h"
|
||||
#include "Game/effects/tomb4fx.h"
|
||||
#include "Game/effects/weather.h"
|
||||
|
@ -75,6 +73,7 @@ using namespace TEN::Effects::Hair;
|
|||
using namespace TEN::Effects::Ripple;
|
||||
using namespace TEN::Effects::Smoke;
|
||||
using namespace TEN::Effects::Spark;
|
||||
using namespace TEN::Effects::Splash;
|
||||
using namespace TEN::Effects::Streamer;
|
||||
using namespace TEN::Entities::Creatures::TR3;
|
||||
using namespace TEN::Entities::Generic;
|
||||
|
|
|
@ -8,7 +8,7 @@ namespace TEN::Control::Volumes
|
|||
{
|
||||
using Activator = std::variant<
|
||||
std::nullptr_t,
|
||||
short,
|
||||
int,
|
||||
MESH_INFO*,
|
||||
CAMERA_INFO*>;
|
||||
|
||||
|
|
|
@ -47,16 +47,16 @@ int TriggerActive(ItemInfo* item)
|
|||
{
|
||||
--item->Timer;
|
||||
if (!item->Timer)
|
||||
item->Timer = -1;
|
||||
item->Timer = NO_VALUE;
|
||||
}
|
||||
else if (item->Timer < -1)
|
||||
else if (item->Timer < NO_VALUE)
|
||||
{
|
||||
++item->Timer;
|
||||
if (item->Timer == -1)
|
||||
if (item->Timer == NO_VALUE)
|
||||
item->Timer = 0;
|
||||
}
|
||||
|
||||
if (item->Timer <= -1)
|
||||
if (item->Timer <= NO_VALUE)
|
||||
flag = !flag;
|
||||
}
|
||||
}
|
||||
|
@ -429,6 +429,10 @@ void TestTriggers(int x, int y, int z, FloorInfo* floor, Activator activator, bo
|
|||
if (!data)
|
||||
return;
|
||||
|
||||
// Don't process legacy triggers if triggerer flag was used in editor and trigger triggerer wasn't activated or used.
|
||||
if (floor->Flags.MarkTriggerer && !floor->Flags.MarkTriggererActive)
|
||||
return;
|
||||
|
||||
short triggerType = (*(data++) >> 8) & TRIGGER_BITS;
|
||||
short flags = *(data++);
|
||||
short timer = flags & TIMER_BITS;
|
||||
|
@ -842,6 +846,10 @@ void TestTriggers(ItemInfo* item, bool isHeavy, int heavyFlags)
|
|||
short roomNumber = item->RoomNumber;
|
||||
auto floor = GetFloor(item->Pose.Position.x, item->Pose.Position.y, item->Pose.Position.z, &roomNumber);
|
||||
|
||||
// Don't process legacy triggers if triggerer flag was used in editor and trigger triggerer wasn't activated or used.
|
||||
if (floor->Flags.MarkTriggerer && !floor->Flags.MarkTriggererActive)
|
||||
return;
|
||||
|
||||
TestTriggers(item->Pose.Position.x, item->Pose.Position.y, item->Pose.Position.z, floor, (Activator)short(item->Index), isHeavy, heavyFlags);
|
||||
}
|
||||
|
||||
|
@ -850,7 +858,7 @@ void TestTriggers(int x, int y, int z, short roomNumber, bool heavy, int heavyFl
|
|||
auto roomNum = roomNumber;
|
||||
auto floor = GetFloor(x, y, z, &roomNum);
|
||||
|
||||
// Don't process legacy triggers if trigger triggerer wasn't used
|
||||
// Don't process legacy triggers if triggerer flag was used in editor and trigger triggerer wasn't activated or used.
|
||||
if (floor->Flags.MarkTriggerer && !floor->Flags.MarkTriggererActive)
|
||||
return;
|
||||
|
||||
|
|
|
@ -17,7 +17,7 @@ namespace TEN::Control::Volumes
|
|||
constexpr auto CAM_SIZE = 32;
|
||||
constexpr auto EVENT_STATE_MASK = SHRT_MAX;
|
||||
|
||||
bool TestVolumeContainment(const TriggerVolume& volume, const BoundingOrientedBox& box, short roomNumber)
|
||||
bool TestVolumeContainment(const TriggerVolume& volume, const BoundingOrientedBox& box, int roomNumber)
|
||||
{
|
||||
float color = !volume.StateQueue.empty() ? 1.0f : 0.4f;
|
||||
|
||||
|
@ -129,7 +129,7 @@ namespace TEN::Control::Volumes
|
|||
return true;
|
||||
}
|
||||
|
||||
void TestVolumes(short roomNumber, const BoundingOrientedBox& box, ActivatorFlags activatorFlag, Activator activator)
|
||||
void TestVolumes(int roomNumber, const BoundingOrientedBox& box, ActivatorFlags activatorFlag, Activator activator)
|
||||
{
|
||||
if (g_GameFlow->CurrentFreezeMode != FreezeMode::None)
|
||||
return;
|
||||
|
@ -152,7 +152,7 @@ namespace TEN::Control::Volumes
|
|||
if (!volume.DetectInAdjacentRooms && currentRoomIndex != roomNumber)
|
||||
continue;
|
||||
|
||||
if (volume.EventSetIndex == NO_EVENT_SET)
|
||||
if (volume.EventSetIndex == NO_VALUE)
|
||||
continue;
|
||||
|
||||
auto& set = g_Level.VolumeEventSets[volume.EventSetIndex];
|
||||
|
@ -233,18 +233,17 @@ namespace TEN::Control::Volumes
|
|||
TestVolumes(camera->pos.RoomNumber, box, ActivatorFlags::Flyby, camera);
|
||||
}
|
||||
|
||||
void TestVolumes(short roomNumber, MESH_INFO* mesh)
|
||||
void TestVolumes(int roomNumber, MESH_INFO* mesh)
|
||||
{
|
||||
auto box = GetBoundsAccurate(*mesh, false).ToBoundingOrientedBox(mesh->pos);
|
||||
|
||||
TestVolumes(roomNumber, box, ActivatorFlags::Static, mesh);
|
||||
}
|
||||
|
||||
void TestVolumes(short itemNumber, const CollisionSetupData* coll)
|
||||
void TestVolumes(int itemNumber, const CollisionSetupData* coll)
|
||||
{
|
||||
auto& item = g_Level.Items[itemNumber];
|
||||
auto box = (coll != nullptr) ?
|
||||
ConstructRoughBox(item, *coll) : GameBoundingBox(&item).ToBoundingOrientedBox(item.Pose);
|
||||
auto box = (coll != nullptr) ? ConstructRoughBox(item, *coll) : GameBoundingBox(&item).ToBoundingOrientedBox(item.Pose);
|
||||
|
||||
DrawDebugBox(box, Vector4(1.0f, 1.0f, 0.0f, 1.0f), RendererDebugPage::CollisionStats);
|
||||
|
||||
|
|
|
@ -8,8 +8,6 @@ struct CollisionSetupData;
|
|||
|
||||
namespace TEN::Control::Volumes
|
||||
{
|
||||
constexpr auto NO_EVENT_SET = -1;
|
||||
|
||||
constexpr auto VOLUME_BUSY_TIMEOUT = 10;
|
||||
constexpr auto VOLUME_LEAVE_TIMEOUT = 5;
|
||||
|
||||
|
@ -38,9 +36,9 @@ namespace TEN::Control::Volumes
|
|||
int Timestamp = 0;
|
||||
};
|
||||
|
||||
void TestVolumes(short roomNumber, const BoundingOrientedBox& box, ActivatorFlags activatorFlag, Activator activator);
|
||||
void TestVolumes(short itemNumber, const CollisionSetupData* coll = nullptr);
|
||||
void TestVolumes(short roomNumber, MESH_INFO* mesh);
|
||||
void TestVolumes(int roomNumber, const BoundingOrientedBox& box, ActivatorFlags activatorFlag, Activator activator);
|
||||
void TestVolumes(int itemNumber, const CollisionSetupData* coll = nullptr);
|
||||
void TestVolumes(int roomNumber, MESH_INFO* mesh);
|
||||
void TestVolumes(CAMERA_INFO* camera);
|
||||
|
||||
bool HandleEvent(Event& event, Activator& activator);
|
||||
|
|
|
@ -44,7 +44,7 @@ namespace TEN::Debug
|
|||
if (prevString == msg && !allowSpam)
|
||||
return;
|
||||
|
||||
if constexpr (!DebugBuild)
|
||||
if constexpr (!DEBUG_BUILD)
|
||||
{
|
||||
if (config == LogConfig::Debug)
|
||||
return;
|
||||
|
|
|
@ -9,9 +9,9 @@
|
|||
namespace TEN::Debug
|
||||
{
|
||||
#if _DEBUG
|
||||
constexpr bool DebugBuild = true;
|
||||
constexpr auto DEBUG_BUILD = true;
|
||||
#else
|
||||
constexpr bool DebugBuild = false;
|
||||
constexpr auto DEBUG_BUILD = false;
|
||||
#endif
|
||||
|
||||
enum class LogLevel
|
||||
|
@ -41,7 +41,7 @@ namespace TEN::Debug
|
|||
|
||||
inline void TENAssert(const bool& cond, const std::string& msg)
|
||||
{
|
||||
if constexpr (DebugBuild)
|
||||
if constexpr (DEBUG_BUILD)
|
||||
{
|
||||
if (!cond)
|
||||
{
|
||||
|
|
|
@ -2,11 +2,13 @@
|
|||
#include "Game/effects/Electricity.h"
|
||||
|
||||
#include "Game/effects/effects.h"
|
||||
#include "Game/effects/spark.h"
|
||||
#include "Game/people.h"
|
||||
#include "Game/Setup.h"
|
||||
#include "Math/Math.h"
|
||||
|
||||
using namespace TEN::Math;
|
||||
using namespace TEN::Effects::Spark;
|
||||
|
||||
namespace TEN::Effects::Electricity
|
||||
{
|
||||
|
@ -83,7 +85,7 @@ namespace TEN::Effects::Electricity
|
|||
fmod(Random::GenerateInt(), amplitude),
|
||||
fmod(Random::GenerateInt(), amplitude),
|
||||
fmod(Random::GenerateInt(), amplitude)) -
|
||||
Vector3(amplitude/ 2);
|
||||
Vector3(amplitude / 2);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -107,7 +109,8 @@ namespace TEN::Effects::Electricity
|
|||
auto& spark = *GetFreeParticle();
|
||||
|
||||
spark.on = true;
|
||||
spark.spriteIndex = Objects[ID_MISC_SPRITES].meshIndex;
|
||||
spark.SpriteSeqID = ID_MISC_SPRITES;
|
||||
spark.SpriteID = 0;
|
||||
spark.blendMode = BlendMode::Additive;
|
||||
spark.x = pos.x;
|
||||
spark.y = pos.y;
|
||||
|
@ -134,18 +137,52 @@ namespace TEN::Effects::Electricity
|
|||
spark.flags = SP_DEF | SP_SCALE;
|
||||
}
|
||||
|
||||
void SpawnElectricEffect(const ItemInfo& item, int jointNumber, const Vector3i& offset, const float spawnRadius, float beamOriginRadius, float beamTargetRadius, int frequency, const Vector3& pos)
|
||||
{
|
||||
// TODO: Make electric effect correctly spawn randomly on any mesh bounds surface and water surfaces. -- Tomo
|
||||
|
||||
int randomIndex = Random::GenerateInt(0, 100);
|
||||
auto pos1 = Vector3::Zero;
|
||||
|
||||
if (randomIndex < frequency)
|
||||
{
|
||||
if (pos != Vector3::Zero)
|
||||
{
|
||||
pos1 = pos + offset.ToVector3();
|
||||
}
|
||||
else
|
||||
{
|
||||
pos1 = GetJointPosition(item, jointNumber, offset).ToVector3();
|
||||
}
|
||||
|
||||
auto sphere = BoundingSphere(pos1, spawnRadius);
|
||||
auto pos2 = Random::GeneratePointOnSphere(sphere);
|
||||
|
||||
SpawnElectricityGlow(pos2, 28, 32, 32, 64);
|
||||
|
||||
SpawnCyborgSpark(pos2);
|
||||
SpawnDynamicLight(pos2.x, pos2.y, pos2.z, Random::GenerateInt(4, 8), 31, 63, 127);
|
||||
|
||||
sphere = BoundingSphere(pos1, beamOriginRadius);
|
||||
auto sphere1 = BoundingSphere(pos1, beamTargetRadius);
|
||||
pos1 = Random::GeneratePointOnSphere(sphere);
|
||||
pos2 = Random::GeneratePointOnSphere(sphere1);
|
||||
|
||||
SpawnElectricity(pos1, pos2, Random::GenerateInt(8, 16), 32, 64, 128, 24, (int)ElectricityFlags::Spline | (int)ElectricityFlags::ThinOut | (int)ElectricityFlags::ThinIn, 6, 8);
|
||||
}
|
||||
}
|
||||
|
||||
void SpawnHelicalLaser(const Vector3& origin, const Vector3& target)
|
||||
{
|
||||
constexpr auto SEGMENTS_NUM_MAX = 128;
|
||||
constexpr auto SEGMENT_COUNT_MAX = 128;
|
||||
constexpr auto COLOR = Vector4(0.0f, 0.375f, 1.0f, 1.0f);
|
||||
constexpr auto LENGTH_MAX = BLOCK(4);
|
||||
constexpr auto ROTATION = ANGLE(-10.0f);
|
||||
|
||||
constexpr auto ROT = ANGLE(-10.0f);
|
||||
constexpr auto ELECTRICITY_FLAGS = (int)ElectricityFlags::ThinIn | (int)ElectricityFlags::ThinOut;
|
||||
|
||||
auto laser = HelicalLaser();
|
||||
|
||||
laser.NumSegments = SEGMENTS_NUM_MAX;
|
||||
laser.NumSegments = SEGMENT_COUNT_MAX;
|
||||
laser.Origin = origin;
|
||||
laser.Target = target;
|
||||
laser.Orientation2D = Random::GenerateAngle();
|
||||
|
@ -156,7 +193,7 @@ namespace TEN::Effects::Electricity
|
|||
laser.Length = LENGTH_MAX / 2;
|
||||
laser.LengthEnd = LENGTH_MAX;
|
||||
laser.Opacity = 1.0f;
|
||||
laser.Rotation = ROTATION;
|
||||
laser.Rotation = ROT;
|
||||
|
||||
HelicalLasers.push_back(laser);
|
||||
|
||||
|
|
|
@ -108,9 +108,9 @@ namespace TEN::Effects::Electricity
|
|||
extern std::array<Vector3, ELECTRICITY_BUFFER_SIZE> ElectricityBuffer;
|
||||
|
||||
void SpawnElectricity(const Vector3& origin, const Vector3& target, float amplitude, byte r, byte g, byte b, float life, int flags, float width, unsigned int numSegments);
|
||||
void SpawnElectricEffect(const ItemInfo& item, int jointNumber, const Vector3i& offset, const float spawnRadius, float beamOriginRadius, float beamTargetRadius, int frequency, const Vector3& pos);
|
||||
void SpawnElectricityGlow(const Vector3& pos, float scale, byte r, byte g, byte b);
|
||||
void SpawnHelicalLaser(const Vector3& origin, const Vector3& target);
|
||||
|
||||
void UpdateElectricityArcs();
|
||||
void UpdateHelicalLasers();
|
||||
|
||||
|
|
145
TombEngine/Game/effects/Splash.cpp
Normal file
145
TombEngine/Game/effects/Splash.cpp
Normal file
|
@ -0,0 +1,145 @@
|
|||
#include "framework.h"
|
||||
#include "Game/effects/Splash.h"
|
||||
|
||||
#include "Game/collision/Point.h"
|
||||
#include "Game/effects/Drip.h"
|
||||
#include "Game/room.h"
|
||||
#include "Sound/sound.h"
|
||||
|
||||
using namespace TEN::Collision::Point;
|
||||
using namespace TEN::Effects::Drip;
|
||||
|
||||
namespace TEN::Effects::Splash
|
||||
{
|
||||
int SplashCount;
|
||||
SplashEffectSetup SplashSetup;
|
||||
std::array<SplashEffect, SPLASH_EFFECT_COUNT_MAX> SplashEffects;
|
||||
|
||||
void SetupSplash(const SplashEffectSetup* const setup, int room)
|
||||
{
|
||||
constexpr auto SETUP_COUNT_MAX = 3;
|
||||
|
||||
int splashSetupCount = 0;
|
||||
float splashVel = 0.0f;
|
||||
|
||||
for (auto& splash : SplashEffects)
|
||||
{
|
||||
if (splash.isActive)
|
||||
continue;
|
||||
|
||||
if (splashSetupCount == 0)
|
||||
{
|
||||
float splashPower = std::min(256.0f, setup->SplashPower);
|
||||
|
||||
splash.isActive = true;
|
||||
splash.Position = setup->Position;
|
||||
splash.life = 62;
|
||||
splash.isRipple = false;
|
||||
splash.InnerRadius = setup->InnerRadius;
|
||||
splashVel = splashPower / 16;
|
||||
splash.InnerRadialVel = splashVel;
|
||||
splash.HeightSpeed = splashPower * 1.2f;
|
||||
splash.height = 0;
|
||||
splash.HeightVel = -16;
|
||||
splash.OuterRadius = setup->InnerRadius / 3;
|
||||
splash.outerRadialVel = splashVel * 1.5f;
|
||||
splash.SpriteSeqStart = 8; // Splash texture.
|
||||
splashSetupCount++;
|
||||
}
|
||||
else
|
||||
{
|
||||
float thickness = Random::GenerateFloat(64, 128);
|
||||
|
||||
splash.isActive = true;
|
||||
splash.Position = setup->Position;
|
||||
splash.isRipple = true;
|
||||
float vel = 0.0f;
|
||||
|
||||
if (splashSetupCount == 2)
|
||||
{
|
||||
vel = (splashVel / 16) + Random::GenerateFloat(2, 4);
|
||||
}
|
||||
else
|
||||
{
|
||||
vel = (splashVel / 7) + Random::GenerateFloat(3, 7);
|
||||
}
|
||||
|
||||
splash.InnerRadius = 0.0f;
|
||||
splash.InnerRadialVel = vel * 1.3f;
|
||||
splash.OuterRadius = thickness;
|
||||
splash.outerRadialVel = vel * 2.3f;
|
||||
splash.HeightSpeed = 128;
|
||||
splash.height = 0;
|
||||
splash.HeightVel = -16;
|
||||
|
||||
float alpha = (vel / (splashVel / 2)) + 16;
|
||||
alpha = std::max(0.0f, std::min(alpha, 1.0f));
|
||||
|
||||
splash.life = Lerp(48.0f, 70.0f, alpha);
|
||||
splash.SpriteSeqStart = 4; // Splash texture.
|
||||
splash.SpriteSeqEnd = 7; // Splash texture.
|
||||
splash.AnimSpeed = fmin(0.6f, (1 / splash.outerRadialVel) * 2);
|
||||
|
||||
splashSetupCount++;
|
||||
}
|
||||
|
||||
if (splashSetupCount == SETUP_COUNT_MAX)
|
||||
break;
|
||||
}
|
||||
|
||||
SpawnSplashDrips(Vector3(setup->Position.x, setup->Position.y - 15, setup->Position.z), room, 32);
|
||||
|
||||
auto soundPose = Pose(Vector3i(setup->Position));
|
||||
SoundEffect(SFX_TR4_LARA_SPLASH, &soundPose);
|
||||
}
|
||||
|
||||
void UpdateSplashes()
|
||||
{
|
||||
if (SplashCount)
|
||||
SplashCount--;
|
||||
|
||||
for (auto& splash : SplashEffects)
|
||||
{
|
||||
if (splash.isActive)
|
||||
{
|
||||
splash.StoreInterpolationData();
|
||||
|
||||
splash.life--;
|
||||
if (splash.life <= 0)
|
||||
splash.isActive = false;
|
||||
|
||||
splash.HeightSpeed += splash.HeightVel;
|
||||
splash.height += splash.HeightSpeed;
|
||||
|
||||
if (splash.height < 0)
|
||||
{
|
||||
splash.height = 0;
|
||||
if (!splash.isRipple)
|
||||
splash.isActive = false;
|
||||
}
|
||||
|
||||
splash.InnerRadius += splash.InnerRadialVel;
|
||||
splash.OuterRadius += splash.outerRadialVel;
|
||||
splash.AnimPhase += splash.AnimSpeed;
|
||||
|
||||
int sequenceLength = splash.SpriteSeqEnd - splash.SpriteSeqStart;
|
||||
if (splash.AnimPhase > sequenceLength)
|
||||
splash.AnimPhase = fmod(splash.AnimPhase, sequenceLength);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
void Splash(ItemInfo* item)
|
||||
{
|
||||
int probedRoomNumber = GetPointCollision(*item).GetRoomNumber();
|
||||
if (!TestEnvironment(ENV_FLAG_WATER, probedRoomNumber))
|
||||
return;
|
||||
|
||||
int waterHeight = GetPointCollision(*item).GetWaterTopHeight();
|
||||
|
||||
SplashSetup.Position = Vector3(item->Pose.Position.x, waterHeight - 1, item->Pose.Position.z);
|
||||
SplashSetup.SplashPower = item->Animation.Velocity.y;
|
||||
SplashSetup.InnerRadius = 64;
|
||||
SetupSplash(&SplashSetup, probedRoomNumber);
|
||||
}
|
||||
}
|
64
TombEngine/Game/effects/Splash.h
Normal file
64
TombEngine/Game/effects/Splash.h
Normal file
|
@ -0,0 +1,64 @@
|
|||
#pragma once
|
||||
|
||||
namespace TEN::Effects::Splash
|
||||
{
|
||||
constexpr auto SPLASH_EFFECT_COUNT_MAX = 8;
|
||||
|
||||
// TODO: Refactor everything here to use new effect handling patterns.
|
||||
|
||||
struct SplashEffectSetup
|
||||
{
|
||||
Vector3 Position = Vector3::Zero;
|
||||
int RoomNumber = 0;
|
||||
float SplashPower = 0.0f;
|
||||
float InnerRadius = 0.0f;
|
||||
};
|
||||
|
||||
struct SplashEffect
|
||||
{
|
||||
Vector3 Position = Vector3::Zero;
|
||||
|
||||
bool isRipple;
|
||||
bool isActive;
|
||||
|
||||
float InnerRadius;
|
||||
float InnerRadialVel;
|
||||
float HeightVel;
|
||||
float HeightSpeed;
|
||||
float height;
|
||||
float OuterRadius;
|
||||
float outerRadialVel;
|
||||
float AnimSpeed;
|
||||
float AnimPhase;
|
||||
int SpriteSeqStart;
|
||||
int SpriteSeqEnd;
|
||||
unsigned int life;
|
||||
|
||||
Vector3 PrevPosition = Vector3::Zero;
|
||||
float PrevInnerRadius = 0.0f;
|
||||
float PrevOuterRadius = 0.0f;
|
||||
float PrevHeight = 0.0f;
|
||||
float PrevHeightSpeed = 0.0f;
|
||||
float PrevAnimPhase = 0.0f;
|
||||
unsigned int PrevLife = 0;
|
||||
|
||||
void StoreInterpolationData()
|
||||
{
|
||||
PrevPosition = Position;
|
||||
PrevInnerRadius = InnerRadius;
|
||||
PrevOuterRadius = OuterRadius;
|
||||
PrevHeight = height;
|
||||
PrevHeightSpeed = HeightSpeed;
|
||||
PrevAnimPhase = AnimPhase;
|
||||
PrevLife = life;
|
||||
}
|
||||
};
|
||||
|
||||
extern int SplashCount;
|
||||
extern SplashEffectSetup SplashSetup;
|
||||
extern std::array<SplashEffect, SPLASH_EFFECT_COUNT_MAX> SplashEffects;
|
||||
|
||||
void SetupSplash(const SplashEffectSetup* const setup, int room);
|
||||
void UpdateSplashes();
|
||||
void Splash(ItemInfo* item);
|
||||
}
|
|
@ -18,6 +18,7 @@ namespace TEN::Effects::Streamer
|
|||
{
|
||||
private:
|
||||
// Constants
|
||||
|
||||
static constexpr auto SEGMENT_COUNT_MAX = 128;
|
||||
|
||||
public:
|
||||
|
@ -55,17 +56,20 @@ namespace TEN::Effects::Streamer
|
|||
}
|
||||
};
|
||||
|
||||
// Members
|
||||
// Fields
|
||||
|
||||
bool IsBroken = false;
|
||||
std::vector<StreamerSegment> Segments = {};
|
||||
|
||||
// Utilities
|
||||
|
||||
void AddSegment(const Vector3& pos, const Vector3& dir, short orient, const Vector4& color,
|
||||
float width, float life, float vel, float scaleRate, short rot, int flags, unsigned int segmentCount);
|
||||
void Update();
|
||||
|
||||
private:
|
||||
// Helpers
|
||||
|
||||
StreamerSegment& GetNewSegment();
|
||||
};
|
||||
|
||||
|
@ -73,20 +77,24 @@ namespace TEN::Effects::Streamer
|
|||
{
|
||||
private:
|
||||
// Constants
|
||||
|
||||
static constexpr auto POOL_COUNT_MAX = 8;
|
||||
static constexpr auto STREAMER_COUNT_MAX = 8;
|
||||
|
||||
public:
|
||||
// Members
|
||||
|
||||
std::unordered_map<int, std::vector<Streamer>> Pools = {}; // Key = tag.
|
||||
|
||||
// Utilities
|
||||
|
||||
void AddStreamer(int tag, const Vector3& pos, const Vector3& dir, short orient, const Vector4& color,
|
||||
float width, float life, float vel, float scaleRate, short rot, int flags);
|
||||
void Update();
|
||||
|
||||
private:
|
||||
// Helpers
|
||||
|
||||
std::vector<Streamer>& GetPool(int tag);
|
||||
Streamer& GetStreamer(int tag);
|
||||
void ClearInactivePools();
|
||||
|
@ -97,13 +105,16 @@ namespace TEN::Effects::Streamer
|
|||
{
|
||||
private:
|
||||
// Constants
|
||||
|
||||
static constexpr auto MODULE_COUNT_MAX = 64;
|
||||
|
||||
public:
|
||||
// Members
|
||||
// Fields
|
||||
|
||||
std::unordered_map<int, StreamerModule> Modules = {}; // Key = item number.
|
||||
|
||||
// Utilities
|
||||
|
||||
void Spawn(int itemNumber, int tag, const Vector3& pos, const Vector3& dir, short orient, const Vector4& color,
|
||||
float width, float life, float vel, float scaleRate, short rot, int flags = 0);
|
||||
void Update();
|
||||
|
@ -111,6 +122,7 @@ namespace TEN::Effects::Streamer
|
|||
|
||||
private:
|
||||
// Helpers
|
||||
|
||||
StreamerModule& GetModule(int itemNumber);
|
||||
void ClearInactiveModules();
|
||||
};
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
|
||||
#include "Scripting/Include/Flow/ScriptInterfaceFlowHandler.h"
|
||||
#include "Game/animation.h"
|
||||
#include "Game/control/box.h"
|
||||
#include "Game/control/los.h"
|
||||
#include "Game/collision/collide_room.h"
|
||||
#include "Game/collision/Point.h"
|
||||
#include "Game/effects/Blood.h"
|
||||
|
@ -14,6 +16,7 @@
|
|||
#include "Game/effects/Ripple.h"
|
||||
#include "Game/effects/smoke.h"
|
||||
#include "Game/effects/spark.h"
|
||||
#include "Game/effects/Splash.h"
|
||||
#include "Game/effects/tomb4fx.h"
|
||||
#include "Game/effects/weather.h"
|
||||
#include "Game/items.h"
|
||||
|
@ -22,6 +25,7 @@
|
|||
#include "Game/Setup.h"
|
||||
#include "Math/Math.h"
|
||||
#include "Objects/objectslist.h"
|
||||
#include "Objects/TR5/Emitter/Waterfall.h"
|
||||
#include "Renderer/Renderer.h"
|
||||
#include "Sound/sound.h"
|
||||
#include "Specific/clock.h"
|
||||
|
@ -37,6 +41,8 @@ using namespace TEN::Effects::Items;
|
|||
using namespace TEN::Effects::Light;
|
||||
using namespace TEN::Effects::Ripple;
|
||||
using namespace TEN::Effects::Spark;
|
||||
using namespace TEN::Effects::Splash;
|
||||
using namespace TEN::Effects::WaterfallEmitter;
|
||||
using namespace TEN::Math;
|
||||
using namespace TEN::Math::Random;
|
||||
|
||||
|
@ -52,10 +58,7 @@ ParticleDynamic ParticleDynamics[MAX_PARTICLE_DYNAMICS];
|
|||
FX_INFO EffectList[MAX_SPAWNED_ITEM_COUNT];
|
||||
|
||||
GameBoundingBox DeadlyBounds;
|
||||
SPLASH_SETUP SplashSetup;
|
||||
SPLASH_STRUCT Splashes[MAX_SPLASHES];
|
||||
|
||||
int SplashCount = 0;
|
||||
int Wibble = 0;
|
||||
|
||||
Vector3i NodeVectors[ParticleNodeOffsetIDs::NodeMax];
|
||||
|
@ -158,7 +161,8 @@ Particle* GetFreeParticle()
|
|||
}
|
||||
|
||||
auto& part = Particles[partID];
|
||||
part.spriteIndex = Objects[ID_DEFAULT_SPRITES].meshIndex;
|
||||
part.SpriteSeqID = ID_DEFAULT_SPRITES;
|
||||
part.SpriteID = 0;
|
||||
part.blendMode = BlendMode::Additive;
|
||||
part.extras = 0;
|
||||
part.dynamic = NO_VALUE;
|
||||
|
@ -178,16 +182,16 @@ void SetSpriteSequence(Particle& particle, GAME_OBJECT_ID objectID)
|
|||
if (particleAge > particle.life )
|
||||
return;
|
||||
|
||||
int numSprites = -Objects[objectID].nmeshes - 1;
|
||||
int spriteCount = -Objects[objectID].nmeshes - 1;
|
||||
float normalizedAge = particleAge / particle.life;
|
||||
particle.spriteIndex = Objects[objectID].meshIndex + (int)round(Lerp(0.0f, numSprites, normalizedAge));
|
||||
particle.SpriteSeqID = objectID;
|
||||
particle.SpriteID = (int)round(Lerp(0.0f, spriteCount, normalizedAge));
|
||||
}
|
||||
|
||||
void UpdateWibble()
|
||||
{
|
||||
// Update oscillator seed.
|
||||
Wibble = (Wibble + WIBBLE_SPEED) & WIBBLE_MAX;
|
||||
|
||||
}
|
||||
|
||||
void UpdateSparks()
|
||||
|
@ -203,69 +207,72 @@ void UpdateSparks()
|
|||
|
||||
for (int i = 0; i < MAX_PARTICLES; i++)
|
||||
{
|
||||
auto* spark = &Particles[i];
|
||||
auto& spark = Particles[i];
|
||||
|
||||
if (spark->on)
|
||||
if (spark.on)
|
||||
{
|
||||
spark->StoreInterpolationData();
|
||||
spark.StoreInterpolationData();
|
||||
|
||||
spark->life--;
|
||||
spark.life--;
|
||||
|
||||
if (!spark->life)
|
||||
if (!spark.life)
|
||||
{
|
||||
if (spark->dynamic != -1)
|
||||
ParticleDynamics[spark->dynamic].On = false;
|
||||
if (spark.dynamic != -1)
|
||||
ParticleDynamics[spark.dynamic].On = false;
|
||||
|
||||
spark->on = false;
|
||||
spark.on = false;
|
||||
continue;
|
||||
}
|
||||
|
||||
int life = spark->sLife - spark->life;
|
||||
if (life < spark->colFadeSpeed)
|
||||
if (HandleWaterfallParticle(spark))
|
||||
continue;
|
||||
|
||||
int life = spark.sLife - spark.life;
|
||||
if (life < spark.colFadeSpeed)
|
||||
{
|
||||
int dl = (life << 16) / spark->colFadeSpeed;
|
||||
spark->r = spark->sR + (dl * (spark->dR - spark->sR) >> 16);
|
||||
spark->g = spark->sG + (dl * (spark->dG - spark->sG) >> 16);
|
||||
spark->b = spark->sB + (dl * (spark->dB - spark->sB) >> 16);
|
||||
int dl = (life << 16) / spark.colFadeSpeed;
|
||||
spark.r = spark.sR + (dl * (spark.dR - spark.sR) >> 16);
|
||||
spark.g = spark.sG + (dl * (spark.dG - spark.sG) >> 16);
|
||||
spark.b = spark.sB + (dl * (spark.dB - spark.sB) >> 16);
|
||||
}
|
||||
else if (spark->life >= spark->fadeToBlack)
|
||||
else if (spark.life >= spark.fadeToBlack)
|
||||
{
|
||||
spark->r = spark->dR;
|
||||
spark->g = spark->dG;
|
||||
spark->b = spark->dB;
|
||||
spark.r = spark.dR;
|
||||
spark.g = spark.dG;
|
||||
spark.b = spark.dB;
|
||||
}
|
||||
else
|
||||
{
|
||||
spark->r = (spark->dR * (((spark->life - spark->fadeToBlack) << 16) / spark->fadeToBlack + 0x10000)) >> 16;
|
||||
spark->g = (spark->dG * (((spark->life - spark->fadeToBlack) << 16) / spark->fadeToBlack + 0x10000)) >> 16;
|
||||
spark->b = (spark->dB * (((spark->life - spark->fadeToBlack) << 16) / spark->fadeToBlack + 0x10000)) >> 16;
|
||||
spark.r = (spark.dR * (((spark.life - spark.fadeToBlack) << 16) / spark.fadeToBlack + 0x10000)) >> 16;
|
||||
spark.g = (spark.dG * (((spark.life - spark.fadeToBlack) << 16) / spark.fadeToBlack + 0x10000)) >> 16;
|
||||
spark.b = (spark.dB * (((spark.life - spark.fadeToBlack) << 16) / spark.fadeToBlack + 0x10000)) >> 16;
|
||||
|
||||
if (spark->r < 8 && spark->g < 8 && spark->b < 8)
|
||||
if (spark.r < 8 && spark.g < 8 && spark.b < 8)
|
||||
{
|
||||
spark->on = 0;
|
||||
spark.on = 0;
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
if (spark->life == spark->colFadeSpeed)
|
||||
if (spark.life == spark.colFadeSpeed)
|
||||
{
|
||||
if (spark->flags & SP_UNDERWEXP)
|
||||
spark->dSize /= 4;
|
||||
if (spark.flags & SP_UNDERWEXP)
|
||||
spark.dSize /= 4;
|
||||
}
|
||||
|
||||
if (spark->flags & SP_ROTATE)
|
||||
spark->rotAng = (spark->rotAng + spark->rotAdd) & 0x0FFF;
|
||||
if (spark.flags & SP_ROTATE)
|
||||
spark.rotAng = (spark.rotAng + spark.rotAdd) & 0x0FFF;
|
||||
|
||||
if (spark->sLife - spark->life == spark->extras >> 3 &&
|
||||
spark->extras & 7)
|
||||
if (spark.sLife - spark.life == spark.extras >> 3 &&
|
||||
spark.extras & 7)
|
||||
{
|
||||
int explosionType;
|
||||
|
||||
if (spark->flags & SP_UNDERWEXP)
|
||||
if (spark.flags & SP_UNDERWEXP)
|
||||
{
|
||||
explosionType = 1;
|
||||
}
|
||||
else if (spark->flags & SP_PLASMAEXP)
|
||||
else if (spark.flags & SP_PLASMAEXP)
|
||||
{
|
||||
explosionType = 2;
|
||||
}
|
||||
|
@ -274,95 +281,95 @@ void UpdateSparks()
|
|||
explosionType = 0;
|
||||
}
|
||||
|
||||
for (int j = 0; j < (spark->extras & 7); j++)
|
||||
for (int j = 0; j < (spark.extras & 7); j++)
|
||||
{
|
||||
if (spark->flags & SP_COLOR)
|
||||
if (spark.flags & SP_COLOR)
|
||||
{
|
||||
TriggerExplosionSparks(
|
||||
spark->x, spark->y, spark->z,
|
||||
(spark->extras & 7) - 1,
|
||||
spark->dynamic,
|
||||
spark.x, spark.y, spark.z,
|
||||
(spark.extras & 7) - 1,
|
||||
spark.dynamic,
|
||||
explosionType,
|
||||
spark->roomNumber,
|
||||
Vector3(spark->dR, spark->dG, spark->dB),
|
||||
Vector3(spark->sR, spark->sG, spark->sB));
|
||||
spark.roomNumber,
|
||||
Vector3(spark.dR, spark.dG, spark.dB),
|
||||
Vector3(spark.sR, spark.sG, spark.sB));
|
||||
}
|
||||
else
|
||||
{
|
||||
TriggerExplosionSparks(
|
||||
spark->x, spark->y, spark->z,
|
||||
(spark->extras & 7) - 1,
|
||||
spark->dynamic,
|
||||
spark.x, spark.y, spark.z,
|
||||
(spark.extras & 7) - 1,
|
||||
spark.dynamic,
|
||||
explosionType,
|
||||
spark->roomNumber);
|
||||
spark.roomNumber);
|
||||
}
|
||||
|
||||
spark->dynamic = -1;
|
||||
spark.dynamic = -1;
|
||||
}
|
||||
|
||||
if (explosionType == 1)
|
||||
{
|
||||
TriggerExplosionBubble(
|
||||
spark->x,
|
||||
spark->y,
|
||||
spark->z,
|
||||
spark->roomNumber);
|
||||
spark.x,
|
||||
spark.y,
|
||||
spark.z,
|
||||
spark.roomNumber);
|
||||
}
|
||||
|
||||
spark->extras = 0;
|
||||
spark.extras = 0;
|
||||
}
|
||||
|
||||
spark->yVel += spark->gravity;
|
||||
if (spark->maxYvel)
|
||||
spark.yVel += spark.gravity;
|
||||
if (spark.maxYvel)
|
||||
{
|
||||
if (spark->yVel > spark->maxYvel)
|
||||
spark->yVel = spark->maxYvel;
|
||||
if (spark.yVel > spark.maxYvel)
|
||||
spark.yVel = spark.maxYvel;
|
||||
}
|
||||
|
||||
if (spark->friction & 0xF)
|
||||
if (spark.friction & 0xF)
|
||||
{
|
||||
spark->xVel -= spark->xVel >> (spark->friction & 0xF);
|
||||
spark->zVel -= spark->zVel >> (spark->friction & 0xF);
|
||||
spark.xVel -= spark.xVel >> (spark.friction & 0xF);
|
||||
spark.zVel -= spark.zVel >> (spark.friction & 0xF);
|
||||
}
|
||||
|
||||
if (spark->friction & 0xF0)
|
||||
spark->yVel -= spark->yVel >> (spark->friction >> 4);
|
||||
if (spark.friction & 0xF0)
|
||||
spark.yVel -= spark.yVel >> (spark.friction >> 4);
|
||||
|
||||
spark->x += spark->xVel >> 5;
|
||||
spark->y += spark->yVel >> 5;
|
||||
spark->z += spark->zVel >> 5;
|
||||
spark.x += spark.xVel >> 5;
|
||||
spark.y += spark.yVel >> 5;
|
||||
spark.z += spark.zVel >> 5;
|
||||
|
||||
if (spark->flags & SP_WIND)
|
||||
if (spark.flags & SP_WIND)
|
||||
{
|
||||
spark->x += Weather.Wind().x;
|
||||
spark->z += Weather.Wind().z;
|
||||
spark.x += Weather.Wind().x;
|
||||
spark.z += Weather.Wind().z;
|
||||
}
|
||||
|
||||
int dl = ((spark->sLife - spark->life) * 65536) / spark->sLife;
|
||||
spark->size = (spark->sSize + ((dl * (spark->dSize - spark->sSize)) / 65536));
|
||||
int dl = ((spark.sLife - spark.life) * 65536) / spark.sLife;
|
||||
spark.size = (spark.sSize + ((dl * (spark.dSize - spark.sSize)) / 65536));
|
||||
|
||||
if (spark->flags & SP_EXPLOSION)
|
||||
SetSpriteSequence(*spark, ID_EXPLOSION_SPRITES);
|
||||
if (spark.flags & SP_EXPLOSION)
|
||||
SetSpriteSequence(spark, ID_EXPLOSION_SPRITES);
|
||||
|
||||
if ((spark->flags & SP_FIRE && LaraItem->Effect.Type == EffectType::None) ||
|
||||
(spark->flags & SP_DAMAGE) ||
|
||||
(spark->flags & SP_POISON))
|
||||
if ((spark.flags & SP_FIRE && LaraItem->Effect.Type == EffectType::None) ||
|
||||
(spark.flags & SP_DAMAGE) ||
|
||||
(spark.flags & SP_POISON))
|
||||
{
|
||||
int ds = spark->size * (spark->scalar / 2.0);
|
||||
int ds = spark.size * (spark.scalar / 2.0);
|
||||
|
||||
if (spark->x + ds > DeadlyBounds.X1 && spark->x - ds < DeadlyBounds.X2)
|
||||
if (spark.x + ds > DeadlyBounds.X1 && spark.x - ds < DeadlyBounds.X2)
|
||||
{
|
||||
if (spark->y + ds > DeadlyBounds.Y1 && spark->y - ds < DeadlyBounds.Y2)
|
||||
if (spark.y + ds > DeadlyBounds.Y1 && spark.y - ds < DeadlyBounds.Y2)
|
||||
{
|
||||
if (spark->z + ds > DeadlyBounds.Z1 && spark->z - ds < DeadlyBounds.Z2)
|
||||
if (spark.z + ds > DeadlyBounds.Z1 && spark.z - ds < DeadlyBounds.Z2)
|
||||
{
|
||||
if (spark->flags & SP_FIRE)
|
||||
if (spark.flags & SP_FIRE)
|
||||
ItemBurn(LaraItem);
|
||||
|
||||
if (spark->flags & SP_DAMAGE)
|
||||
if (spark.flags & SP_DAMAGE)
|
||||
DoDamage(LaraItem, 2);
|
||||
|
||||
if (spark->flags & SP_POISON)
|
||||
if (spark.flags & SP_POISON)
|
||||
Lara.Status.Poison += 5;
|
||||
}
|
||||
}
|
||||
|
@ -371,25 +378,26 @@ void UpdateSparks()
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
for (int i = 0; i < MAX_PARTICLES; i++)
|
||||
{
|
||||
auto* spark = &Particles[i];
|
||||
auto& spark = Particles[i];
|
||||
|
||||
if (spark->on && spark->dynamic != -1)
|
||||
if (spark.on && spark.dynamic != -1)
|
||||
{
|
||||
auto* dynsp = &ParticleDynamics[spark->dynamic];
|
||||
auto* dynsp = &ParticleDynamics[spark.dynamic];
|
||||
|
||||
if (dynsp->Flags & 3)
|
||||
{
|
||||
int random = GetRandomControl();
|
||||
|
||||
int x = spark->x + 16 * (random & 0xF);
|
||||
int y = spark->y + (random & 0xF0);
|
||||
int z = spark->z + ((random >> 4) & 0xF0);
|
||||
int x = spark.x + 16 * (random & 0xF);
|
||||
int y = spark.y + (random & 0xF0);
|
||||
int z = spark.z + ((random >> 4) & 0xF0);
|
||||
|
||||
byte r, g, b;
|
||||
|
||||
int dl = spark->sLife - spark->life - 1;
|
||||
int dl = spark.sLife - spark.life - 1;
|
||||
if (dl >= 2)
|
||||
{
|
||||
if (dl >= 4)
|
||||
|
@ -424,7 +432,7 @@ void UpdateSparks()
|
|||
r = 255 - (dl << 6) - (random & 0x1F);
|
||||
}
|
||||
|
||||
if (spark->flags & SP_PLASMAEXP)
|
||||
if (spark.flags & SP_PLASMAEXP)
|
||||
{
|
||||
int falloff;
|
||||
if (dynsp->Falloff <= 28)
|
||||
|
@ -438,9 +446,9 @@ void UpdateSparks()
|
|||
{
|
||||
int falloff = (dynsp->Falloff <= 28) ? dynsp->Falloff : 31;
|
||||
|
||||
if (spark->flags & SP_COLOR)
|
||||
if (spark.flags & SP_COLOR)
|
||||
{
|
||||
SpawnDynamicLight(x, y, z, falloff, spark->dR, spark->dG, spark->dB);
|
||||
SpawnDynamicLight(x, y, z, falloff, spark.dR, spark.dG, spark.dB);
|
||||
}
|
||||
else
|
||||
{
|
||||
|
@ -757,7 +765,8 @@ void TriggerExplosionBubbles(int x, int y, int z, short roomNumber)
|
|||
spark->zVel = 0;
|
||||
spark->friction = 0;
|
||||
spark->flags = SP_UNDERWEXP | SP_DEF | SP_SCALE;
|
||||
spark->spriteIndex = Objects[ID_DEFAULT_SPRITES].meshIndex + SPR_BUBBLES;
|
||||
spark->SpriteSeqID = ID_DEFAULT_SPRITES;
|
||||
spark->SpriteID = SPR_BUBBLES;
|
||||
spark->scalar = 3;
|
||||
spark->gravity = 0;
|
||||
spark->maxYvel = 0;
|
||||
|
@ -969,123 +978,6 @@ void TriggerSuperJetFlame(ItemInfo* item, int yvel, int deadly)
|
|||
}
|
||||
}
|
||||
|
||||
void SetupSplash(const SPLASH_SETUP* const setup, int room)
|
||||
{
|
||||
constexpr size_t NUM_SPLASHES = 3;
|
||||
int numSplashesSetup = 0;
|
||||
float splashVelocity;
|
||||
|
||||
for (int i = 0; i < MAX_SPLASHES; i++)
|
||||
{
|
||||
SPLASH_STRUCT& splash = Splashes[i];
|
||||
|
||||
if (!splash.isActive)
|
||||
{
|
||||
if (numSplashesSetup == 0)
|
||||
{
|
||||
float splashPower = fmin(256, setup->splashPower);
|
||||
splash.isActive = true;
|
||||
splash.x = setup->x;
|
||||
splash.y = setup->y;
|
||||
splash.z = setup->z;
|
||||
splash.life = 62;
|
||||
splash.isRipple = false;
|
||||
splash.innerRad = setup->innerRadius;
|
||||
splashVelocity = splashPower / 16;
|
||||
splash.innerRadVel = splashVelocity;
|
||||
splash.heightSpeed = splashPower * 1.2f;
|
||||
splash.height = 0;
|
||||
splash.heightVel = -16;
|
||||
splash.outerRad = setup->innerRadius / 3;
|
||||
splash.outerRadVel = splashVelocity * 1.5f;
|
||||
splash.spriteSequenceStart = 8; // Splash texture.
|
||||
numSplashesSetup++;
|
||||
}
|
||||
else
|
||||
{
|
||||
float thickness = Random::GenerateFloat(64,128);
|
||||
splash.isActive = true;
|
||||
splash.x = setup->x;
|
||||
splash.y = setup->y;
|
||||
splash.z = setup->z;
|
||||
splash.isRipple = true;
|
||||
float vel;
|
||||
|
||||
if (numSplashesSetup == 2)
|
||||
vel = (splashVelocity / 16) + Random::GenerateFloat(2, 4);
|
||||
else
|
||||
vel = (splashVelocity / 7) + Random::GenerateFloat(3, 7);
|
||||
|
||||
float innerRadius = 0;
|
||||
splash.innerRad = innerRadius;
|
||||
splash.innerRadVel = vel * 1.3f;
|
||||
splash.outerRad = innerRadius+thickness;
|
||||
splash.outerRadVel = vel * 2.3f;
|
||||
splash.heightSpeed = 128;
|
||||
splash.height = 0;
|
||||
splash.heightVel = -16;
|
||||
|
||||
float t = vel / (splashVelocity / 2) + 16;
|
||||
t = fmax(0, fmin(t, 1));
|
||||
splash.life = Lerp(48.0f, 70.0f, t);
|
||||
splash.spriteSequenceStart = 4; // Splash texture.
|
||||
splash.spriteSequenceEnd = 7; // Splash texture.
|
||||
splash.animationSpeed = fmin(0.6f, (1 / splash.outerRadVel) * 2);
|
||||
|
||||
numSplashesSetup++;
|
||||
}
|
||||
|
||||
if (numSplashesSetup == NUM_SPLASHES)
|
||||
break;
|
||||
|
||||
continue;
|
||||
}
|
||||
}
|
||||
|
||||
SpawnSplashDrips(Vector3(setup->x, setup->y - 15, setup->z), room, 32);
|
||||
|
||||
auto soundPosition = Pose(Vector3i(setup->x, setup->y, setup->z));
|
||||
SoundEffect(SFX_TR4_LARA_SPLASH, &soundPosition);
|
||||
}
|
||||
|
||||
void UpdateSplashes()
|
||||
{
|
||||
if (SplashCount)
|
||||
SplashCount--;
|
||||
|
||||
for (int i = 0; i < MAX_SPLASHES; i++)
|
||||
{
|
||||
auto& splash = Splashes[i];
|
||||
|
||||
if (splash.isActive)
|
||||
{
|
||||
splash.StoreInterpolationData();
|
||||
|
||||
splash.life--;
|
||||
if (splash.life <= 0)
|
||||
splash.isActive = false;
|
||||
|
||||
splash.heightSpeed += splash.heightVel;
|
||||
splash.height += splash.heightSpeed;
|
||||
|
||||
if (splash.height < 0)
|
||||
{
|
||||
splash.height = 0;
|
||||
if (!splash.isRipple)
|
||||
splash.isActive = false;
|
||||
}
|
||||
|
||||
splash.innerRad += splash.innerRadVel;
|
||||
splash.outerRad += splash.outerRadVel;
|
||||
splash.animationPhase += splash.animationSpeed;
|
||||
short sequenceLength = splash.spriteSequenceEnd - splash.spriteSequenceStart;
|
||||
|
||||
if (splash.animationPhase > sequenceLength)
|
||||
splash.animationPhase = fmod(splash.animationPhase, sequenceLength);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
short DoBloodSplat(int x, int y, int z, short speed, short direction, short roomNumber)
|
||||
{
|
||||
short probedRoomNumber = GetPointCollision(Vector3i(x, y, z), roomNumber).GetRoomNumber();
|
||||
|
@ -1231,7 +1123,8 @@ void TriggerWaterfallMist(const ItemInfo& item)
|
|||
spark->sSize = spark->size = Random::GenerateInt(0, 3) * scale + size;
|
||||
spark->dSize = 2 * spark->size;
|
||||
|
||||
spark->spriteIndex = Objects[ID_DEFAULT_SPRITES].meshIndex + (Random::GenerateInt(0, 100) > 95 ? 17 : 0);
|
||||
spark->SpriteSeqID = ID_DEFAULT_SPRITES;
|
||||
spark->SpriteID = Random::GenerateInt(0, 100) > 95 ? 17 : 0;
|
||||
spark->flags = 538;
|
||||
|
||||
if (sign == 1)
|
||||
|
@ -1249,75 +1142,6 @@ void KillAllCurrentItems(short itemNumber)
|
|||
// TODO: Reimplement this functionality.
|
||||
}
|
||||
|
||||
void SpawnPlayerWaterSurfaceEffects(const ItemInfo& item, int waterHeight, int waterDepth)
|
||||
{
|
||||
const auto& player = GetLaraInfo(item);
|
||||
|
||||
// Player underwater; return early.
|
||||
if (player.Control.WaterStatus == WaterStatus::Underwater)
|
||||
return;
|
||||
|
||||
// Get point collision.
|
||||
auto pointColl0 = GetPointCollision(item, 0, 0, -(LARA_HEIGHT / 2));
|
||||
auto pointColl1 = GetPointCollision(item, 0, 0, item.Animation.Velocity.y);
|
||||
|
||||
// In swamp; return early.
|
||||
if (TestEnvironment(ENV_FLAG_SWAMP, pointColl1.GetRoomNumber()))
|
||||
return;
|
||||
|
||||
bool isWater0 = TestEnvironment(ENV_FLAG_WATER, pointColl0.GetRoomNumber());
|
||||
bool isWater1 = TestEnvironment(ENV_FLAG_WATER, pointColl1.GetRoomNumber());
|
||||
|
||||
// Spawn splash.
|
||||
if (!isWater0 && isWater1 &&
|
||||
item.Animation.Velocity.y > 0.0f && SplashCount == 0 &&
|
||||
player.Control.WaterStatus != WaterStatus::TreadWater)
|
||||
{
|
||||
SplashSetup.x = item.Pose.Position.x;
|
||||
SplashSetup.y = waterHeight - 1;
|
||||
SplashSetup.z = item.Pose.Position.z;
|
||||
SplashSetup.innerRadius = 16;
|
||||
SplashSetup.splashPower = item.Animation.Velocity.z;
|
||||
|
||||
SetupSplash(&SplashSetup, pointColl0.GetRoomNumber());
|
||||
SplashCount = 16;
|
||||
}
|
||||
// Spawn ripple.
|
||||
else if (isWater1)
|
||||
{
|
||||
if (Wibble & 0xF)
|
||||
return;
|
||||
|
||||
if (Random::TestProbability(1 / 2000.0f) && item.Animation.ActiveState == LS_IDLE)
|
||||
return;
|
||||
|
||||
int flags = (item.Animation.ActiveState == LS_IDLE) ?
|
||||
(int)RippleFlags::LowOpacity :
|
||||
(int)RippleFlags::SlowFade | (int)RippleFlags::LowOpacity;
|
||||
|
||||
SpawnRipple(
|
||||
Vector3(item.Pose.Position.x, waterHeight - 1, item.Pose.Position.z),
|
||||
item.RoomNumber, Random::GenerateFloat(112.0f, 128.0f),
|
||||
flags);
|
||||
}
|
||||
}
|
||||
|
||||
void Splash(ItemInfo* item)
|
||||
{
|
||||
int probedRoomNumber = GetPointCollision(*item).GetRoomNumber();
|
||||
if (!TestEnvironment(ENV_FLAG_WATER, probedRoomNumber))
|
||||
return;
|
||||
|
||||
int waterHeight = GetPointCollision(*item).GetWaterTopHeight();
|
||||
|
||||
SplashSetup.x = item->Pose.Position.x;
|
||||
SplashSetup.y = waterHeight - 1;
|
||||
SplashSetup.z = item->Pose.Position.z;
|
||||
SplashSetup.splashPower = item->Animation.Velocity.y;
|
||||
SplashSetup.innerRadius = 64;
|
||||
SetupSplash(&SplashSetup, probedRoomNumber);
|
||||
}
|
||||
|
||||
void TriggerRocketFlame(int x, int y, int z, int xv, int yv, int zv, int itemNumber)
|
||||
{
|
||||
auto* sptr = GetFreeParticle();
|
||||
|
@ -1368,7 +1192,8 @@ void TriggerRocketFlame(int x, int y, int z, int xv, int yv, int zv, int itemNum
|
|||
sptr->maxYvel = 0;
|
||||
|
||||
// TODO: right sprite
|
||||
sptr->spriteIndex = Objects[ID_DEFAULT_SPRITES].meshIndex;
|
||||
sptr->SpriteSeqID = ID_DEFAULT_SPRITES;
|
||||
sptr->SpriteID = 0;
|
||||
sptr->scalar = 2;
|
||||
|
||||
int size = (GetRandomControl() & 7) + 32;
|
||||
|
@ -1416,7 +1241,8 @@ void TriggerRocketFire(int x, int y, int z)
|
|||
sptr->flags = SP_SCALE | SP_DEF | SP_EXPDEF;
|
||||
|
||||
// TODO: right sprite
|
||||
sptr->spriteIndex = Objects[ID_DEFAULT_SPRITES].meshIndex;
|
||||
sptr->SpriteSeqID = ID_DEFAULT_SPRITES;
|
||||
sptr->SpriteID = 0;
|
||||
sptr->scalar = 1;
|
||||
sptr->gravity = -(GetRandomControl() & 3) - 4;
|
||||
sptr->maxYvel = -(GetRandomControl() & 3) - 4;
|
||||
|
@ -1989,3 +1815,54 @@ void TriggerAttackFlame(const Vector3i& pos, const Vector3& color, int scale)
|
|||
spark.sSize = spark.size;
|
||||
spark.dSize = spark.size / 4;
|
||||
}
|
||||
|
||||
void SpawnPlayerWaterSurfaceEffects(const ItemInfo& item, int waterHeight, int waterDepth)
|
||||
{
|
||||
const auto& player = GetLaraInfo(item);
|
||||
|
||||
// Player underwater; return early.
|
||||
if (player.Control.WaterStatus == WaterStatus::Underwater)
|
||||
return;
|
||||
|
||||
// Get point collision.
|
||||
auto pointColl0 = GetPointCollision(item, 0, 0, -(LARA_HEIGHT / 2));
|
||||
auto pointColl1 = GetPointCollision(item, 0, 0, item.Animation.Velocity.y);
|
||||
|
||||
// In swamp; return early.
|
||||
if (TestEnvironment(ENV_FLAG_SWAMP, pointColl1.GetRoomNumber()))
|
||||
return;
|
||||
|
||||
bool isWater0 = TestEnvironment(ENV_FLAG_WATER, pointColl0.GetRoomNumber());
|
||||
bool isWater1 = TestEnvironment(ENV_FLAG_WATER, pointColl1.GetRoomNumber());
|
||||
|
||||
// Spawn splash.
|
||||
if (!isWater0 && isWater1 &&
|
||||
item.Animation.Velocity.y > 0.0f && SplashCount == 0 &&
|
||||
player.Control.WaterStatus != WaterStatus::TreadWater)
|
||||
{
|
||||
SplashSetup.Position = Vector3(item.Pose.Position.x, waterHeight - 1, item.Pose.Position.z);
|
||||
SplashSetup.InnerRadius = 16;
|
||||
SplashSetup.SplashPower = item.Animation.Velocity.z;
|
||||
|
||||
SetupSplash(&SplashSetup, pointColl0.GetRoomNumber());
|
||||
SplashCount = 16;
|
||||
}
|
||||
// Spawn ripple.
|
||||
else if (isWater1)
|
||||
{
|
||||
if (Wibble & 0xF)
|
||||
return;
|
||||
|
||||
if (Random::TestProbability(1 / 2000.0f) && item.Animation.ActiveState == LS_IDLE)
|
||||
return;
|
||||
|
||||
int flags = (item.Animation.ActiveState == LS_IDLE) ?
|
||||
(int)RippleFlags::LowOpacity :
|
||||
(int)RippleFlags::SlowFade | (int)RippleFlags::LowOpacity;
|
||||
|
||||
SpawnRipple(
|
||||
Vector3(item.Pose.Position.x, waterHeight - 1, item.Pose.Position.z),
|
||||
item.RoomNumber, Random::GenerateFloat(112.0f, 128.0f),
|
||||
flags);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -17,9 +17,8 @@ constexpr auto SD_UWEXPLOSION = 2;
|
|||
|
||||
constexpr auto MAX_NODE = 23;
|
||||
constexpr auto MAX_DYNAMICS = 64;
|
||||
constexpr auto MAX_SPLASHES = 8;
|
||||
|
||||
constexpr auto MAX_PARTICLES = 4096;
|
||||
constexpr auto MAX_PARTICLES = 8192;
|
||||
constexpr auto MAX_PARTICLE_DYNAMICS = 8;
|
||||
|
||||
extern int Wibble;
|
||||
|
@ -108,54 +107,58 @@ struct NODEOFFSET_INFO
|
|||
unsigned char gotIt;
|
||||
};
|
||||
|
||||
struct SPLASH_SETUP
|
||||
{
|
||||
float x;
|
||||
float y;
|
||||
float z;
|
||||
float splashPower;
|
||||
float innerRadius;
|
||||
int room;
|
||||
};
|
||||
|
||||
// TODO: Refactor this entire struct.
|
||||
struct Particle
|
||||
{
|
||||
bool on;
|
||||
|
||||
GAME_OBJECT_ID SpriteSeqID = GAME_OBJECT_ID::ID_DEFAULT_SPRITES;
|
||||
int SpriteID = 0;
|
||||
int fxObj;
|
||||
|
||||
int x;
|
||||
int y;
|
||||
int z;
|
||||
int roomNumber;
|
||||
Vector3 targetPos;
|
||||
|
||||
short xVel;
|
||||
short yVel;
|
||||
short zVel;
|
||||
|
||||
short rotAng; // TODO: Due to legacy conventions, assigned values must be shifted >> 4.
|
||||
short rotAdd; // TODO: Due to legacy conventions, assigned values must be shifted >> 4.
|
||||
|
||||
short gravity;
|
||||
short rotAng;
|
||||
unsigned short flags; // SP_enum
|
||||
|
||||
float sSize;
|
||||
float dSize;
|
||||
float size;
|
||||
unsigned char friction;
|
||||
unsigned char scalar;
|
||||
unsigned char spriteIndex;
|
||||
signed char rotAdd;
|
||||
signed char maxYvel;
|
||||
bool on;
|
||||
|
||||
unsigned int friction;
|
||||
unsigned int scalar;
|
||||
int maxYvel;
|
||||
|
||||
unsigned char r;
|
||||
unsigned char g;
|
||||
unsigned char b;
|
||||
unsigned char sR;
|
||||
unsigned char sG;
|
||||
unsigned char sB;
|
||||
unsigned char dR;
|
||||
unsigned char dG;
|
||||
unsigned char dB;
|
||||
unsigned char r;
|
||||
unsigned char g;
|
||||
unsigned char b;
|
||||
|
||||
unsigned char colFadeSpeed;
|
||||
unsigned char fadeToBlack;
|
||||
|
||||
int sLife;
|
||||
int life;
|
||||
|
||||
BlendMode blendMode;
|
||||
unsigned char extras;
|
||||
signed char dynamic;
|
||||
int fxObj;
|
||||
int roomNumber;
|
||||
unsigned char nodeNumber; // ParticleNodeOffsetIDs enum.
|
||||
|
||||
int PrevX;
|
||||
|
@ -180,46 +183,6 @@ struct Particle
|
|||
}
|
||||
};
|
||||
|
||||
struct SPLASH_STRUCT
|
||||
{
|
||||
float x;
|
||||
float y;
|
||||
float z;
|
||||
float innerRad;
|
||||
float innerRadVel;
|
||||
float heightVel;
|
||||
float heightSpeed;
|
||||
float height;
|
||||
float outerRad;
|
||||
float outerRadVel;
|
||||
float animationSpeed;
|
||||
float animationPhase;
|
||||
short spriteSequenceStart;
|
||||
short spriteSequenceEnd;
|
||||
unsigned short life;
|
||||
bool isRipple;
|
||||
bool isActive;
|
||||
|
||||
Vector3 PrevPosition = Vector3::Zero;
|
||||
float PrevInnerRad = 0.0f;
|
||||
float PrevOuterRad = 0.0f;
|
||||
float PrevHeight = 0.0f;
|
||||
float PrevHeightSpeed = 0.0f;
|
||||
float PrevAnimPhase = 0.0f;
|
||||
unsigned short PrevLife = 0;
|
||||
|
||||
void StoreInterpolationData()
|
||||
{
|
||||
PrevPosition = Vector3(x, y, z);
|
||||
PrevInnerRad = innerRad;
|
||||
PrevOuterRad = outerRad;
|
||||
PrevHeight = height;
|
||||
PrevHeightSpeed = heightSpeed;
|
||||
PrevAnimPhase = animationPhase;
|
||||
PrevLife = life;
|
||||
}
|
||||
};
|
||||
|
||||
struct ParticleDynamic
|
||||
{
|
||||
byte On;
|
||||
|
@ -237,9 +200,6 @@ extern GameBoundingBox DeadlyBounds;
|
|||
extern Particle Particles[MAX_PARTICLES];
|
||||
extern ParticleDynamic ParticleDynamics[MAX_PARTICLE_DYNAMICS];
|
||||
|
||||
extern SPLASH_SETUP SplashSetup;
|
||||
extern SPLASH_STRUCT Splashes[MAX_SPLASHES];
|
||||
|
||||
extern Vector3i NodeVectors[ParticleNodeOffsetIDs::NodeMax];
|
||||
extern NODEOFFSET_INFO NodeOffsets[ParticleNodeOffsetIDs::NodeMax];
|
||||
|
||||
|
@ -295,8 +255,6 @@ void TriggerExplosionSmokeEnd(int x, int y, int z, int uw);
|
|||
void TriggerExplosionSmoke(int x, int y, int z, int uw);
|
||||
void TriggerFireFlame(int x, int y, int z, FlameType type, const Vector3& color1 = Vector3::Zero, const Vector3& color2 = Vector3::Zero);
|
||||
void TriggerSuperJetFlame(ItemInfo* item, int yvel, int deadly);
|
||||
void SetupSplash(const SPLASH_SETUP* const setup, int room);
|
||||
void UpdateSplashes();
|
||||
void TriggerLaraBlood();
|
||||
short DoBloodSplat(int x, int y, int z, short speed, short yRot, short roomNumber);
|
||||
void DoLotsOfBlood(int x, int y, int z, int speed, short direction, short roomNumber, int count);
|
||||
|
@ -309,10 +267,10 @@ void TriggerFlashSmoke(int x, int y, int z, short roomNumber);
|
|||
void TriggerMetalSparks(int x, int y, int z, int xv, int yv, int zv, const Vector3& color, int additional);
|
||||
void SpawnCorpseEffect(const Vector3& pos);
|
||||
void TriggerAttackFlame(const Vector3i& pos, const Vector3& color, int scale);
|
||||
void SpawnPlayerWaterSurfaceEffects(const ItemInfo& item, int waterHeight, int waterDepth);
|
||||
void Splash(ItemInfo* item);
|
||||
void TriggerRocketFire(int x, int y, int z);
|
||||
void TriggerExplosionBubbles(int x, int y, int z, short roomNumber);
|
||||
void Ricochet(Pose& pos);
|
||||
void ProcessEffects(ItemInfo* item);
|
||||
void UpdateWibble();
|
||||
|
||||
void SpawnPlayerWaterSurfaceEffects(const ItemInfo& item, int waterHeight, int waterDepth);
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
#include <array>
|
||||
#include "Game/control/control.h"
|
||||
#include "Game/effects/effects.h"
|
||||
#include "Game/Setup.h"
|
||||
#include "Math/Math.h"
|
||||
#include "Math/Random.h"
|
||||
|
||||
|
@ -100,6 +101,45 @@ namespace TEN::Effects::Spark
|
|||
s.destinationColor = Vector4::Zero;
|
||||
s.active = true;
|
||||
}
|
||||
|
||||
auto& sptr = *GetFreeParticle();
|
||||
|
||||
sptr = {};
|
||||
sptr.on = true;
|
||||
sptr.dynamic = NO_VALUE;
|
||||
sptr.sR = colorStart.x * 0.33f * UCHAR_MAX;
|
||||
sptr.sG = colorStart.y * 0.33f * UCHAR_MAX;
|
||||
sptr.sB = colorStart.z * 0.33f * UCHAR_MAX;
|
||||
sptr.dR = 0;
|
||||
sptr.dG = 0;
|
||||
sptr.dB = 0;
|
||||
sptr.colFadeSpeed = 4;
|
||||
sptr.fadeToBlack = 0;
|
||||
sptr.life = 4;
|
||||
sptr.sLife = 4;
|
||||
sptr.blendMode = BlendMode::Additive;
|
||||
sptr.x = pos.x;
|
||||
sptr.y = pos.y;
|
||||
sptr.z = pos.z;
|
||||
sptr.xVel = 0;
|
||||
sptr.yVel = 0;
|
||||
sptr.zVel = 0;
|
||||
sptr.flags = SP_SCALE | SP_DEF | SP_ROTATE;
|
||||
sptr.rotAng = GenerateAngle(0, 4095);
|
||||
|
||||
if (TestProbability(1 / 2.0f))
|
||||
sptr.rotAdd = 64 - GenerateAngle(0, 63);
|
||||
else
|
||||
sptr.rotAdd = GenerateAngle(0, 63) + 64;
|
||||
|
||||
sptr.scalar = 3;
|
||||
sptr.SpriteSeqID = ID_DEFAULT_SPRITES;
|
||||
sptr.SpriteID = SPR_BULLETIMPACT;
|
||||
sptr.size = GenerateInt(6, 12);
|
||||
sptr.sSize = sptr.size;
|
||||
sptr.dSize = 1;
|
||||
sptr.maxYvel = 0;
|
||||
sptr.gravity = 0;
|
||||
}
|
||||
|
||||
void TriggerFrictionSpark(const GameVector& pos, const EulerAngles& angle, float length, int count)
|
||||
|
|
|
@ -12,6 +12,7 @@
|
|||
#include "Game/effects/Drip.h"
|
||||
#include "Game/effects/Ripple.h"
|
||||
#include "Game/effects/smoke.h"
|
||||
#include "Game/effects/Splash.h"
|
||||
#include "Game/effects/weather.h"
|
||||
#include "Game/items.h"
|
||||
#include "Game/Lara/lara.h"
|
||||
|
@ -27,6 +28,7 @@ using namespace TEN::Effects::Drip;
|
|||
using namespace TEN::Effects::Environment;
|
||||
using namespace TEN::Effects::Ripple;
|
||||
using namespace TEN::Effects::Smoke;
|
||||
using namespace TEN::Effects::Splash;
|
||||
using namespace TEN::Collision::Floordata;
|
||||
using namespace TEN::Collision::Point;
|
||||
using namespace TEN::Math;
|
||||
|
@ -306,7 +308,8 @@ static void AttachAndCreateSpark(Particle* spark, const ItemInfo* item, int mesh
|
|||
int v = (GetRandomControl() & 0x3F) + 192;
|
||||
|
||||
spark->life = spark->sLife = v / 6;
|
||||
spark->spriteIndex = Objects[ID_DEFAULT_SPRITES].meshIndex + spriteID;
|
||||
spark->SpriteSeqID = ID_DEFAULT_SPRITES;
|
||||
spark->SpriteID = spriteID;
|
||||
|
||||
spark->xVel = v * (pos2.x - pos1.x) / 10;
|
||||
spark->yVel = v * (pos2.y - pos1.y) / 10;
|
||||
|
@ -1131,11 +1134,9 @@ void TriggerUnderwaterExplosion(ItemInfo* item, int flag)
|
|||
int dy = item->Pose.Position.y - waterHeight;
|
||||
if (dy < 2048)
|
||||
{
|
||||
SplashSetup.y = waterHeight;
|
||||
SplashSetup.x = item->Pose.Position.x;
|
||||
SplashSetup.z = item->Pose.Position.z;
|
||||
SplashSetup.innerRadius = 160;
|
||||
SplashSetup.splashPower = 2048 - dy;
|
||||
SplashSetup.Position = Vector3(item->Pose.Position.x, waterHeight, item->Pose.Position.z);
|
||||
SplashSetup.InnerRadius = 160;
|
||||
SplashSetup.SplashPower = 2048 - dy;
|
||||
|
||||
SetupSplash(&SplashSetup, item->RoomNumber);
|
||||
}
|
||||
|
@ -1341,7 +1342,8 @@ void TriggerShockwaveHitEffect(int x, int y, int z, unsigned char r, unsigned ch
|
|||
spark->rotAdd = (GetRandomControl() & 0xF) + 16;
|
||||
|
||||
spark->scalar = 1;
|
||||
spark->spriteIndex = Objects[ID_DEFAULT_SPRITES].meshIndex + SPR_UNDERWATERDUST;
|
||||
spark->SpriteSeqID = ID_DEFAULT_SPRITES;
|
||||
spark->SpriteID = SPR_UNDERWATERDUST;
|
||||
spark->maxYvel = 0;
|
||||
spark->gravity = (GetRandomControl() & 0x3F) + 64;
|
||||
spark->sSize = spark->size = (GetRandomControl() & 0x1F) + 32;
|
||||
|
@ -1441,7 +1443,8 @@ void TriggerExplosionBubble(int x, int y, int z, short roomNumber)
|
|||
spark->flags = 2058;
|
||||
spark->scalar = 3;
|
||||
spark->gravity = 0;
|
||||
spark->spriteIndex = Objects[ID_DEFAULT_SPRITES].meshIndex + SPR_BUBBLES;
|
||||
spark->SpriteSeqID = ID_DEFAULT_SPRITES;
|
||||
spark->SpriteID = SPR_BUBBLES;
|
||||
spark->maxYvel = 0;
|
||||
int size = (GetRandomControl() & 7) + 63;
|
||||
spark->sSize = size >> 1;
|
||||
|
|
|
@ -272,6 +272,7 @@ enum class ShockwaveStyle
|
|||
Normal = 0,
|
||||
Sophia = 1,
|
||||
Knockback = 2,
|
||||
Invisible = 3,
|
||||
};
|
||||
|
||||
#define ENERGY_ARC_STRAIGHT_LINE 0
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue