1
0
Fork 0
mirror of https://github.com/OpenMW/openmw.git synced 2025-01-20 07:53:53 +00:00
Commit graph

316 commits

Author SHA1 Message Date
Evil Eye
66d9d7e585 Expose levelled creatures to Lua 2023-06-11 15:13:46 +02:00
psi29a
724d29aa63 Merge branch 'add_getBounty_to_types_Player' into 'master'
Lua: Add getCrimeLevel() to types.Player

See merge request OpenMW/openmw!3118
2023-06-10 08:48:33 +00:00
psi29a
3fcf9dc1d2 Merge branch 'set_scale' into 'master'
Allow Lua to set and get GameObject's in game scale

See merge request OpenMW/openmw!3114
2023-06-10 08:48:14 +00:00
psi29a
ca57bbe644 Merge branch 'debug_tgm_tcl' into 'master'
Lua commands debug.toggleGodMode and debug.toggleCollision

See merge request OpenMW/openmw!3113
2023-06-09 07:26:44 +00:00
Kindi
8962cb818c Add getCrimeLevel() to types.Player 2023-06-09 07:01:12 +08:00
Tobias Tribble
41a2c82f93 Added scale property and setScale function 2023-06-07 19:23:36 -05:00
Petr Mikheev
e773b9d055 Lua commands debug.toggleGodMode and debug.toggleCollision 2023-06-07 23:41:29 +02:00
Petr Mikheev
e84ef1d5d9 More Lua documentation about FormId 2023-06-07 22:20:35 +02:00
Petr Mikheev
3b5849add8 Move content files functions to core.contentFiles and add obj.contentFile 2023-06-07 20:57:48 +02:00
Petr Mikheev
a778dff61d Add Lua functions to get the current load order and search objects by RefNum/FormId 2023-06-07 20:57:48 +02:00
Kindi
dfafac72e9 add startingPosition and startingRotation lua property to gameobject 2023-06-04 14:35:33 +08:00
Mads Buvik Sandvei
85a30c9ad0 Fix signature of MWMechanics::MagicEffects::get. Fix a mistake in the docs. 2023-05-25 18:12:18 +02:00
Petr Mikheev
4ed283bb15 Merge branch 'create_record_types' into 'master'
Allow creating Activator, Armor, Clothing, Misc, Weapon records via lua

See merge request OpenMW/openmw!2944
2023-05-25 08:00:13 +00:00
Zackhasacat
ef004e5eba Allow creating Activator, Armor, Clothing, Misc, Weapon records via lua 2023-05-25 08:00:12 +00:00
Mads Buvik Sandvei
b5aefc872b Document the optional attribute/skill parameter of getEffect. 2023-05-23 18:17:31 +02:00
Mads Buvik Sandvei
5f6bd5466f #number -> #string in documentation 2023-05-23 18:12:06 +02:00
Mads Buvik Sandvei
8ac7b04770 ActiveEffects / ActiveSpells documentation 2023-05-23 18:11:44 +02:00
Mads Buvik Sandvei
c03c3c40d5 documentation of MagicEffectId enum 2023-05-23 18:11:44 +02:00
psi29a
1ce35fa9e7 Merge branch 'lua-bounding-box' into 'master'
Expose game object's bounding box in lua api

See merge request OpenMW/openmw!3009
2023-05-19 09:33:44 +00:00
glassmancody.info
a7b7f99d72 Expose game object's bounding box in lua api 2023-05-18 11:10:10 -07:00
psi29a
5fba79ece3 Merge branch 'teleport' into 'master'
Additional Lua bindings for cells and fixes for teleporting

