Subsidiaries management (latest build: r7213)

Forum for technical discussions regarding development. If you have a general suggestion, problem or comment, please use one of the other forums.

Moderator: OpenTTD Developers

oVRoM
Engineer
Engineer
Posts: 37
Joined: 11 Jan 2003 10:40
Location: Utah

Post by oVRoM »

I don't think it should give much problems, I just tried it on 2137 and it compiles fine (only one patch from PBS is rejected but that's something you can fix manually without problem). With the latest trunk (2150) something in npf.c needs fixing and I don't know how (I could guess but I haven't used PBS at all so I wouldn't know if I did it wrong :-)

Image
Attachments
pbs_and_subsidiaries.diff
Combo patch for 2137
(119.17 KiB) Downloaded 161 times
Brons
Engineer
Engineer
Posts: 2
Joined: 06 Apr 2005 15:14

Post by Brons »

Could you post the win32 binary of PBS and Subsidiaries? Because Tortoise wont eat it, saying it doesn't have an index. I'm sorry for my ignorance, but I haven't used diff's much.

I love the patch, its something thats has been in my head for a long time. But I never thought anyone would make it.
Asterix
Engineer
Engineer
Posts: 121
Joined: 04 Apr 2005 18:17
Location: Germany

Post by Asterix »

hmm, i could post my binary...
but i have just done it and not tested much yet...

i used PBS v0.61 diff and subsidiaries.2135 diff and applied them to 2155
it compiled ok (just some warnings building "langs", all sounding like:
Warning: String name 'XXXX' does not match the layout of the master string)
game starts and i could generate a new random map without problems, anything else not tested yet ;)

hmm, should i try to make a diff for what i did, too? (never made a diff myself before :roll: )

well, anyway there is the binary (debugbuild):

EDIT: Attachment deleted (lang files were missing anyway ;) )
new binary in later post
Last edited by Asterix on 07 Apr 2005 13:57, edited 1 time in total.
Brons
Engineer
Engineer
Posts: 2
Joined: 06 Apr 2005 15:14

Post by Brons »

Thanks very much. I'll try it later :).
User avatar
Dextro
Chief Executive
Chief Executive
Posts: 701
Joined: 12 Jan 2005 21:56
Location: Lisboa, Portugal
Contact:

Post by Dextro »

pity it's a debug build still I think I'll try it out ;) I was really looking foward to the mix of those too patches, it will make my tracks flow soooooooo much better :mrgreen:
Uncle Dex Says: Follow the KISS Principle!
Asterix
Engineer
Engineer
Posts: 121
Joined: 04 Apr 2005 18:17
Location: Germany

Post by Asterix »

well, i thought trying a debug-build first would be better for tracking down problems if there are any...

if i get some feedback if its stable i might do a non-debug-build ;)

EDIT: did a new (non-debug) build with the 2157-trunk...
can i update an attachment so i dont have to put up nearly the same build twice? and if yes should i put up a new thread for the pbs-subsidiaries merged version so that its in the first post?
User avatar
orudge
Administrator
Administrator
Posts: 25144
Joined: 26 Jan 2001 20:18
Skype: orudge
Location: Banchory, UK
Contact:

Post by orudge »

From memory... you can update the attachment if you go to "Posted Attachments" (or something like that), and then click "Add an Attachment", the form should appear again, put the path to the new file in and a description, and click "update" next to the old attachment. That should work, IIRC. ;)
User avatar
osai
Traffic Manager
Traffic Manager
Posts: 132
Joined: 22 Sep 2004 14:56
Location: 10.0.1.254
Contact:

Post by osai »

hmm... i 've got errors in the beginning and cant start the game:

MD5 of TRGIR.grf is incorrect.
sounds strange, because this is an originial TTD file and that means the file is n't changed.... strange :roll:

osai
User avatar
Dextro
Chief Executive
Chief Executive
Posts: 701
Joined: 12 Jan 2005 21:56
Location: Lisboa, Portugal
Contact:

Post by Dextro »

invalid version of the language files here :?
Uncle Dex Says: Follow the KISS Principle!
Asterix
Engineer
Engineer
Posts: 121
Joined: 04 Apr 2005 18:17
Location: Germany

Post by Asterix »

hmm, some of the language files were updated in the trunk, but as i do a complete build i dont get those errors... seems i should include the \lang folder next time :)

as for the MD5 error: i think another thread states that there are diffrent versions of the original files out there... maybe one of the developers can say more about this

EDIT: i will probably try to make a new build tomorrow... for now im too tired ;)
Asterix
Engineer
Engineer
Posts: 121
Joined: 04 Apr 2005 18:17
Location: Germany

Post by Asterix »

As promised I did a new build (using trunk 2164 this time), and its not a debug build :)

I hope I didnt forget to include any necessary files this time ;)
Attachments
pbs_subsidiaries_2164trunk.zip
PBS + Subsidiaries, 2164 trunk
(956.19 KiB) Downloaded 151 times
User avatar
Dextro
Chief Executive
Chief Executive
Posts: 701
Joined: 12 Jan 2005 21:56
Location: Lisboa, Portugal
Contact:

Post by Dextro »

Looks good but I still don't know how to use PBS... I'll figure it out eventualy but it looks like it's working :)
Uncle Dex Says: Follow the KISS Principle!
Novatlan
Engineer
Engineer
Posts: 26
Joined: 18 Feb 2005 19:53

Post by Novatlan »

Are there any plans to include this patch as a regular feature in one of the next releases of OTT?
Generally there are a lot of well done patches and new features out there - but many people (including myself) have no idea what to do with these .diff files.
Asterix
Engineer
Engineer
Posts: 121
Joined: 04 Apr 2005 18:17
Location: Germany

Post by Asterix »

