Commit Graph

34 Commits (master)

Author SHA1 Message Date
orwell96 ef8391a60d atc_reset(): Removed unused string parameter and also clear ATC autocouple flag (Cpl)
Fixes H#189 and H#190
2021-12-31 16:04:04 +01:00
Maverick2797 43c85ab8cf readme atc_set_ars_disable typo 2021-11-09 21:45:33 +01:00
Maverick2797 4cf9e5283b split_at_index where index=1
Splitting at index=1 results in multiple empty trains being created.
Can be prevented by an atc_speed > 0 check by the user, but easier just to return false and do nothing.
2021-11-08 22:58:23 +01:00
orwell96 5e27bbdcfe LuaATC: Fix position of error label, use consistent name "LuaATC" instead of "LuaAutomation" 2021-11-02 23:22:30 +01:00
orwell96 09bba2c57f Hopefully fix #177 2021-04-25 21:59:02 +02:00
orwell96 6135f8a23b LuaATC: add sending atc command to train by ID, and getters for in/out text (solves #124 and #166) 2021-03-02 19:51:56 +01:00
orwell96 5569849401 Restore LuaATC autocouple interface accidentally lost in 74a2199
During rebase, this part of the autocouple feature must have been accidentally lost
2021-02-15 16:52:54 +01:00
orwell96 4d13b15842 luaatc: Train event: also remember arrow connection in enter callback, remove obsolete code 2021-02-10 16:39:46 +01:00
orwell96 41568a3e2e luaatc: don't fail train event when train has already passed the rail at event time 2021-02-10 16:39:46 +01:00
orwell96 8660794ef8 Fix lots of things around new LZB 2021-02-10 16:36:24 +01:00
orwell96 816245588d Disable ARS train flag and surrounding uses 2021-02-10 16:35:45 +01:00
orwell96 74a219937d Add approach callback mechanism to LuaATC 2021-02-10 16:34:34 +01:00
Gabriel Pérez-Cerezo b23d346ace add maximum length parameter to split_at_fc and split_off_locomotive 2020-08-21 15:58:12 +02:00
Gabriel Pérez-Cerezo 36d8c8b716 Add command to split off locomotive 2020-07-28 20:39:35 +02:00
Gabriel Pérez-Cerezo 549db4737f add train_length command to luaatc 2020-07-27 21:50:22 +02:00
Gabriel Pérez-Cerezo 45413ee5c0 Add function to step through freight codes 2020-07-26 23:30:07 +02:00
Gabriel Pérez-Cerezo c54e0b341a add split_train_at_fc luaatc command
This command splits the train at the second non-empty FC it
encounters, taking with it the first few freight cars that all go to
the same destination.
2020-07-26 23:30:07 +02:00
Blockhead ad49854fed Make using the default tracks optional, even in submods
If advtrains_train_track is disabled, don't register any tracks that use
its model like the LuaATC automation rail, point speed restriction rail,
station/stop rail.

For LuaATC, the definition for firing an event when a
train runs over the rail needs to be moved into the common defs so that
other mods like linetrack can use that as an interface.
2020-07-10 22:14:39 +02:00
Gabriel Pérez-Cerezo 2a0c55099e fix typo in luaautomation 2020-07-02 14:45:38 +02:00
Gabriel Pérez-Cerezo 0b14d8ddb1 Add autocouple mode
The shunting mode no longer makes trains couple, since it was meant
for other purposes. For autocoupling, the new autocoupling mode is
used. If trains are in autocouple mode, they couple when they collide
with another train.
2020-06-29 01:30:27 +02:00
Gabriel Pérez-Cerezo 15be500662 document shunting mode, add unset_shunt to luaatc 2020-06-08 13:42:24 +02:00
Gabriel Pérez-Cerezo 2d8c13885a Shunting mode now couples trains on collision.
Trains now get coupled when one of them is in coupling mode.
2019-08-11 20:16:11 +02:00
Gabriel Pérez-Cerezo 1f6038c75a Add decoupling to luaatc 2019-08-11 17:42:30 +02:00
orwell96 ff94129761 Fix occurences of old lzb_invalidate 2019-04-23 22:30:33 +02:00
orwell96 e7dcee1127 Force LZB Halt setting 2019-02-05 11:23:17 +01:00
orwell96 f5e8b70202 Add getter/setter for routingcode in LuaATC 2019-01-15 17:54:13 +01:00
orwell96 37166b5c14 Make "Line" property accessible from OBC and gettable via LATC, change subway wagon texture handling 2018-11-20 11:57:46 +01:00
orwell96 33c839b40d Add signal safety control override, restructure control system 2018-10-10 21:49:52 +02:00
orwell96 24b0639c5f Mainly make collisions and coupling work
Missing: ATC stuff, yaw problems
2018-06-14 17:39:42 +02:00
orwell96 1feae7a1ea Add digiline interface and is_passive function to LuaATC 2018-04-25 17:14:03 +02:00
orwell96 46c4447da0 Rewrite rail connection system...
...to support an arbitrary number of connections for rails, which leads to these new features:
- switches now get recognized by the trackworker correctly
- ability to add real rail crosses
During this, I also rewrote the rail registering system and the conway function (important part of path prediction)
Note, developers: the track preset format changed, you might need to rewrite them according to the presets in tracks.lua if you wrote your own
(possibly breaks advcarts)
2017-12-18 23:09:23 +01:00
orwell96 f1a8b4f505 Implement multi-occupation in detector.on_node table to finally fix collisions 2017-10-25 11:49:34 +02:00
Gabriel Pérez-Cerezo 11d6a12ce7 Set wagon line number 2017-10-23 13:40:20 +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