Commit Graph

12630 Commits

Author SHA1 Message Date
teknomunk dc815e1873 Fix table of contents 2024-10-11 11:22:23 +02:00
teknomunk 542bae8417 Finish writing API documentation, remove drop_railcarts (replaced by try_detach_minecart), rename constants to ALL CAPS for consistency, change mcl_minecarts. to mod. for API function definitions 2024-10-11 11:22:23 +02:00
teknomunk 2f950a2974 Nearly finish API documentation, create mcl_minecarts.add_blocks_to_map() 2024-10-11 11:22:23 +02:00
teknomunk ff6badbcd0 Continue writing API documentation, update call signatures for a couple of API functions 2024-10-11 11:22:23 +02:00
teknomunk c77e3d0c26 Change document formatting, finally move cactus cart dropping to node definition for mcl_core:cactus 2024-10-11 11:22:23 +02:00
teknomunk 2aed569b85 Correct crashes/item duplication with dropping carts, start API documentation 2024-10-11 11:22:23 +02:00
teknomunk e136489339 Fix cart controls, cart pushing 2024-10-11 11:22:23 +02:00
teknomunk a71ad474f9 Fix typo in rail replacement mapping, fix several crashes 2024-10-11 11:22:23 +02:00
teknomunk 94cd9dbc73 Implement movement thru tee rails 2024-10-11 11:22:23 +02:00
teknomunk 54a73b76e7 Tune respawn distance limit 2024-10-11 11:22:23 +02:00
teknomunk cdce542f16 Fix crashes 2024-10-11 11:22:23 +02:00
teknomunk d1daed118a Remove memory leak for cart data, check distance to players before respawning distant carts to prevent adding entities that are immediately inactivated 2024-10-11 11:22:23 +02:00
teknomunk 6f951000ae Implement offline/out of range minecart movement and fix minecart respawning, remove railtype tracking 2024-10-11 11:22:23 +02:00
teknomunk 81664096ca Remove do_movement dependency on the existence of a cart luaentity 2024-10-11 11:22:23 +02:00
teknomunk 435cd88ceb Fix undefined global warning, move player off to the side of a cart when dismounting so trains don't get pushed apart when getting out 2024-10-11 11:22:23 +02:00
teknomunk a68e973cac Make trains containing a player in a minecart function, minor cleanup in mcl_playerinfo 2024-10-11 11:22:23 +02:00
teknomunk 65c5f30e32 Fix crashes in train logic, allow breaking apart trains 2024-10-11 11:22:23 +02:00
teknomunk f3d4e96c83 Implement train reversing 2024-10-11 11:22:23 +02:00
teknomunk 4e1fac94d0 Repair vectors in cart data, mostly fix train movement bugs (still possible to have a furnace minecart flip, without the train also flipping) 2024-10-11 11:22:23 +02:00
teknomunk 58a2858ab2 Add cart entity respawn/destroy to match cart data (partially working) 2024-10-11 11:22:23 +02:00
teknomunk 9e63976f37 Give furnace minecart minimum velocity when lit, add train separation code, update logging code, add sequence number to entity staticdata to allow respawn/despawn when carts move when the entity is unloaded 2024-10-11 11:22:23 +02:00
teknomunk d1782923ae Fix rail detach crash, make tnt minecarts explode if they hit something hard (off rails) 2024-10-11 11:22:23 +02:00
teknomunk 10a9c932c3 Make sure carts get detatch if the rail under them is removed 2024-10-11 11:22:23 +02:00
teknomunk 74e3f4c9c8 Fixish reorganizing, initial train implementation 2024-10-11 11:22:23 +02:00
teknomunk dcce34871b Major reorganization, start setup for trains 2024-10-11 11:22:23 +02:00
teknomunk 7c5f2f4dfb Make sure carts that collide move in the same direction the colliding cart was 2024-10-11 11:22:23 +02:00
teknomunk 74791e7219 Add utilities to convert between an ObjectRef, it's active object id and a 128bit uuid, move minecart data from entity staticdata to mod storage to eventually allow updating carts when out of range of players and also track what carts are alive, implement on-rail cart collisions 2024-10-11 11:22:23 +02:00
teknomunk af9e01350e Harden against unknown nodes 2024-10-11 11:22:23 +02:00
teknomunk da674131ec Allow players to push minecarts that are not on track 2024-10-11 11:22:23 +02:00
teknomunk 34de252d97 Fix rails in creative inventory, make minecart with tnt not crash server when exploding, make minecart with tnt slightly more powerful than regular tnt 2024-10-11 11:22:23 +02:00
teknomunk ead9da6d14 Fix rail movement regressions 2024-10-11 11:22:23 +02:00
teknomunk 4879899e06 Move cart code to its own file, more code cleanup, add aliases for old track items 2024-10-11 11:22:23 +02:00
teknomunk 2f4ac9a02d Cleanup code, restore uphill/downhill cart movement, completely remove old rail 2024-10-11 11:22:23 +02:00
teknomunk 17a27e9169 Get rail reattachment (especially after jumps) working correctly 2024-10-11 11:22:23 +02:00
teknomunk b356da9472 Make legacy rail update apply to all old rail types, add basic detached railcart physics with a stub to use mcl_physics when it gets merged 2024-10-11 11:22:23 +02:00
teknomunk 9524b8313a Silence unmaskable print statements 2024-10-11 11:22:23 +02:00
teknomunk 4b66ae64eb Add immortal item entity support, add legacy rail conversion that uses immortal item drops for corners/tees/crosses that are no longer possible 2024-10-11 11:22:23 +02:00
teknomunk d4234f0c4d Fix more rail connection bugs 2024-10-11 11:22:23 +02:00
teknomunk d8ea7659f2 Get sloped connections working correctly 2024-10-11 11:22:23 +02:00
teknomunk 299a6c4177 Re-enable rule for powering rail from underneath, have stairs block minecart movement, fix crash when lightning strikes a minecart 2024-10-11 11:22:23 +02:00
teknomunk 9d9a0d2faa Fix mcl_util.table_merge where a standard value overwrites a table, fix base definition usage, implement behavior difference when there is a solid block after a straight piece of track (this will eventually allow minecarts to fly off the end of the track) 2024-10-11 11:22:23 +02:00
teknomunk 5877854f3a Update all rail types to new version 2024-10-11 11:22:23 +02:00
teknomunk 659bf8fed9 Reorganize 2024-10-11 11:22:23 +02:00
teknomunk 1598f7fa80 Finish reverting 08b41a3b39 2024-10-11 11:22:23 +02:00
teknomunk 78ee4481c9 Enable new track with get_next_dir handlers 2024-10-11 11:22:23 +02:00
teknomunk da4058ad2c Change connection rules again to allow building parallel track, tees and crosses), start implementing rail rules callbacks 2024-10-11 11:22:23 +02:00
teknomunk 6a6405366a Add sloped rail 2024-10-11 11:22:23 +02:00
teknomunk bcbb319129 Fix rail visuals, add switch operation 2024-10-11 11:22:23 +02:00
teknomunk 68f7eb509a Implement initial rail connection logic (no vertical track yet), experiment with texture modifiers and gravel underlay for display (not working) 2024-10-11 11:22:23 +02:00
teknomunk fde18b5020 Start implementing new rail nodes 2024-10-11 11:22:23 +02:00