News:

Simutrans.com Portal
Our Simutrans site. You can find everything about Simutrans from here.

pyTile - My pet project

Started by Ashley, June 17, 2009, 04:49:30 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Ashley

I thought I'd show off a little project I've been playing with. I like Simutrans a lot, and I am very interested in learning what it takes to put together a game like this. I've been working recently on a few little technical demos to improve my programming ability and to try and bring to life ideas I've had for ways to solve problems (some of which may be inspirational for the Simutrans project).

The first is an isometric graphics engine. I've called this pyTile (following the standard naming convention when dealing with Python). I'm working on releasing a much improved version soon, but you can see an older version here:

http://www.pygame.org/project/871/

The second which I have been playing with most recently is a demonstration of a system for track building which I've been thinking about for a long time. Again, this is quite embryonic at present but I think this represents the best and most flexible way to integrate realistic looking track (and road, eventually) into a square-grid/tile based game. It gives you smooth curves, nice looking points (switches) and even double track. I've posted a much earlier version of this before in a discussion about Curves. See what you think, the demo is here:

http://pygame.org/project/1160/

Both of these require the download of Python 2.6 and Pygame 1.8.1.

Maybe some of these ideas will inspire the developers of Simutrans.
Use Firefox? Interested in IPv6? Try SixOrNot the IPv6 status indicator for Firefox.
Why not try playing Simutrans online? See the Game Servers board for details.

sojo

This tracks are very nice. Mayby it will be in simutrans a funciton for this, someday.
"English is a easy language. But not for me." ;) sojo

follow simutrans_de on Twitter
- A home for Simutrans (in german)

VS

I get the impression that you have some surprises hidden up your sleeves :)

My projects... Tools for messing with Simutrans graphics. Graphic archive - templates and some other stuff for painters. Development logs for most recent information on what is going on. And of course pak128!

Ashley

Moved to general discussion.
Use Firefox? Interested in IPv6? Try SixOrNot the IPv6 status indicator for Firefox.
Why not try playing Simutrans online? See the Game Servers board for details.

VS

I wanted to ask - what are for these four points around corners? It seems impossible to connect tracks to them.

My projects... Tools for messing with Simutrans graphics. Graphic archive - templates and some other stuff for painters. Development logs for most recent information on what is going on. And of course pak128!

Ashley

An update, since I've had time to work on this recently.

(Please click on the images to view the full size ones, the forum resizes them and the resized versions don't look that great)

The bezier tracks are merged into the game engine, they look pretty good (though they need some tweaking to look as good as hand-drawn track graphics). They look a lot better in higher resolution (e.g. pak128 scale). I may try rendering some static tile-based graphics for Simutrans using this method for pak128/64.



I've also written a perlin noise generator to produce random terrain (much like the one Simutrans uses). I'm going to use this to procedurally generate textures as well (e.g. for grass and other ground terrain types).



Finally I'm going to be providing a public read-only interface to the SVN on my server, to make it easy to check out development versions. This will cover the source code for TileCutter as well.
Use Firefox? Interested in IPv6? Try SixOrNot the IPv6 status indicator for Firefox.
Why not try playing Simutrans online? See the Game Servers board for details.

Combuijs

Bob Marley: No woman, no cry

Programmer: No user, no bugs



Fabio

congrats!!!
Could this code be integrated in ST? it would be lovely!!!

Ashley

I am sure the same system could be implemented in Simutrans, yes, but the development effort would almost certainly be extremely high... If anyone wants to examine the source code and try to port the system to Simutrans they are welcome, it should be finished soon enough.

I started this project with the intent of exploring concepts which would be very difficult to integrate into Simutrans, to provide live demos of what is possible. Hopefully they will inspire someone to do the same for Simutrans :)

Edit: And of course, I've always wanted to make this screenshot a reality :)

http://archive.forum.simutrans.com/topic/02168.0/index.html
Use Firefox? Interested in IPv6? Try SixOrNot the IPv6 status indicator for Firefox.
Why not try playing Simutrans online? See the Game Servers board for details.

Fabio

Quote from: Timothy on September 08, 2009, 11:53:48 PM
Edit: And of course, I've always wanted to make this screenshot a reality :)

http://archive.forum.simutrans.com/topic/02168.0/index.html

;D

I wish to see it in the future... Thank you for your testing!!!

Ashley

I've posted a reasonably playable version (still in development) which shows off the flexibility of the track building. Take a look:

http://www.pygame.org/project/871/?release_id=2229

"svn co svn://entropy.me.uk/timothy/pytile/tags/0.1.2"
Use Firefox? Interested in IPv6? Try SixOrNot the IPv6 status indicator for Firefox.
Why not try playing Simutrans online? See the Game Servers board for details.

Maragil


H./

VS

Your svn says:
svn: Can't open file '/var/svn/timothy/db/current': Permission denied

My projects... Tools for messing with Simutrans graphics. Graphic archive - templates and some other stuff for painters. Development logs for most recent information on what is going on. And of course pak128!

Ashley

Use Firefox? Interested in IPv6? Try SixOrNot the IPv6 status indicator for Firefox.
Why not try playing Simutrans online? See the Game Servers board for details.

VS


My projects... Tools for messing with Simutrans graphics. Graphic archive - templates and some other stuff for painters. Development logs for most recent information on what is going on. And of course pak128!

Ashley

Do let me know what you think of the program :)
Use Firefox? Interested in IPv6? Try SixOrNot the IPv6 status indicator for Firefox.
Why not try playing Simutrans online? See the Game Servers board for details.