[Mod] Advanced Trains [advtrains] [2.1.0]

User avatar
mbb
Member
 
Posts: 251
Joined: Sat Jan 17, 2015 17:47
Location: in front of my pc
GitHub: mbblp
IRC: mBb
In-game: MBB

Re: [Mod] Advanced Trains [advtrains] [1.12]

by mbb » Fri Dec 22, 2017 13:41

new PR
please merge or review
If you want to contact me please send me a twitter pm https://twitter.com/mbbdev
 

User avatar
Codesound
Member
 
Posts: 231
Joined: Thu Jun 09, 2016 14:56

Re: [Mod] Advanced Trains [advtrains] [1.12]

by Codesound » Thu Dec 28, 2017 13:12

Hi,

I tried the 1.12 latest release but the "Trains dropped to 0" problem remains...

I realized that when the level is rendered, I often see the train off the track for a very short time, (especially in the curves), then it is re-positioned correctly but his velocity is clipped to 0;

I still see that when a train has to stop (after an ATC command), its "slowdown" is made with many and many LAGs;

finally, I often wait a long time for the arrival of a train, (which does not arrive (also 10 minutes)), until I begin to fly along the rails: the level is rendered and only then I see the train coming...

all these problems seem to be related to the Minetest rendering engine...

I hope I was helpful...

R
 

User avatar
mbb
Member
 
Posts: 251
Joined: Sat Jan 17, 2015 17:47
Location: in front of my pc
GitHub: mbblp
IRC: mBb
In-game: MBB
 

User avatar
mbb
Member
 
Posts: 251
Joined: Sat Jan 17, 2015 17:47
Location: in front of my pc
GitHub: mbblp
IRC: mBb
In-game: MBB

Re: [Mod] Advanced Trains [advtrains] [1.12]

by mbb » Thu Dec 28, 2017 17:36

how i can set the number?
If you want to contact me please send me a twitter pm https://twitter.com/mbbdev
 

User avatar
gpcf
Member
 
Posts: 326
Joined: Fri May 27, 2016 10:48
In-game: gabriel

Re: [Mod] Advanced Trains [advtrains] [1.12]

by gpcf » Fri Dec 29, 2017 10:03

Wow, the zugspitzbahn really looks nice. The number is set using overlay textures. setting it on non-subway trains might require a small change in the core mod, though.
 

User avatar
Codesound
Member
 
Posts: 231
Joined: Thu Jun 09, 2016 14:56
 

User avatar
gpcf
Member
 
Posts: 326
Joined: Fri May 27, 2016 10:48
In-game: gabriel

Re: [Mod] Advanced Trains [advtrains] [1.12]

by gpcf » Fri Dec 29, 2017 12:11

just put it in your mods folder and enable it. You don't need to put it in the advtrains folder.
 

User avatar
orwell
Member
 
Posts: 794
Joined: Wed Jun 24, 2015 18:45
Location: Raxacoricofallapatorius
GitHub: orwell96
IRC: orwell96_mt
In-game: orwell

Re: [Mod] Advanced Trains [advtrains] [1.12]

by orwell » Fri Dec 29, 2017 12:24

Codesound wrote:Hi,

I tried the 1.12 latest release but the "Trains dropped to 0" problem remains...

I realized that when the level is rendered, I often see the train off the track for a very short time, (especially in the curves), then it is re-positioned correctly but his velocity is clipped to 0;