See merge request OpenMW/openmw!3017
2023-05-17 07:57:57 +00:00
Petr Mikheev
e657874351 Lua commands getSelectedSpell/setSelectedSpell 2023-05-14 15:17:03 +02:00
Petr Mikheev
ce7f6f31c9 Additional Lua bindings for cells 2023-05-13 20:59:55 +02:00
Petr Mikheev
2725a9d7f4 Add option "onGround=true/false" in Lua teleporting 2023-05-13 20:59:55 +02:00
Petr Mikheev
067df2d07e Rename some functions in Lua API from aaa to getAaa (for consistency with setAaa) 2023-05-08 00:49:06 +02:00
Tobias Tribble
15d940654d Fixed field error in documentation 2023-04-26 15:02:27 -05:00
Tobias Tribble
b52ab04c43 Added soulValue to creatureRecord, added documentation 2023-04-26 12:01:59 -05:00
Zackhasacat
f6fb05d1ca Add functionality for lua to view and modify ownership data for GameObjects 2023-04-25 21:20:43 +00:00
Petr Mikheev
90397662bc Lua bindings for magic. Based on the work made by @bharbich in !2765. 2023-04-20 18:48:34 +02:00
psi29a
2a6e301925 Merge branch 'activation' into 'master'
Allow Lua scripts to extend or override standard activation mechanics

See merge request OpenMW/openmw!2935
2023-04-20 11:29:21 +00:00
psi29a
cace3e6566 Merge branch 'fix_teleporting' into 'master'
Fix bugs related to Lua commands `obj:teleport` and `obj:moveInto`

See merge request OpenMW/openmw!2937
2023-04-20 11:28:02 +00:00
Petr Mikheev
00beb06391 Initial Lua bindings for ESM4 types; bindings for ESM4Door. 2023-04-20 01:47:16 +02:00
Petr Mikheev
60a8d08e66 Refactor teleporting in Lua; fix a bug in worldmodel.cpp 2023-04-17 19:07:30 +02:00
Petr Mikheev
61d207bd78 Allow Lua scripts to extend or override standard activation mechanics 2023-04-16 23:50:27 +02:00
Zackhasacat
224b7a0bf8 Allow Soul values on Misc Items to be set by Lua 2023-04-16 19:28:26 +00:00
psi29a
d6d7746c9b Merge branch 'records' into 'master'
[Lua] Fix implementation of types.*.records

