orwell96
e7d0a5fac2
Train Coupling: Change behavior so that train direction of initiating train is kept, add ATC Cpl command
2021-10-25 21:04:45 +02:00
orwell96
1f3a4c3bfc
Rework train same-track collision system and deterministic coupling
...
- Adds a separate collision system for trains sharing a path
- Moved some coupling-related code to couple.lua and refactor it
- Handle coupling in a way that the initiating train always keeps its ID
- As a side effect, engine has its direction reversed after coupling
2021-07-07 22:42:14 +02:00
orwell96
112e3ff255
Fix undeclared globals warnings ( #176 )
...
Reported by Vanessa Dannenberg
2021-04-25 21:54:51 +02:00
orwell96
556e0782f7
Replace deprecated object:getxxx()/setxxx() by get_xxx()/set_xxx()
2021-02-10 16:42:15 +01:00
orwell96
5c2534cc35
Remove pcall wrappers completely, add command to disable advtrains mainloop
2021-02-10 16:36:24 +01:00
orwell96
8ae405f00f
Discard get_node_or_nil() for area-loaded check and use either a distance-based approach or minetest.is_block_active() if available
...
See also https://github.com/minetest/minetest/pull/10897
2021-02-03 09:30:44 +01:00
Gabriel Pérez-Cerezo
964b0a7ab6
Remove couple entities when out of range from players
...
Work around the entity flood bug caused by improper engine handling of
static_save=false
2020-10-12 15:41:27 +02:00
orwell96
b872bdae82
Remove "couple locks" and apply protection to the actual coupling process, and fix permissions on that
2018-11-10 12:12:52 +01:00
orwell96
06216b0ca1
No static_save for discouple entities
2018-10-30 15:42:30 +01:00
orwell96
93726db4e3
Handle the case that a train is not initialized (train_ensure_init returns nil/false)
...
Fixes H#72
2018-10-29 21:19:49 +01:00
orwell96
2a76d4a960
Fix final bugs and to-do's (u.a.save/load system)
2018-06-14 17:39:42 +02:00
orwell96
24b0639c5f
Mainly make collisions and coupling work
...
Missing: ATC stuff, yaw problems
2018-06-14 17:39:42 +02:00
orwell96
5dca155333
Implement collisions. (does not work yet, still code errors)
2018-06-14 17:39:42 +02:00
orwell96
418c026038
Correct discouple position
...
Discouple entity was falsely placed at the position of the wagon
instead of at its end
2018-01-22 22:44:55 +01:00
orwell96
8ef6e9a529
Fix crash
...
IDK why this happens, but it's not important.
2018-01-17 20:15:06 +01:00
orwell96
79da249c3d
Add bord computer to trains
...
Features:
- couple/decouple trains from a driver stand
- new couple lock system (owner based, overridable by 'train_remove' privilege)
- all train operators can now change the inside/outside text, allows for multilines
Accessible via right-click menu or by pressing Sneak+Jump keys
2018-01-09 21:30:56 +01:00
orwell96
d78d07589d
Add modifiable wagon extents
...
This will be required for advcarts
2017-11-23 17:00:39 +01:00
orwell96
17ee62dc64
Fix occasional crash in discouple on_punch
...
I think the issue is caused by the new animal damage code...
2017-11-14 22:08:56 +01:00
orwell96
c67770833b
Fix coupling and collisions in certain cases
...
If a train moved towards another train, and the other train's step was executed after the first one's, the trains did eventually not collide.
Fix by moving the enter_node and collision check to step_b
Also change some couple behavior
2017-10-25 10:33:41 +02:00
rubenwardy
d65c4916ce
Remove zip release files, move mod to root, exclude assets from Makefile ( #92 )
2017-09-20 18:05:04 +02:00
orwell96
2d0b51b897
Restructure mod directory
2017-01-04 19:10:03 +01:00
orwell96
2a924d086a
fix discouple not disappearing and a logical mistake with owners
2017-01-02 13:55:25 +01:00
orwell96
8784ee41dd
Do not duplicate definitions of 'print' in every file
2017-01-02 13:49:20 +01:00
orwell96
987cd5b7f0
spawn couple on train collision
...
also fix empty trains hanging around for too long
2016-12-31 15:16:19 +01:00
orwell96
f806ed9eee
Turning mod into a modpack and separating the trains from the core mod
2016-12-20 14:17:39 +01:00