this patch (and some others too) probably wont make it into the next release of OpenTTD.
Perhaps saome of them will be added AFTER the release of 0.4.0, but currently theres only bugfixing of current features, as the release should be soon

for use of those diff-files you need to be able to compile source-code
if you have windows you might be lucky and someone posted an executable file of what you want to have (see LordOfThePigs post on previous page for latest subsidiaries binary or my last one for subsidiaries+PBS)
User avatar
LordOfThePigs
Route Supervisor
Route Supervisor
Posts: 435
Joined: 01 Jul 2004 10:28
Location: Jura/Switzerland

Yet another new build

Post by LordOfThePigs »

Hello,

here's the newest build of the subsidiairies patch (it doesn't include pbs or any other patches). The subsidiairies patch hasn't changed itself, but a lot of bugs were solved in the nightly builds, and those changes are of course included in this new build. The best of these changes is, if you ask me, the ability for NPF to plan routes through depots, thus allowing forced servicing lines. NPF was also heavily debugged.

r2173 - [Fixed] compiler warnings (thanks to Panther)
r2173 - [Languages] Cleanup: All strings are now nicely aligned with the other strings
r2173 - [Languages] Updated Hungarian translation (thanks to Panther)
r2173 - [Languages] Added French translation (thanks to papillon-bleu)
Attachments
TODO.txt
Change log, and a short TODO list
(1.05 KiB) Downloaded 188 times
subsidiairies.2173.diff
.diff file against revision 2173
(122.88 KiB) Downloaded 146 times
subsidiairies.2173.bin.zip
Windows executable and language packs
(962.11 KiB) Downloaded 212 times
Sometimes I'm told "Brilliant"...
Sometimes I'm told "Charming"...
And Often I'm told "Shut Up"!
Nanaki13
Traffic Manager
Traffic Manager
Posts: 151
Joined: 08 Jan 2005 16:08

Post by Nanaki13 »

I have selected the option to allow subsidiairies to remove each others tracks and roads, but all i can remove are stations, airports and stuff like that. Roads and tracks seem to be sacred, the message 'owned by' appears.
So it seems that the option doesn't work as it should.
User avatar
Dextro
Chief Executive
Chief Executive
Posts: 701
Joined: 12 Jan 2005 21:56
Location: Lisboa, Portugal
Contact:

Post by Dextro »

So LordOfThePigs any work recently on this? I was looking foward for a new version soon... :oops:
Uncle Dex Says: Follow the KISS Principle!
User avatar
LordOfThePigs
Route Supervisor
Route Supervisor
Posts: 435
Joined: 01 Jul 2004 10:28
Location: Jura/Switzerland

Post by LordOfThePigs »

Well, I'm pretty much overworked these days, so it might take some time before I post an updated version. However I got tow more bug reports on #openttd. I'll paste them right there so I don't forget them:

<<<<<<<<<<<<<<<<<<<<<<<<
click my train in another companys station list

train_gui.c:1418: PlayerTrainsWndProc: Assertion `v->type == VEH_Train&& v->subtype == TS_Front_Engine && v->owner == owner' failed.
<<<<<<<<<<<<<<<<<<<<<<<<
another one, you can't delete your own trains built in another's depot
cos the buttons aren't active
<<<<<<<<<<<<<<<<<<<<<<<<
Sometimes I'm told "Brilliant"...
Sometimes I'm told "Charming"...
And Often I'm told "Shut Up"!
User avatar
lucaspiller
Tycoon
Tycoon
Posts: 1228
Joined: 18 Apr 2004 20:27

Post by lucaspiller »

You also cannot add other companies (non subsidary) stations to the order list, when you have the option checked to allow it.
No longer active here, but you can still reach me via email: luca[at]stackednotion[dot]com
Hazelrah
Traffic Manager
Traffic Manager
Posts: 196
Joined: 13 Apr 2005 05:41

Post by Hazelrah »

Hey everyone,

So I was playing with my brother online this weekend and love using the subsidiaries patch! But thought it was really annoying that I couldn't add in my brother's stations. So I figured it was about time I made my first contribution to this massive project. It's not much but at least now you can add opponents’ stations when the option is turned on. Hope you don't mind LordOfThePigs!

Fortunately, it seems like it was just a one line job. Line 171 in order_cmd.c had to be changed from:

Code: Select all

if (!IsValidStation(st) ||
  (st->airport_type != AT_OILRIG && !(IsBuoy(st)) && !CheckOwnership(st->owner))) {
To:

Code: Select all

if (!IsValidStation(st) ||
    (st->airport_type != AT_OILRIG && !(IsBuoy(st)) && 
     !(_patches.shared_stations || CheckOwnership(st->owner)))) {
Seems to work so far!

I also discovered a couple of things while I was working on this.

1) You must have track sharing on, or they can't go into the opponents’ station, even if your track goes all the way to the entrance.

2) Doesn't properly display an error message when Allow station sharing for everyone is on.

3) While I saw the gui for Taxing trains on shared tracks, the actual tax doesn't seem to be implemented at all.

I've attached a windows binary and difference file (to 2281) below. If you want it with PBS or what not, hopefully the guys over at the Integrated Nightly Build can help. If not, give me a shout and I'll see what I can do.

Actually that was kind of fun, so if LordOfThePigs stays busy, I might try to make a few more bug fixes to this awesome patch!

Forgive any spelling mistakes. It’s rather late at night where I am.

-Hazelrah
Attachments
subsidiairies.2281.diff
Subsidaries Patch to 2281
(154.31 KiB) Downloaded 119 times
Two human players sharing a station.
Two human players sharing a station.
Sharing_Stations.png (172.5 KiB) Viewed 651 times
OTTD_Sub2281.bin.rar
Windows binary with the above patch
(895.67 KiB) Downloaded 109 times
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 4 guests