Commit graph

1496 commits

Author SHA1 Message Date
Vsevolod Kremianskii
9f955664fb Add tool to convert ASCII PTH to PTH
This is inteded to be used alongside KotorBlender.
2021-03-31 13:55:15 +07:00
Vsevolod Kremianskii
2730abb00b Fix refreshing the combat action queue, deactivate with delay 2021-03-29 20:03:43 +07:00
Vsevolod Kremianskii
c94432e1ae Fix color glitches in selection overlay 2021-03-29 14:37:00 +07:00
Vsevolod Kremianskii
fb876e216f Make animation resolving and model building part of Creature 2021-03-28 09:39:15 +07:00
Vsevolod Kremianskii
272fb6b0d4 Run end of combat round script for creatures 2021-03-27 19:14:49 +07:00
Vsevolod Kremianskii
a52e914b1b Ensure all scripting messages are written to script debug channel 2021-03-27 19:05:30 +07:00
Vsevolod Kremianskii
40e48cc02c Refactor combat to take advantage of k_ai_master
Still doesn't work properly.
2021-03-27 18:49:33 +07:00
Vsevolod Kremianskii
c3ba96b222 Rename rp folder in libgame into d20 2021-03-27 10:27:50 +07:00
Vsevolod Kremianskii
6a17b286e9 Cleanup Routines, unify code style in routine implementations 2021-03-26 16:44:24 +07:00
Vsevolod Kremianskii
f124889100 Optimize SceneGraph.prepareGrass
Cull early grass clusters that are too far away.
2021-03-25 00:45:20 +07:00
Vsevolod Kremianskii
80061cc43f Drop Action source files
They were redundant.
2021-03-25 00:34:31 +07:00
Vsevolod Kremianskii
d40e4550fb Cleanup ByteCode handler registration 2021-03-25 00:12:16 +07:00
Vsevolod Kremianskii
eee68dad71 Add getEnum helper function to Routines 2021-03-25 00:07:32 +07:00
Vsevolod Kremianskii
70956e438d Store ExecutionContext as a smart pointer in Variable
This is to save space.
2021-03-24 23:51:42 +07:00
Vsevolod Kremianskii
50584354ad Replace Variable ctors with static factory functions
This is to make variable creation more robust at the cost of being more
verbose.
2021-03-24 23:12:44 +07:00
Vsevolod Kremianskii
07de49a78b Use macros to declare routine implementations 2021-03-24 22:16:59 +07:00
Vsevolod Kremianskii
fe683324e2 Implement more combat-related script routines 2021-03-23 22:41:33 +07:00
Vsevolod Kremianskii
c6deb588ec Implement more combat-related routines 2021-03-23 20:46:05 +07:00
Vsevolod Kremianskii
8a7885e19e Implement get*Target combat routines 2021-03-23 19:59:16 +07:00
Vsevolod Kremianskii
581984f7c0 Implement Get/SetNPCAIStyle 2021-03-23 18:37:16 +07:00
Vsevolod Kremianskii
59db8ae15c Implement GetRacialType routine 2021-03-23 17:35:14 +07:00
Vsevolod Kremianskii
d3e6a859af Add global variable to toggle shipBuild return value 2021-03-23 16:17:52 +07:00
Vsevolod Kremianskii
9e436508bd Implement perception criteria when searching for nth nearest creature 2021-03-23 16:05:19 +07:00
Vsevolod Kremianskii
ff9d939c32 fix: Invert the order of components when reading vector from stack 2021-03-23 15:42:08 +07:00
Vsevolod Kremianskii
d58c356ef4 Add line-of-sight check to perception 2021-03-23 15:36:56 +07:00
Vsevolod Kremianskii
6d35fdb455 Implement creature perception (sight and hearing) 2021-03-23 15:01:25 +07:00
Vsevolod Kremianskii
9c5be9b87a Refactor resource management
- Move GameID into libgame
- Move resource provider registration into Game
- Move GUI background loading into GameGUI
2021-03-23 13:21:24 +07:00
Vsevolod Kremianskii
32bc207b14 Check MDL signature as part of BinaryReader.load 2021-03-23 11:05:17 +07:00
Vsevolod Kremianskii
ecba6c70b6 When reading MDL, determine game by function pointers 2021-03-23 10:58:55 +07:00
Vsevolod Kremianskii
6f4ec13ab0 Fix animation blending not working 2021-03-23 10:17:28 +07:00
Vsevolod Kremianskii
48ae0226ea Simplify AnimatedProperty 2021-03-23 10:02:27 +07:00
Vsevolod Kremianskii
c71a513401 ci: Remove Azure from APT sources
This should fix the GitHub actions build.
2021-03-23 09:47:45 +07:00
Vsevolod Kremianskii
76ef2b481e Fix animating light properties 2021-03-23 00:28:01 +07:00
Vsevolod Kremianskii
8ee6fa3bdc Fill Danglymesh struct when loading MDL 2021-03-22 22:50:11 +07:00
Vsevolod Kremianskii
e65ecd6ca4 Refactor animation keyframes 2021-03-22 22:40:36 +07:00
Vsevolod Kremianskii
2e47ae21ed Refactor Model 2021-03-22 19:46:32 +07:00
Vsevolod Kremianskii
a0d95f16e5 Cleanup MdlReader 2021-03-22 19:30:26 +07:00
Vsevolod Kremianskii
ac55ac6a8d Read Danglymesh header and AABB tree from MDL 2021-03-22 19:27:54 +07:00
Vsevolod Kremianskii
100f318c81 Refactor MDL model loading
Read structs directly from memory.
2021-03-22 18:41:33 +07:00
Vsevolod Kremianskii
e5a41b92db Read ALL known controller types 2021-03-22 14:24:39 +07:00
Vsevolod Kremianskii
11cb6cea28 Color is a light-only controller 2021-03-22 13:57:23 +07:00
Vsevolod Kremianskii
4b075ab56c Remove redundant MdlReader.openMDX function 2021-03-22 13:55:00 +07:00
Vsevolod Kremianskii
d531e40a0f Refactor MDL controllers
Loading code was getting untidy with all the switch cases and functions.
2021-03-22 10:10:05 +07:00
Vsevolod Kremianskii
3ee16a5a24 Implement MDL reference nodes 2021-03-22 02:09:24 +07:00
Vsevolod Kremianskii
3019831286 Fix regression where not all particles were drawn 2021-03-21 16:23:44 +07:00
Vsevolod Kremianskii
3c32d4f752 Make dynamic room lighting not part of "enhanced graphics" mode 2021-03-20 15:44:24 +07:00
Vsevolod Kremianskii
f4f3ac7b91 Update room visibility less frequently
When in a third-person camera mode, room visibility must only be updated
when the party leader changes rooms.
2021-03-20 15:23:52 +07:00
Vsevolod Kremianskii
801a6b5200 Rename onScreen to culledOut 2021-03-20 15:13:50 +07:00
Vsevolod Kremianskii
48bc91a675 Add ERF/MOD writer 2021-03-20 14:24:22 +07:00
Vsevolod Kremianskii
9a98be39d5 Reimplement instanced particle drawing 2021-03-20 12:06:51 +07:00