IMO this is caused by some sort of bug in my tracks database.
advtrains keeps a database of all tracks in the world, independent of the Minetest node storage.
Whenever a train drives into (or inside) terrain that is not loaded(there's no player near), the train relies on this database. It might occur that nodes are not registered in the track database, esp. when WorldEdit has been used. Then trains are considered off-track and stop.
There is an LBM (loading block modifier) that finds those missing tracks when the MapBlock is loaded. This means that your tracks should work once you flew along all your rails. (note:should, if not there's a bug either in Minetests LBM handling or in my mod)
Codesound wrote:I still see that when a train has to stop (after an ATC command), its "slowdown" is made with many and many LAGs;

This is certainly caused by your computer.
Codesound wrote:finally, I often wait a long time for the arrival of a train, (which does not arrive (also 10 minutes)), until I begin to fly along the rails: the level is rendered and only then I see the train coming...

Also related to the track database:
Every train only saves 2 positions when stored to disk. When advtrains starts up, it checks whether those positions are rails. If this cannot be determined, the train step code just aborts before doing anything, waiting for the position to become loaded. Therefore the train does not move at all, until the position gets loaded.
Lua is great!
List of my mods
I like singing. I like dancing. I like ... niyummm...
 

User avatar
mbb
Member
 
Posts: 251
Joined: Sat Jan 17, 2015 17:47
Location: in front of my pc
GitHub: mbblp
IRC: mBb
In-game: MBB

Re: [Mod] Advanced Trains [advtrains] [1.12]

by mbb » Fri Dec 29, 2017 12:26

ok
Last edited by mbb on Fri Dec 29, 2017 12:28, edited 1 time in total.
If you want to contact me please send me a twitter pm https://twitter.com/mbbdev
 

User avatar
mbb
Member
 
Posts: 251
Joined: Sat Jan 17, 2015 17:47
Location: in front of my pc
GitHub: mbblp
IRC: mBb
In-game: MBB

Re: [Mod] Advanced Trains [advtrains] [1.12]

by mbb » Fri Dec 29, 2017 12:28

gpcf wrote:Wow, the zugspitzbahn really looks nice. The number is set using overlay textures. setting it on non-subway trains might require a small change in the core mod, though.

like
Code: Select all
core.override item adtrains:subway{
     tiles = "advtrains_subway.png^1.png"
}
If you want to contact me please send me a twitter pm https://twitter.com/mbbdev
 

User avatar
mbb
Member
 
Posts: 251
Joined: Sat Jan 17, 2015 17:47
Location: in front of my pc
GitHub: mbblp
IRC: mBb
In-game: MBB
 

User avatar
mbb
Member
 
Posts: 251
Joined: Sat Jan 17, 2015 17:47
Location: in front of my pc
GitHub: mbblp
IRC: mBb
In-game: MBB

Re: [Mod] Advanced Trains [advtrains] [1.12]

by mbb » Fri Dec 29, 2017 12:44

mbb wrote:
gpcf wrote:Wow, the zugspitzbahn really looks nice. The number is set using overlay textures. setting it on non-subway trains might require a small change in the core mod, though.

like
Code: Select all
core.override item adtrains:subway{
     tiles = "advtrains_subway.png^1.png"
}

please send me the hole code
thx
If you want to contact me please send me a twitter pm https://twitter.com/mbbdev
 

User avatar
Codesound
Member
 
Posts: 231
Joined: Thu Jun 09, 2016 14:56
 

User avatar
Codesound
Member
 
Posts: 231
Joined: Thu Jun 09, 2016 14:56

Re: [Mod] Advanced Trains [advtrains] [1.12]

by Codesound » Fri Dec 29, 2017 13:20

orwell wrote:
Codesound wrote:Hi,

I tried the 1.12 latest release but the "Trains dropped to 0" problem remains...

I realized that when the level is rendered, I often see the train off the track for a very short time, (especially in the curves), then it is re-positioned correctly but his velocity is clipped to 0;

IMO this is caused by some sort of bug in my tracks database.
advtrains keeps a database of all tracks in the world, independent of the Minetest node storage.
Whenever a train drives into (or inside) terrain that is not loaded(there's no player near), the train relies on this database. It might occur that nodes are not registered in the track database, esp. when WorldEdit has been used. Then trains are considered off-track and stop.
There is an LBM (loading block modifier) that finds those missing tracks when the MapBlock is loaded. This means that your tracks should work once you flew along all your rails. (note:should, if not there's a bug either in Minetests LBM handling or in my mod)
Codesound wrote:I still see that when a train has to stop (after an ATC command), its "slowdown" is made with many and many LAGs;

This is certainly caused by your computer.
Codesound wrote:finally, I often wait a long time for the arrival of a train, (which does not arrive (also 10 minutes)), until I begin to fly along the rails: the level is rendered and only then I see the train coming...

Also related to the track database:
Every train only saves 2 positions when stored to disk. When advtrains starts up, it checks whether those positions are rails. If this cannot be determined, the train step code just aborts before doing anything, waiting for the position to become loaded. Therefore the train does not move at all, until the position gets loaded.


Hi,

thanks for your reply..
I have one alienware area 51v2 (Intel i7 esacore + geforce gtx980 on Win10) if this PC is little for minetest.... I think I'll have to change computer.... ;-)

thanks again for all your work!

R
 

User avatar
orwell
Member
 
Posts: 794
Joined: Wed Jun 24, 2015 18:45
Location: Raxacoricofallapatorius
GitHub: orwell96
IRC: orwell96_mt
In-game: orwell

Re: [Mod] Advanced Trains [advtrains] [1.12]

by orwell » Fri Dec 29, 2017 18:55

mbb wrote:
gpcf wrote:Wow, the zugspitzbahn really looks nice. The number is set using overlay textures. setting it on non-subway trains might require a small change in the core mod, though.

like
Code: Select all
core.override item adtrains:subway{
     tiles = "advtrains_subway.png^1.png"
}

No...
I need to explain the line numbers.
- implemented only on the subway train
- NOT settable via any menu
- The only way to set them is to write the following code into a LUA-ATC controller:
Code: Select all
set_line(<line number>)

... and driving the train over it
IDK if it's possible to clear the line number once it has been set...
Lua is great!
List of my mods
I like singing. I like dancing. I like ... niyummm...
 

User avatar
mbb
Member
 
Posts: 251
Joined: Sat Jan 17, 2015 17:47
Location: in front of my pc
GitHub: mbblp
IRC: mBb
In-game: MBB

Re: [Mod] Advanced Trains [advtrains] [1.12]

by mbb » Fri Dec 29, 2017 19:27

orwell wrote:
mbb wrote:
gpcf wrote:Wow, the zugspitzbahn really looks nice. The number is set using overlay textures. setting it on non-subway trains might require a small change in the core mod, though.

like
Code: Select all
core.override item adtrains:subway{
     tiles = "advtrains_subway.png^1.png"
}

No...
I need to explain the line numbers.
- implemented only on the subway train
- NOT settable via any menu
- The only way to set them is to write the following code into a LUA-ATC controller:
Code: Select all
set_line(<line number>)

... and driving the train over it
IDK if it's possible to clear the line number once it has been set...



thx orwell
If you want to contact me please send me a twitter pm https://twitter.com/mbbdev
 

User avatar
SonosFuer
Member
 
Posts: 104
Joined: Sun Jul 09, 2017 00:32
GitHub: apachano
IRC: SonosFuer
In-game: SonosFuer

Re: [Mod] Advanced Trains [advtrains] [1.12]

by SonosFuer » Wed Jan 03, 2018 05:14

It would be really cool to add sounds to the trains. There should be engine and rail sounds when the train moves and air sounds for breaks and the doors opening/ closing. I also thing being able to use the ATC rails to make a whistle/ air horn sound would be cool.
Working on a content database for minetest mods, servers, and etc Check it out and give me feedback at https://forum.minetest.net/viewtopic.php?f=14&t=18137
 

User avatar
orwell
Member
 
Posts: 794
Joined: Wed Jun 24, 2015 18:45
Location: Raxacoricofallapatorius
GitHub: orwell96
IRC: orwell96_mt
In-game: orwell

Re: [Mod] Advanced Trains [advtrains] [1.12]

by orwell » Wed Jan 03, 2018 06:40

The subway train already has some sounds.
Horn via ATC would be cool of course, but it's difficult to implement because of reasons.
Lua is great!
List of my mods
I like singing. I like dancing. I like ... niyummm...
 

User avatar
Codesound
Member
 
Posts: 231
Joined: Thu Jun 09, 2016 14:56

Re: [Mod] Advanced Trains [advtrains] [1.12]

by Codesound » Mon Jan 08, 2018 13:57

Hi,

I inform you that with the latest version 0.5.0-9146c6a-win64 the power line above the rails is finally gone....

thanks for you patience...

R

Image


EDIT:
when I downloaded the latest version of Minetest, all the video settings are disabled: this is the reason why the power line is hidden. When I set any type of Mipmaps in the global main settings window, the power line is showed....the problem therefore is if I set any mipmap value. It is enough then that I leave it disabled

thanks again for all....

R
 

User avatar
orwell
Member
 
Posts: 794
Joined: Wed Jun 24, 2015 18:45
Location: Raxacoricofallapatorius
GitHub: orwell96
IRC: orwell96_mt
In-game: orwell

Re: [Mod] Advanced Trains [advtrains] [1.13]

by orwell » Tue Jan 09, 2018 19:37

1.13
I've been changing the controls for driving trains. The key assignment did not change at all, but you now need to hold keys to accelerate/roll. It's now more or less like a virtual 'lever' as found in many trams.
Hold Down and Jump at the same time to use the (somewhat overpowered) emergency brake.
Also: Added 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

@codesound: the models currently include the powerlines, although they are set to a transparent texture. I decided to implement them in a different manner, however. The reason why they still do exist is simply because it is NOT FUN to export 48 different .obj files from Blender. So I always try to avoid to change the rail models because of this.
When I get to implement power lines (which will be after I finished the automatic track section signalling system), i might reexport the models (note, might)
If you are very annoyed of them, feel free to do that work for me, the blender files with the rails should be in the assets directory on the repository.
Lua is great!
List of my mods
I like singing. I like dancing. I like ... niyummm...
 

User avatar
Codesound
Member
 
Posts: 231
Joined: Thu Jun 09, 2016 14:56

Re: [Mod] Advanced Trains [advtrains] [1.13]

by Codesound » Wed Jan 10, 2018 09:55

orwell wrote:@codesound: the models currently include the powerlines, although they are set to a transparent texture. I decided to implement them in a different manner, however. The reason why they still do exist is simply because it is NOT FUN to export 48 different .obj files from Blender. So I always try to avoid to change the rail models because of this.
When I get to implement power lines (which will be after I finished the automatic track section signalling system), i might reexport the models (note, might)
If you are very annoyed of them, feel free to do that work for me, the blender files with the rails should be in the assets directory on the repository.


Hi, thanks for reply.
I'm sorry for my feeds on power line. I did not understand that they were part of the project.
I'm not a programmer and I do not use blender. I do not know how to help you. I thought the only thing I could do was to inform you of possible problems with the mod.... Sorry again and thanks for all

R
 

User avatar
orwell
Member
 
Posts: 794
Joined: Wed Jun 24, 2015 18:45
Location: Raxacoricofallapatorius
GitHub: orwell96
IRC: orwell96_mt
In-game: orwell

Re: [Mod] Advanced Trains [advtrains] [1.13]

by orwell » Thu Jan 11, 2018 20:40

No problem. I really like your level crossing bell!
Lua is great!
List of my mods
I like singing. I like dancing. I like ... niyummm...
 

user
Member
 
Posts: 18
Joined: Sat Mar 18, 2017 10:56
In-game: user

Re: [Mod] Advanced Trains [advtrains] [1.13]

by user » Fri Jan 12, 2018 01:20

moin moin,

i tested the version 1.13 they don't start and i get follow error:


Code: Select all
2018-01-12 02:13:28: ERROR[Main]: ModError: Failed to load and run script from /home/minetest/.minetest/mods/advtrains/advtrains/init.lua:
2018-01-12 02:13:28: ERROR[Main]: /home/minetest/.minetest/mods/advtrains/advtrains/wagons.lua: Datei oder Verzeichnis nicht gefunden
2018-01-12 02:13:28: ERROR[Main]: stack traceback:
2018-01-12 02:13:28: ERROR[Main]:    [C]: in function 'dofile'
2018-01-12 02:13:28: ERROR[Main]:    /home/minetest/.minetest/mods/advtrains/advtrains/init.lua:152: in main chunk


that's all!

edit:
Looks like a mistake of myself, i must show if i come home!


mfg user
 

user
Member
 
Posts: 18
Joined: Sat Mar 18, 2017 10:56
In-game: user

Re: [Mod] Advanced Trains [advtrains] [1.13]

by user » Sat Jan 13, 2018 16:52

Hi,

everything ist OK!

Sorry my mistake :(

The sound of the green steam engine, the new conrol and boardcomputer are great!

Tanks for all!

Best regards
 

User avatar
orwell
Member
 
Posts: 794
Joined: Wed Jun 24, 2015 18:45
Location: Raxacoricofallapatorius
GitHub: orwell96
IRC: orwell96_mt
In-game: orwell

Re: [Mod] Advanced Trains [advtrains] [1.13]

by orwell » Tue Jan 16, 2018 08:45

user wrote:Tanks for all!

Image
TANKS FOR ALL!!!
Lua is great!
List of my mods
I like singing. I like dancing. I like ... niyummm...
 

PreviousNext

Return to Mod Releases



Who is online

Users browsing this forum: No registered users and 10 guests