Train refit patch

OpenTTD is a fully open-sourced reimplementation of TTD, written in C++, boasting improved gameplay and many new features.

Moderator: OpenTTD Developers

Post Reply
User avatar
heavyjoost
Engineer
Engineer
Posts: 26
Joined: 19 Dec 2002 14:00
Location: Canada
Contact:

Train refit patch

Post by heavyjoost »

I just improved that train refit patch using the latest CVS. It work for multiheaded trains :). However, I just wonder how to make a patch so I can share it with you.
Last edited by heavyjoost on 12 May 2004 19:31, edited 1 time in total.
mike[F]
Traffic Manager
Traffic Manager
Posts: 232
Joined: 26 Mar 2004 18:56

Post by mike[F] »

Use diff. With cvs, you can 'cvs diff' - I guess svn will have a similar function.
-mike[F]
Caught in the rush of the crowd, lost in a wall of sound...
User avatar
heavyjoost
Engineer
Engineer
Posts: 26
Joined: 19 Dec 2002 14:00
Location: Canada
Contact:

Post by heavyjoost »

I'm still debugging it a bit because the funtion even worked out of a depot :lol:

edit: I guess it works now, I'm gonna test it a bit more
User avatar
dominik81
OpenTTD Developer
OpenTTD Developer
Posts: 768
Joined: 16 Aug 2003 12:55
Location: Bonn, Germany

Post by dominik81 »

I'm wondering how hard it is to read a Readme file...

Code: Select all

The command
  $ svn diff > mypatch.diff
creates a patch file (aka diff file) which you can submit to the developers to share your improvements.
"There's a readme that comes with the source. I suggest you read it."
- Korenn
User avatar
heavyjoost
Engineer
Engineer
Posts: 26
Joined: 19 Dec 2002 14:00
Location: Canada
Contact:

Post by heavyjoost »

Ok, I tested it and everything is working for me. This replaced the reverse button. You can find it here: http://sourceforge.net/tracker/index.ph ... tid=636367
fabca2
Transport Coordinator
Transport Coordinator
Posts: 312
Joined: 14 Apr 2004 15:18
Location: Fr

Post by fabca2 »

heavyjoost wrote:Ok, I tested it and everything is working for me. This replaced the reverse button. You can find it here: http://sourceforge.net/tracker/index.ph ... tid=636367
Hey !! I use the reverse button !... Please add a new button...
User avatar
heavyjoost
Engineer
Engineer
Posts: 26
Joined: 19 Dec 2002 14:00
Location: Canada
Contact:

Post by heavyjoost »

maybe the ottd coders will do that. I was surpriced that I could still do some C because it was years ago when I did it for the last time :P. I'd really like to have a refit button in ottd.
User avatar
heavyjoost
Engineer
Engineer
Posts: 26
Joined: 19 Dec 2002 14:00
Location: Canada
Contact:

Post by heavyjoost »

I changed it a bit. You can refit it when the train is in a depot, if it's not in a depot it will reverse :)
User avatar
charlieg
Transport Coordinator
Transport Coordinator
Posts: 323
Joined: 08 Oct 2003 14:07
Contact:

Post by charlieg »

Perhaps you could make this work for other vehicles as well (ie cars, boats, planes)?
Open source tycoon games
--
Free Gamer - open source and Free Software games
FreeGameDev forums - open source game development community
User avatar
heavyjoost
Engineer
Engineer
Posts: 26
Joined: 19 Dec 2002 14:00
Location: Canada
Contact:

Post by heavyjoost »

It already works in the latest trunk :)
School
Engineer
Engineer
Posts: 56
Joined: 18 Apr 2004 09:30

Post by School »

I used the newest svn right now.
http://sourceforge.net/tracker/index.ph ... tid=636365
Here is the bug I got.
Heavyjoost, could you take a look and fix this for us?
(I mean the part related to multi-headed trains and please refer to the comments)
User avatar
heavyjoost
Engineer
Engineer
Posts: 26
Joined: 19 Dec 2002 14:00
Location: Canada
Contact:

Post by heavyjoost »

Uhm... Maybe I didn't understand it but everything works fine here. I tested it with rev 610.
Post Reply

Return to “General OpenTTD”

Who is online

Users browsing this forum: No registered users and 33 guests