See merge request OpenMW/openmw!2918
2023-04-11 06:54:19 +00:00
Petr Mikheev
55c9cde2ed [Lua] Add missing record.id for NPC and Creature records. 2023-04-10 23:28:15 +02:00
Petr Mikheev
9279c3d3e1 [Lua] Fix implementation of types.*.records 2023-04-10 23:15:28 +02:00
Mitten.O
d1fd6d77ca Document the records function for all record types 2023-04-09 15:01:44 +03:00
Mitten.O
11953a421b Document the records function 2023-04-09 14:38:04 +03:00
Mitten Orvan
4744b1eeda Make API for creating potions 2023-03-29 07:46:11 +00:00
Krzysztof Antoniak
ccdd381f96 Minor fixes to Lua documentation 2023-02-28 22:04:53 -08:00
uramer
9e22a5ac43 Add a note in the docs 2023-02-26 14:13:06 +01:00
Kindi
1d35a83452 Update types.lua 2023-02-12 00:26:45 +00:00
Kindi
4734504e2c Lua binding for Clothing 2023-02-12 00:19:08 +08:00
Bret Curtis
a708fb4a5c make sure lua works with macos packages 2023-02-06 14:35:22 +01:00
psi29a
68b3b90255 Merge branch 'ui_content_leak' into 'master'
Move implementation of UI Content to Lua (#7155)

See merge request OpenMW/openmw!2661
2023-02-01 22:51:47 +00:00
uramer
539ee77888 Note Layout names colliding with Content methods 2023-01-30 23:29:00 +01:00
uramer
c17eedd348 Documentation and API fixes (part of !2529) 2023-01-30 10:13:26 +00:00
Petr Mikheev
c294898246 Lua commands to create/move/remove objects; consistent handling of disabled objects (#6726, #6893) 2023-01-22 00:08:21 +01:00
Kindi
07da7eddea Add remap and round to lua utils 2023-01-20 22:28:34 +00:00
psi29a
0028127b42 Merge branch 'lua_mwscript' into 'master'
Access local mwscript variables in Lua scripts

See merge request OpenMW/openmw!2589
2023-01-10 08:47:12 +00:00
psi29a
2754d63e45 Merge branch 'cleanup_actions' into 'master'
Cleanup unused actions

See merge request OpenMW/openmw!2591
2023-01-08 20:14:35 +00:00
Petr Mikheev
7a0b998d4f Cleanup unused actions 2023-01-07 23:42:53 +01:00
psi29a
b6d0d09c5a Merge branch 'cell_hastag' into 'master'
[Lua] New function `cell.hasTag`

See merge request OpenMW/openmw!2567
2023-01-07 22:22:31 +00:00
Petr Mikheev
8c7cad024b Access local mwscript variables in Lua scripts 2023-01-07 22:10:10 +01:00
Petr Mikheev
7f117a28c8 Merge branch 'updateluacoredoc' into 'master'
update lua doc : recordid desc

See merge request OpenMW/openmw!2576
2023-01-05 11:27:33 +00:00
psi29a
1e62b84f9a Merge branch 'lua_initdata' into 'master'
Allow passing `initData` to the :addSript call (#7091)

Closes #7091

See merge request OpenMW/openmw!2568
2023-01-04 14:32:23 +00:00
Rasinin
02f0af42d9 updateluacoredoc: recordid desc 2023-01-04 17:59:19 +08:00
Petr Mikheev
f0a06258fb [Lua] New function cell:hasTag 2023-01-02 18:24:37 +01:00
Petr Mikheev
1a2d6514ba Fix incorrect description is Lua docs 2023-01-01 20:19:56 +01:00
Petr Mikheev
b248c3e173 Allow passing initData to the :addSript call (#7091) 2022-12-31 22:08:17 +01:00
Petr Mikheev
1869aeae5c Move some of player controls logic from C++ to Lua 2022-12-28 22:04:19 +01:00
mpeco
e10b7e5c82 types.lua baseArmor comment 2022-10-11 00:01:12 -03:00
mpeco
fd2d9d7d1a types.lua typo 2022-10-11 00:01:12 -03:00
mpeco
af3af6e091 update types.lua 2022-10-11 00:01:11 -03:00
AnyOldName3
84f8a6848a Renormalise line endings
This should replace accidental CRLF with LF
2022-09-16 00:53:24 +01:00
elsid
ab1ddc690e
Do not check getPolyHeight status
It may fail in some cases depending on a platform without obvious reason.
2022-08-24 23:30:36 +02:00
florent.teppe
15751c57a0 Lua debug api doc 2022-08-04 13:36:24 +02:00
psi29a
454684bad3 Merge branch 'custom_actor_collision_shape_type' into 'master'
Support cylinder and rotating box collision shape types for actors (#6138)

Closes #6138

See merge request OpenMW/openmw!2043
2022-08-01 11:00:23 +00:00
Christian Haro
86bb3195a0 Lua Bindings for Ingredient Records 2022-07-31 20:31:29 +00:00
elsid
8b8e4f78b6
Support cylinder and rotating box collision shape types for actors
Cylinder collision shape should give the best consistency between physics
simulation and pathfinding. Rotating box is already used by some actors, so
add it to have the same collision shape type for all actors.
2022-07-30 14:28:21 +02:00
elsid
27cc901e76
Add bindings for navigator utils functions 2022-07-21 00:04:26 +02:00
Cody Glassman
051832d7ae [Lua] Set simulation time scale 2022-07-03 12:51:28 +00:00
Petr Mikheev
377c00261a [Lua] Ability to distinguish normal interiors and quasi exteriors (like Mournhold). 2022-06-24 18:24:02 +02:00
Kindi
aa2e724342 Lua API for Repair records 2022-06-06 16:24:54 +00:00
Petr Mikheev
0745ed590b Fix incorrect package name in lua docs 2022-06-04 13:28:04 +00:00
beelzebielsk
fb5eb542ff Lua api for potion records 2022-06-01 13:19:03 +00:00
psi29a
a875ac86c0 Merge branch 'change-inventory-usage-docs' into 'master'
Make inventory example runnable in a script

See merge request OpenMW/openmw!1957
2022-05-31 14:41:54 +00:00
beelzebielsk
ad3b83432c Fix docs typos 2022-05-31 13:16:19 +00:00
adam
e4b2f730c7 Make inventory example runnable in a script 2022-05-31 13:12:40 +00:00
Kindi
638ad15af8 Lua API for Miscellaneous records 2022-05-31 08:54:07 +00:00
Kindi
3d0adf259b Lua API for Apparatus records 2022-05-29 23:03:36 +00:00
adam
e2528a1562 Add docs and automagical declaration 2022-05-26 07:20:50 +00:00
Kindi
1b37d5d2ad Lua API for Lockpick and Probe records 2022-05-24 11:48:13 +00:00
cody glassman
6093cb5f2c postprocessing lua api extensions 2022-05-22 18:53:38 -07:00
Petr Mikheev
6a0a2eed33 [Lua] core.getRealTime() 2022-05-20 21:49:19 +02:00
kuyondo
7dbccc914a no skill returns nil 2022-05-20 06:03:12 +08:00
kuyondo
8a1a838ffa update book.cpp and weapon.cpp 2022-05-20 00:39:19 +08:00
kuyondo
cad68a5566 Add lua binding for books 2022-05-19 20:02:18 +08:00
kuyondo
93aae5e116 Add lua binding for activators 2022-05-19 04:23:22 +08:00
Adam Ibrahim
96f4057f08 Update files/lua_api/openmw/types.lua, files/lua_api/openmw/ui.lua 2022-05-18 03:22:12 +00:00
elsid
215b46503c
Support rendering for navmesh update frequency as a heatmap
Useful when need to find tiles with high number of updates.

Add debug Lua package with new functions to toggle render mode and set navmesh
render mode.
2022-05-17 01:54:20 +02:00
psi29a
f092d8da9a Merge branch 'post_malone' into 'master'
Post Processing

See merge request OpenMW/openmw!1124
2022-05-16 14:51:13 +00:00
Petr Mikheev
7ccbf95503 [Lua] makeStrictReadOnly for enums 2022-05-16 00:16:26 +02:00
cody glassman
04843fed6d moddable post-processing pipeline 2022-05-15 10:03:58 -07:00
Petr Mikheev
0643685ea5 [Lua] Rename onInputUpdate -> onFrame and call it even when the game is on pause (#6745) 2022-05-13 19:14:34 +02:00
uramer
95ad67eb8b Add extraRoll to the Lua camera package 2022-05-12 23:21:47 +02:00
uramer
e92c88a133 Make the documentation clearer, match the documentation when no buttons are pressed for an event 2022-05-10 20:00:42 +02:00
Cody Glassman
882245b935 Lua Bindings: Add view distance bindings to camera 2022-05-09 19:40:48 +00:00
uramer
9c5887aab6 Add NPC and Creature record bindings 2022-05-08 16:36:17 +02:00
uramer
03659bef86 MWUI interface (resolve https://gitlab.com/OpenMW/openmw/-/issues/6594) 2022-05-03 17:36:49 +00:00
Petr Mikheev
eae1e87081 [Lua] Update openmw.storage 2022-04-23 18:55:12 +02:00
Petr Mikheev
88d09c336c Lua console 2022-04-21 21:57:07 +02:00
Petr Mikheev
1363292fc9 Merge branch 'l10n_docs' into 'master'
L10n docs

See merge request OpenMW/openmw!1785
2022-04-21 19:44:18 +00:00
Benjamin Winger
2f455aa87b
Added fallback details to l10n docs 2022-04-20 20:10:58 -04:00
Benjamin Winger
dac4415699
Moved localisation docs to dedicated page 2022-04-20 20:10:58 -04:00
fredzio
d05a2facf3 Handle NCC flag in Nif files. Objects with this flag will collide only with camera.
Expose objects with NC flag to be used by Lua mods.
2022-04-17 20:03:00 +02:00
Petr Mikheev
45c9635e94 Fix getmetatable, fix pairsForReadonly, add util.loadCode, _G 2022-04-14 01:00:02 +02:00
Petr Mikheev
51845e9553 Rendering raycasts in Lua 2022-04-11 23:36:54 +02:00
Benjamin Winger
21ffbcc4b4 Lua i18n updates 2022-04-10 07:57:02 +00:00
Petr Mikheev
3af8ea5dfc Update Lua bindings for the camera 2022-04-06 21:55:05 +02:00
Petr Mikheev
7186ea8ab4 [Lua] New overload Actor.equipment(actor, slot). 2022-04-06 21:55:05 +02:00
Petr Mikheev
eca64b48e8 Bitwise operations in Lua 2022-04-06 21:55:05 +02:00
Petr Mikheev
fbc84465c5 Merge branch 'futureproof_layers' into 'master'
Add layer size, make layers API more flexible

See merge request OpenMW/openmw!1724
2022-03-29 20:11:11 +00:00
Evil Eye
93d195646c Lua stats 2022-03-25 20:03:13 +00:00
uramer
5d1fe6c2bc Add layer size, make layers API more flexible 2022-03-23 15:04:49 +01:00
jvoisin
eb46bde75e Merge branch 'lua_records' into 'master'
Lua bindings for ESM::Door and ESM::Weapon records

See merge request OpenMW/openmw!1717
2022-03-20 15:39:48 +00:00
Petr Mikheev
1b1e81b90e Lua bindings for ESM::Door and ESM::Weapon records 2022-03-20 15:39:48 +00:00
Petr Mikheev
d185cb6dce Add Lua function ui.screenSize() 2022-03-20 00:16:41 +01:00
Petr Mikheev
fa115418eb [Lua] Remove queries 2022-03-15 23:35:36 +01:00
Petr Mikheev
9af49cfa68 [Lua] Update documentation 2022-03-15 23:35:36 +01:00
uramer
e7474490a1 Document using ui.texture to create atlases 2022-02-25 18:18:27 +01:00
uramer
94cc090f73 PR feedack for documentation 2022-02-25 18:18:27 +01:00
uramer
e092ee2624 Document the Lua Image widget, add UI texture resources 2022-02-25 18:18:26 +01:00
uramer
4a0b784699 Use reasonable Luadoc comment headers 2022-02-23 22:08:50 +01:00
Petr Mikheev
ff7ac7192b Merge branch 'ui_pairs' into 'master'
Implement pairs and ipairs for ui.content and ui.layers. Document all iterable types in a uniform way.

See merge request OpenMW/openmw!1643
2022-02-21 20:43:29 +00:00
uramer
a1abc84f59 Implement pairs and ipairs for ui.content and ui.layers. Document all iterable types in a uniform way. 2022-02-21 20:43:27 +00:00
uramer
cc6dce5443 Support controller touchpads (Resolves https://gitlab.com/OpenMW/openmw/-/issues/6639) 2022-02-21 19:49:00 +00:00
uramer
ede9d27437 Element-wise multiplication and division of Lua vectors 2022-02-10 19:43:27 +00:00
uramer
643c1d6aeb Merge branch 'lua_ai' into 'master'
Control AI packages from Lua

See merge request OpenMW/openmw!1604
2022-02-06 22:43:48 +00:00
Evil Eye
7a7a95407a Merge branch 'lua_pairs' into 'master'
Proper support of `pairs` and `ipairs` in Lua; fix bug in `makeReadOnly`.

See merge request OpenMW/openmw!1628
2022-02-06 22:10:21 +00:00
Petr Mikheev
a294adcdaf Proper support of pairs and ipairs in Lua; fix bug in makeReadOnly. 2022-02-06 22:10:20 +00:00
uramer
581c3f4882 Update and document Lua Text and TextEdit widget types, fix some issues with Lua UI 2022-02-06 20:22:38 +00:00
Petr Mikheev
6c56436809 Control AI packages from Lua 2022-02-06 15:01:51 +01:00
Petr Mikheev
6e4f628866 Replace inventory:get<Type>() with inventory:getAll(<Type>) 2022-02-03 02:05:49 +01:00
psi29a
cf8d49bb9a Merge branch 'lua_settings_ui' into 'master'
Lua settings UI

Closes #6454

See merge request OpenMW/openmw!1595
2022-02-02 21:04:18 +00:00
uramer
2945f6238e Fix util.color docs 2022-02-02 20:30:28 +00:00
uramer
946b8b804c MR feedback 2022-02-02 16:42:04 +01:00
Petr Mikheev
47c37e5849 Lua command object:activateBy(actor) and handler onActivate 2022-02-01 23:42:56 +00:00
uramer
2185fd29c5 Document ui.registerSettingsPage 2022-02-01 19:50:03 +01:00
uramer
c31dedb89c Implement Yaw, Pitch and Use (attack / cast spell) in Lua self.controls 2022-02-01 18:47:20 +00:00
uramer
d1d8f058ac Lua bindings for Colours 2022-01-17 22:35:06 +00:00
Petr Mikheev
a182fdeea1 Permanent storage for Lua data 2022-01-11 11:21:03 +01:00
Petr Mikheev
2d1b100239 Change terminology of gameSecond/gameHour to simulationTime/gameTime 2022-01-10 21:03:35 +01:00
Petr Mikheev
0f246e7365 Use a separate instance of Lua i18n for every context 2022-01-02 09:58:51 +01:00
Petr Mikheev
db72380ba9 Allow Lua scripts to handle input actions when UI is opened. Also fixes #6456. 2021-12-15 02:38:54 +01:00
Petr Mikheev
7549496162 A few small fixes + expose makeReadOnly to Lua + an option to apply makeReadOnly during deserialize 2021-12-15 02:38:54 +01:00
uramer
c865114b9b Lua UI Layers 2021-12-14 17:38:06 +00:00
Petr Mikheev
620748480b Merge branch 'lua_missing_key_codes' into 'master'
Lua binding for SDL_GetKeyName, two missing scan codes

See merge request OpenMW/openmw!1450

(cherry picked from commit d86e7d4c9a28bc96af0a5638b26879fa49b8a847)

9a073baa Add Apostrophe and Period scan codes
d66f3a35 Add getKeyName to Lua input API
ed64add9 Replace mentions of KeyEvent with KEY
2021-12-03 13:35:57 +00:00
Petr Mikheev
73821ace94 Update Lua docs 2021-11-19 20:37:21 +01:00
Petr Mikheev
d5ca091d6e Make util.rotateX, util.rotateY, rotate.Z consistent with morrowind rotation 2021-11-19 20:37:21 +01:00
uramer
68963538ae Lua UI API 2021-11-18 15:19:54 +00:00
Petr Mikheev
d285427485 Update Lua package openmw.input 2021-11-11 20:14:30 +01:00
Petr Mikheev
dd96eba2b0 Update OpenMW Lua docs 2021-10-26 21:52:42 +02:00
Petr Mikheev
48538d5cef 3D transforms in Lua 2021-09-28 20:37:47 +02:00
Petr Mikheev
fb3917fc1a Lua callbacks 2021-09-28 09:36:23 +02:00
Petr Mikheev
0bd1c22e24 Raycasting in Lua 2021-09-28 09:36:23 +02:00
Petr Mikheev
3771e523f1 More object bindings 2021-08-21 17:18:11 +02:00
Petr Mikheev
0e6fbbc126 Lua package 'openmw.input' 2021-08-10 19:00:52 +03:00
Petr Mikheev
a94072243b Lua command core.quit 2021-08-04 19:14:24 +03:00
Petr Mikheev
0f7f5ce140 Remove Lua command "self:setDirectControl" 2021-08-03 14:36:51 +03:00
Petr Mikheev
2938aaf05c Rename API_VERSION -> API_REVISION in Lua API. 2021-07-27 20:06:04 +02:00
Petr Mikheev
3e4c0b775d Add Lua package 'openmw.settings' 2021-07-27 20:06:04 +02:00
Petr Mikheev
25cc884c17 Integrate Lua doc into sphinx doc (issue #5931) 2021-07-09 20:48:54 +02:00
Petr Mikheev
4eb5841c60 Update OpenMW Lua documentation 2021-07-09 20:48:54 +02:00