diff options
author | orwell96 <orwell@bleipb.de> | 2020-04-28 16:01:35 +0200 |
---|---|---|
committer | orwell96 <orwell@bleipb.de> | 2021-02-10 16:36:24 +0100 |
commit | 8660794ef8392f08fa5be46715abb5dcbd96ca5d (patch) | |
tree | f077c3f12f901ed41061ee2672c62d53d5d2c27e /advtrains/api_doc.txt | |
parent | 5c2534cc35bc0fc47b53c8a992e3e71b15a60ec4 (diff) | |
download | advtrains-8660794ef8392f08fa5be46715abb5dcbd96ca5d.tar.gz advtrains-8660794ef8392f08fa5be46715abb5dcbd96ca5d.tar.bz2 advtrains-8660794ef8392f08fa5be46715abb5dcbd96ca5d.zip |
Fix lots of things around new LZB
Diffstat (limited to 'advtrains/api_doc.txt')
-rw-r--r-- | advtrains/api_doc.txt | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/advtrains/api_doc.txt b/advtrains/api_doc.txt index 0256713..8ac4986 100644 --- a/advtrains/api_doc.txt +++ b/advtrains/api_doc.txt @@ -182,9 +182,11 @@ minetest.register_node(nodename, { ^- called when a train leaves the rail -- The following function is only in effect when interlocking is enabled: - on_train_approach = function(pos, train_id, train, index, lzbdata) + on_train_approach = function(pos, train_id, train, index, has_entered, lzbdata) ^- called when a train is approaching this position, called exactly once for every path recalculation (which can happen at any time) ^- This is called so that if the train would start braking now, it would come to halt about(wide approx) 5 nodes before the rail. + ^- has_entered: when true, the train is already standing on this node with its front tip, and the enter callback has already been called. + Possibly, some actions need not to be taken in this case. Only set if it's the very first node the train is standing on. ^- lzbdata should be ignored and nothing should be assigned to it } }) |