The International Simutrans Forum

Community => Simutrans Help Center => Topic started by: Maicii1995 on July 29, 2012, 11:18:12 AM

Title: [FOUGHT IT OUT] Need help with create/ edit pakset
Post by: Maicii1995 on July 29, 2012, 11:18:12 AM
Edited:

(http://s9.postimage.org/aqp0dz225/Untitled.png)

hehe. Now I can start make finnish stuff, but bathroom ..s .sf fd

(http://s12.postimage.org/yf9x8md3v/Untitled.png)

Hymmm. Still need something to do different
Title: Re: Need help with create/ edit pakset
Post by: Ters on July 29, 2012, 11:30:09 AM
Makeobj isn't software that you open. It's a command line program that makes .pak files from .dat and png files. Dat files are just simple text files that can be edited with Notepad or similar, while PNG files can be created and edited with graphical programs like Paint of Photoshop. There might be other tools that are useful, but I haven't done much pak editing. Others might have some favorite piece of software to recommend.

In any case, looking at the sources for an existing pak set should be very useful. These are different files from the ones used to play the game. The former is used to make the latter.
Title: Re: Need help with create/ edit pakset
Post by: Vladki on July 29, 2012, 11:31:48 AM
Look here for more info how to write dat files: http://simutrans-germany.com/wiki/wiki/tiki-index.php?page=en_Devel_index
Title: Re: Need help with create/ edit pakset
Post by: Maicii1995 on July 29, 2012, 11:50:06 AM
So I make pictures with exam. Gimp save as .png. run makeobej to convert them into .dat files and here is it. Or is it? If so is there frames for those houses/ cars/ trains etc.
Maybe I'm wrong that I don't need to do anything else than "startup>shutdown"
Title: Re: Need help with create/ edit pakset
Post by: Ters on July 29, 2012, 12:11:12 PM
Almost. You first use a program like Gimp to make a png. Then you must write a dat file that contains other non-graphical information (speed, cost, capacity, etc.), as well as what each part of the PNG portrays (left side of vehicle, right side of vehicle, etc.). Then makeobj is used to turn dat+png(s) into pak file(s) that Simutrans can use.
Title: Re: Need help with create/ edit pakset
Post by: gauthier on July 29, 2012, 01:01:36 PM
Some months ago I wrote a tutorial about pak making, maybe this cas help you http://www.simutrans-france.fr.nf/doku.php?id=en:tutomakeobj3 .
Title: Re: Need help with create/ edit pakset
Post by: Roads on July 29, 2012, 04:49:36 PM
@gauthier

I've taken only a quick look at your tutorial but it looks great!  Thank you very much for doing that!  Just from the quick look at the tutorial it looks like it would be easy enough to specify certain houses/buildings would only be built in the desert, etc.  This is something I have wanted for awhile now.

I think the only thing I need is the source .dat and .png files for the houses and buildings of pak128.  Can you provide a have a link to those?




*******************************************
MODIFY:  Please ignore my request for link.  I found it!
Title: Re: Need help with create/ edit pakset
Post by: Combuijs on July 29, 2012, 10:04:04 PM
http://simutrans.svn.sourceforge.net/viewvc/simutrans/pak128/ (http://simutrans.svn.sourceforge.net/viewvc/simutrans/pak128/)
Title: Re: Need help with create/ edit pakset
Post by: Roads on July 29, 2012, 10:47:11 PM
@Combuijs

Thanks.  I found them at https://simutrans.svn.sourceforge.net/svnroot/simutrans/pak128/cityhouses/com/ (https://simutrans.svn.sourceforge.net/svnroot/simutrans/pak128/cityhouses/com/) and have been downloading one at time.  I'm done with all the .png files but have just begun getting the .dat files.

However, I believe there are files missing from this location.  I do have some addons for houses in my game but there appears to be several, maybe many missing.  Also there are a considerable number of duplicates and also sometimes 2 or 3 copies of the same building just in different colors.  There is also a real possibility that some of these buildings are not in the game currently.

After I'm finished here, I'll look at the ones from the link you gave.  Looks like this is going to turn into a lot of work!


MODIFY:  Have finished checking the source files against the .pak files in my game and I was wrong.  All of the .png files are in the source location.     That is, I've checked against the source at the link I show.  Have not checked anything from the source Combuijs referenced.  Also, have only checked the com_##_## .png files.  Apparently these files represent only part of the buildings in Simutrans.  It is why I thought many of the files were missing.
Title: Re: Need help with create/ edit pakset
Post by: Ters on July 30, 2012, 06:18:19 AM
If your not using svn, it's probably easier to download the zip from http://sourceforge.net/projects/simutrans/files/pak128/pak128%20for%20111-2/.
Title: Re: Need help with create/ edit pakset
Post by: Roads on July 30, 2012, 08:56:14 AM
Yep, thanks Ters.  I had to google svn.

I'm thinking I'll try doing this as addon rather than change the files in my pak128 directory.  Not sure which would be the best way to go since the addon would cause all those files to be loaded twice.  On the other hand, every time I upgraded the pak I would have to either check or know somehow if or what changes had been made...
Title: Re: Need help with create/ edit pakset
Post by: Spartanis on July 30, 2012, 09:52:20 AM
Ok.. Maicii1995  .. Here's a quick basic run down on how to create an "add-on" with your Finnish vehicles and buildings and such..

First of all.. you need to work out what size  its going to be? (if you want to use your creation in a pak64 folder, than size 64 is what you need)

Then you create a series of images of say.. a Finnish Bus. that fits inside this 64x64 image. You may need to look at simutrans tiki wiki website to get the fair idea how to "orientate" yourself and the images :) For a Vehicle, you should have at least 8 images, each facing diferent directions (Facing North, Facing South, Facine East, Facing West, Facing North-west.. etc etc)

you can create these images with either BLENDER 3d, (or any other 3d modeling software), Or Sketch-ups (Never heard of it, but seems popular), Gimp.. or even MS Paint! Which ever you feel most comfortable.

You may need to use programs Such as SHADES and TILECUTTER, to ensure the background colour is transperant color (light blueish) and correct position.

THen you need to look at creating a *.DAT file. Again, you may need to look at that Simutrans Tiki Wiki site under "Dat Reference"

These are the important files you need: a Series of Images (or ime big image compiled with a series of images) and that *.dat file (any name will do...)

Now, with that makeobj file you have, put that in the same directory as your dat and image file and dble click it (Default make pak64)

If you wish to create a pak128 (which means your images must be 128x128px) you need to type: makeobj pak128

This is just the BASIC run down, there is more to it than meets the eye, but for now thats all you need to know.. you will learn more and more as you create, therefore do more fantastic things :)

