Citybuilder Goals

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

Akoz2
Engineer
Engineer
Posts: 2
Joined: 05 Jun 2009 21:23

Citybuilder Goals

Post by Akoz2 »

Hey

Here is a beta of my current city building project. I'm posting here on request of various people asking for the source.
Please note that the code is quite full of ugly hacks and unoptimized code, and there are still minor bugs yet to be fixed.

Current main features:
- Claiming of cities with exclusive build rights in that city to the company.
- Conditional city growth depending on a storage of food, water, goods and diamonds to the specific city. The city's consumption and needs increases with its population size.
- Privately owned secondary industries (Food processing plant, factory and oil refinery).
- City population goal with server restart when reached.
- Various information commands.

Currently working with 0.7.1 and requires English(uk) language set in order to run successfully.
The patch should be applied for the server only, and the server should remain compatible with all 0.7.1 clients.
Make sure you apply citybuilder.cpp and citybuilder.h to source.list before compiling

Thanks to Rasco from speedy on showing me his company value code to base this on, to Xi and Ex' for the great citybuilding concept that inspired this, and ofc everyone in #openttd.
Attachments
citybuilder.patch
(68.91 KiB) Downloaded 1038 times
Last edited by Akoz2 on 21 Jul 2009 19:06, edited 3 times in total.
hempa
Engineer
Engineer
Posts: 21
Joined: 15 Oct 2008 16:30

Re: Citybuilder Goals

Post by hempa »

Hmm, this looks very interesting. Could we have some screenies perhaps? That is, if there are any GUI changes :)

I'm going to give it a try when I can get my compiler up and running again.

Cheers
petert
Tycoon
Tycoon
Posts: 3008
Joined: 02 Apr 2009 22:43
Location: Massachusetts, USA

Re: Citybuilder Goals

Post by petert »

Hempa, when you do, could you post a compiled version
Thanks :bow:
hempa
Engineer
Engineer
Posts: 21
Joined: 15 Oct 2008 16:30

Re: Citybuilder Goals

Post by hempa »

If I can manage to compile it for win32, I will. I do my patch testing on my Linux box though so.. We'll see if I can get a win32 binary done, but I'm going to be out of town until next week and unable to use my windows box.

Cheers
petert
Tycoon
Tycoon
Posts: 3008
Joined: 02 Apr 2009 22:43
Location: Massachusetts, USA

Re: Citybuilder Goals

Post by petert »

Ok, thanks :)
hempa
Engineer
Engineer
Posts: 21
Joined: 15 Oct 2008 16:30

Re: Citybuilder Goals

Post by hempa »

Otherwise, you can follow the instructions on here, here, and here and compile a binary yourself ;) There's a helpful post in the sticky list for how to apply patches too.
petert
Tycoon
Tycoon
Posts: 3008
Joined: 02 Apr 2009 22:43
Location: Massachusetts, USA

Re: Citybuilder Goals

Post by petert »

I've been having problems compiling.
Akoz
Engineer
Engineer
Posts: 9
Joined: 31 Jan 2008 18:25

Re: Citybuilder Goals

Post by Akoz »

Hmm, this looks very interesting. Could we have some screenies perhaps? That is, if there are any GUI changes :)
There is no GUI, although if anyone would want to help me make a grf addon that could display the extra city information that would be lovely.

Currently everything goes with text commands. See attached screenshots.
Attachments
city_information.png
City storage / growth information
(192.81 KiB) Downloaded 682 times
commands.png
Available commands
(189.91 KiB) Downloaded 537 times
private_industry.png
Private industries
(89.32 KiB) Downloaded 522 times
petert
Tycoon
Tycoon
Posts: 3008
Joined: 02 Apr 2009 22:43
Location: Massachusetts, USA

Re: Citybuilder Goals

Post by petert »

The patch does not work. I have compiled and tested it, no such commands like "!city" or "!help" work. I even set the language to English (UK). Nothing. Here is the compiled version (0.7.1)

Peter

Edit: Included COPYING file.
Attachments
patch is broken.rar
(3.58 MiB) Downloaded 337 times
Last edited by petert on 18 Aug 2009 09:55, edited 2 times in total.
User avatar
Ammler
President
President
Posts: 953
Joined: 18 Jun 2006 18:18
Location: Switzerland
Contact:

Re: Citybuilder Goals

Post by Ammler »

Hmm, you work with 0.7 branch, so this is a server side only patch? Like the patches from the various Goal servers?

If not, I would highly recommend to make it with trunk.

Anyway, nice idea.

Greets
Ammler
petert
Tycoon
Tycoon
Posts: 3008
Joined: 02 Apr 2009 22:43
Location: Massachusetts, USA

Re: Citybuilder Goals

Post by petert »

