New release

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

Moderator: OpenTTD Developers

User avatar
Darkvater
Tycoon
Tycoon
Posts: 3053
Joined: 24 Feb 2003 18:45
Location: Hong Kong

Post by Darkvater »

TrueSatan wrote:Hi Darkvater.
You can get SDL here http://www.libsdl.org
greets
yea, I was a bit too premature. Some google-ing later, I found it, compiled TTD and it works :D

Now for some changes ^^
TrueLight: "Did you bother to read any of the replies, or you just pressed 'Reply' and started typing?"
<@[R-Dk]FoRbiDDeN> "HELP, this litte arrow thing keeps following my mouse, and I can't make it go away."
Bjarni
Tycoon
Tycoon
Posts: 2088
Joined: 08 Mar 2004 13:10

Post by Bjarni »

Darkvater wrote:LITTLE or BIG Endian depends on which OS you are using. I think linux is little endian too, but solaris sparc is big endian.

I wrote
#if !defined(i386)
# define TTD_BIG_ENDIAN
#endif

rigth after
#if defined(i386)
# define TTD_LITTLE_ENDIAN
#endif

I now have an executeable file compiled om MacOSX

However I get this error when I run it:
Error: Unable to read english.lng
ttd.c:74: failed assertion `0'
Abort

english.lng is present. Any ideas?
User avatar
Saskia
Director
Director
Posts: 523
Joined: 22 Feb 2004 14:23
Location: Cologne, Germany
Contact:

Post by Saskia »

Darkvater wrote:LITTLE or BIG Endian depends on which OS you are using. I think linux is little endian too, but solaris sparc is big endian.
Endianness is the bit counting order in a byte or other dataword. It depends on the CPU. If you have a PC (Intel* CPU), you always have little endian, if you own a Mac or Sparc or something that's using a Motorola* CPU, you have big endian. *) Or every other CPU based on these

Replace all _LITTLE_ENDIAN with __LITTLE_ENDIAN :wink:
Dakkus
Engineer
Engineer
Posts: 27
Joined: 07 Mar 2004 10:34
Skype: daccus
Location: Berlin, DE, EU
Contact:

Post by Dakkus »

Also remember, that the sdl has to be an sdl-devel package. Many packages you can find are just runtime packages and can't be used for compiling stuff.
So, one thing to do in problems like these is to find a file like "sdl-x.x.x-dev.rpm" instead of just "sdl-x.x.x.rpm". Solves most problems quite well.
Where have my euro notes travelled? *click* http://eurobilltracker.eu/
Hmm..?! From Portugal to Finland?
See it for yourself!
User avatar
Darkvater
Tycoon
Tycoon
Posts: 3053
Joined: 24 Feb 2003 18:45
Location: Hong Kong

Post by Darkvater »

Saskia wrote:
Darkvater wrote:LITTLE or BIG Endian depends on which OS you are using. I think linux is little endian too, but solaris sparc is big endian.
Endianness is the bit counting order in a byte or other dataword. It depends on the CPU. If you have a PC (Intel* CPU), you always have little endian, if you own a Mac or Sparc or something that's using a Motorola* CPU, you have big endian. *) Or every other CPU based on these

Replace all _LITTLE_ENDIAN with __LITTLE_ENDIAN :wink:
Yes that's right. Just usually at school win/linux is all 386 and solaris runs on an RISC proc, so I just took the OS. My mistake :)

english.lng should be in the same directory as your ttd.exe file, or in your C/C++ you should set the working directory to the folder where your graphic files and english.lng file is.
TrueLight: "Did you bother to read any of the replies, or you just pressed 'Reply' and started typing?"
<@[R-Dk]FoRbiDDeN> "HELP, this litte arrow thing keeps following my mouse, and I can't make it go away."
Bjarni
Tycoon
Tycoon
Posts: 2088
Joined: 08 Mar 2004 13:10

Post by Bjarni »

I got it to accept English.lng :)
but a new problem apeared :cry:

When I try to run, I get this
Loading sound effects...
Loading sprite set 0.
Loading drivers...

and after that, I get lot's of this
2004-03-09 18:30:54.966 ttd[1001] *** _NSAutoreleaseNoPool(): Object 0x1138d40 of class NSException autoreleased with no pool in place - just leaking

and in the end, it writes
2004-03-09 18:30:54.968 ttd[1001] *** Uncaught exception: <NSInternalInconsistencyException> Error (1002) creating CGSWindow
Trace/BPT trap

setting video driver to null fixes this problem, but it is no fun

Anybody knows how to fix this?
User avatar
Darkvater
Tycoon
Tycoon
Posts: 3053
Joined: 24 Feb 2003 18:45
Location: Hong Kong

Post by Darkvater »

Bjarni wrote:I got it to accept English.lng :)
but a new problem apeared :cry:

When I try to run, I get this
Loading sound effects...
Loading sprite set 0.
Loading drivers...

and after that, I get lot's of this
2004-03-09 18:30:54.966 ttd[1001] *** _NSAutoreleaseNoPool(): Object 0x1138d40 of class NSException autoreleased with no pool in place - just leaking

and in the end, it writes
2004-03-09 18:30:54.968 ttd[1001] *** Uncaught exception: <NSInternalInconsistencyException> Error (1002) creating CGSWindow
Trace/BPT trap

setting video driver to null fixes this problem, but it is no fun

Anybody knows how to fix this?
Have you installed SDL as per this:
http://www.tt-forums.net/viewtopic.php?t=6616
following their tutorial to set it up?
TrueLight: "Did you bother to read any of the replies, or you just pressed 'Reply' and started typing?"
<@[R-Dk]FoRbiDDeN> "HELP, this litte arrow thing keeps following my mouse, and I can't make it go away."
Post Reply

Return to “General OpenTTD”

Who is online

Users browsing this forum: Bing [Bot] and 14 guests