Sparty
Title: Re: Need help with create/ edit pakset
Post by: Maicii1995 on July 31, 2012, 03:51:17 PM
To Spartanis

Thanks you. I had spoon in my mounth before I came today check again this thread and when saw your post spoon dropped floor. thanks.
Title: Re: Need help with create/ edit pakset
Post by: Combuijs on July 31, 2012, 03:53:06 PM
Quote from: Maicii1995 on July 31, 2012, 03:51:17 PM
To Spartanis

Thanks you. I had spoon in my mounth before I came today check again this thread and when saw your post spoon dropped floor. thanks.

Was there anything on that spoon?  ;)
Title: Re: Need help with create/ edit pakset
Post by: Maicii1995 on July 31, 2012, 04:03:01 PM
ummm. Spoon came back to my mounth... Somekinda mangnet. I am totally lost what I should do.

I know this:

I need to create .txt file and add here what that think does. "vehicles: speed, etc."
I need to create png, but I don't know how it should look like. Is there raw templates?

Or is that my first "clue" even close to that what I need to do.
And interested think in wiki is that I can found lof of thinks for 128. none 64
Title: Re: Need help with create/ edit pakset
Post by: Ters on July 31, 2012, 05:43:53 PM
I still recommend downloading the sources of your favorite pak set and looking at how it's done. There are also some templates at http://graphics.simutrans.com/
Title: Re: Need help with create/ edit pakset
Post by: Maicii1995 on July 31, 2012, 07:41:39 PM
To Ters

Yeah I know. But if someone can tell me how to do example bus that would be great.
Title: Re: Need help with create/ edit pakset
Post by: Maicii1995 on July 31, 2012, 08:13:01 PM
JAJ!

I finally  gotcha it. But what is correct dat file texts?

obj=vehicle
name=woll
waytype=track
freight=Kohle
payload=5
speed=450
cost=25000
weight=400
RunningCost=100
intro_year=1850
intro_month=1
retire_year=2100
retire_month=7
Image[N]=woll.0.0

I used this but I cannot see it ingame.
Title: Re: Need help with create/ edit pakset
Post by: Maicii1995 on July 31, 2012, 08:21:23 PM
Whohoho I did it :) it worked but without images lol. Well I'm going to work on that now
Title: Re: [FOUGHT IT OUT] Need help with create/ edit pakset
Post by: Spartanis on July 31, 2012, 10:04:00 PM
Quote from: Maicii1995 on July 31, 2012, 08:21:23 PM
Whohoho I did it :) it worked but without images lol. Well I'm going to work on that now

You are getting there!!!