What I was saying, is that after compiling and opening a server, none of the commands worked. (Yes, I switched to English UK)
Last edited by petert on 16 Jul 2009 16:50, edited 1 time in total.
Akoz
Engineer
Engineer
Posts: 9
Joined: 31 Jan 2008 18:25

Re: Citybuilder Goals

Post by Akoz »

Ammler wrote:Hmm, you work with 0.7 branch, so this is a server side only patch? Like the patches from the various Goal servers?

If not, I would highly recommend to make it with trunk.

Anyway, nice idea.

Greets
Ammler
Yes it's a server side patch for 0.7.1 that keeps the server compatible for 0.7.1 clients.
If you want to test it out as a client just join any of the public servers with my name in them.
Neuralize
Engineer
Engineer
Posts: 17
Joined: 20 Jan 2009 04:28

Re: Citybuilder Goals

Post by Neuralize »

Awesome. I've played on the servers with city building and it is great. I'd love for someone to post a binary of this so I could host a city building server for me and my friends. Finally a patch that has definable multiplayer goals! I don't know why the climate around this community is so adverse to making the game competitive and fun. I really love opentdd, I just don't see the point in playing it when there are no hard coded goals which always leave the winner disputed. Keep working on this, it's the reason I play openttd.
petert
Tycoon
Tycoon
Posts: 3008
Joined: 02 Apr 2009 22:43
Location: Massachusetts, USA

Re: Citybuilder Goals

Post by petert »

Neuralize wrote:Awesome. I've played on the servers with city building and it is great. I'd love for someone to post a binary of this so I could host a city building server for me and my friends. Finally a patch that has definable multiplayer goals! I don't know why the climate around this community is so adverse to making the game competitive and fun. I really love opentdd, I just don't see the point in playing it when there are no hard coded goals which always leave the winner disputed. Keep working on this, it's the reason I play openttd.
Unfortunately, this patch doesn't work after a compile. So, unless Akoz posts a binary, we're stuck. :(
DaleStan
TTDPatch Developer
TTDPatch Developer
Posts: 10285
Joined: 18 Feb 2004 03:06
Contact:

Re: Citybuilder Goals

Post by DaleStan »

And if the posted binary works, we should be very suspicious of Akoz's compliance with the GPL.
To get a good answer, ask a Smart Question. Similarly, if you want a bug fixed, write a Useful Bug Report. No TTDPatch crashlog? Then follow directions.
Projects: NFORenum (download) | PlaneSet (Website) | grfcodec (download) | grfdebug.log parser
petert
Tycoon
Tycoon
Posts: 3008
Joined: 02 Apr 2009 22:43
Location: Massachusetts, USA

Re: Citybuilder Goals

Post by petert »

Hmm? He can't post a binary?
Yexo
Tycoon
Tycoon
Posts: 3663
Joined: 20 Dec 2007 12:49

Re: Citybuilder Goals

Post by Yexo »

Fact 1:
petert wrote: this patch doesn't work after a compile
Fact 2:
You have to provide either the sources or a written offer to provide them when you distribute a binary program under GPL.

Fictional fact 3:
. So, unless Akoz posts a binary, we're stuck. :(
I assume here you ment a working binary, otherwise it would be useless.

Combining these facts will lead you to the following conclusion: Either Akoz builds will have to change his patch before compiling or he has already done some changes and can post a binary. In the first case you're asking not only for a binary, but for him to fix the patch as well. In the second case (which DaleStan assumed), he doesn't abide the GPL (unless he posts his sources again, but then it's no longer juts a binary).
petert
Tycoon
Tycoon
Posts: 3008
Joined: 02 Apr 2009 22:43
Location: Massachusetts, USA

Re: Citybuilder Goals

Post by petert »

True, I meant a working binary. Preferably the one he uses to run the servers. If so, then he should post the sources.
Akoz
Engineer
Engineer
Posts: 9
Joined: 31 Jan 2008 18:25

Re: Citybuilder Goals

Post by Akoz »

Yexo wrote:Fact 1:
petert wrote: this patch doesn't work after a compile
Are you sure you're not confusing fact with fiction now? O_o

Petert: You are the only one I have heard of having trouble with the patch. Several others have gotten it to work with no issues whatsoever. Please let me know what the issue is and I will see if I can help. Most likely the issue is with your patching procedure. You can find help on how to successfully apply a patch in the links posted by hempa above.
Yexo
Tycoon
Tycoon
Posts: 3663
Joined: 20 Dec 2007 12:49

Re: Citybuilder Goals

Post by Yexo »

Akoz wrote:Are you sure you're not confusing fact with fiction now? O_o
I took whatever petert said as true to explain him DaleStans post. Since I haven't tried the patch myself I have no idea whether it works or not, but I assume that you wouldn't have posted it if it didn't work.
Post Reply

Return to “OpenTTD Development”

Who is online

Users browsing this forum: No registered users and 11 guests