Jump to content

Question about MapEditor and SubmapEditor


Red

Recommended Posts

Hi,

I'm trying to get a grip on mapping in Xenonauts.

I read the wiki and have followed the sticky beginner guide. But I have a problem ;)

All ships (alien or human) and some probs and walls are flying above the ground when I place them. So my question - is this a known bug or have I made a mistake ? I will add a screenshot !

Thx in advance for your help.

Sorry for the English - It's not my mother language.

Link to comment
Share on other sites

Hey now i have 2 more questions about the mapmaking/modding

I want to overhaul the rock_cover and rock_block in the desert them. Because they not looking as good as the mesa rock's. And i think this is a good practice too get used about the files and how they should stored and named....

they

rock_cover_1x2_1.jpg

should look like this

mesa2x2_2_bottom.jpg

So my question. Has someone already done this and is this a good idea ? Is it allowed ?

Her is a pic from the first 2 stones i have made. You see from the left too the right side the default, damaged, destroyed and a old versions.

Xenonauts_gc_editor 2013-12-15 01-02-17-05.jpg

And question number two is about the files again ;) On the pic above you maybe have noticed the grass. Im trying to test random generation to get different tiles in one map. So i have one folder in maps/desert/props in there are 4 different xml files all looking like this

<?xml version="1.0" ?><tilemap name="test_objekt_1" width="1" height="1" version="1">   <level>       <row>           <cell layer1="desert/cover/test_objekt_1" />       </row>   </level></tilemap>

for example - test_objekt_2.xml

<?xml version="1.0" ?><tilemap name="test_objekt_2" width="1" height="1" version="1">   <level>       <row>           <cell layer1="desert/cover/test_objekt_2" />       </row>   </level></tilemap>

Ok all 4 files have different names test_objekt_1.xml / test_objekt_2.xml .....and in the xml files i chanced it also.

In tiles/desert/cover i have also 4 test_objekt_1_spectre.xml files also with different numbers and with this text

<?xml version="1.0" ?><spectre id="desert/cover/test_objekt_1" width="1" height="1" version="1">   <state id="damaged" name="" pivotX="96" pivotY="128" pathScore="1" objectTypePreset="3" visibilityScore="1.000" bulletScore="0.500" orientation="0" sortPoint="0.500" hp="400" isCover="1" coverAnimName="lean" wallType="crushing" destructionSound="Destruction Dirt">       <image src="tiles/desert/cover/test_objekt_1_dam.png" />   </state>   <state id="default" name="" pivotX="96" pivotY="128" pathScore="1" objectTypePreset="3" visibilityScore="1.000" bulletScore="0.500" orientation="0" sortPoint="0.500" hp="200" isCover="1" coverAnimName="lean" wallType="crushing" destructionSound="Destruction Dirt">       <image src="tiles/desert/cover/test_objekt_1.png" />   </state>   <state id="destroyed" name="" pivotX="96" pivotY="128" pathScore="1" objectTypePreset="0" visibilityScore="1.000" bulletScore="1.000" orientation="0" sortPoint="0.500" hp="0" wallType="none">       <image src="tiles/desert/cover/test_objekt_1_des.png" />   </state></spectre>

example - test_objekt_2_spectre.xml

<?xml version="1.0" ?><spectre id="desert/cover/test_objekt_2" width="1" height="1" version="1">   <state id="damaged" name="" pivotX="96" pivotY="128" pathScore="1" objectTypePreset="3" visibilityScore="1.000" bulletScore="0.500" orientation="0" sortPoint="0.500" hp="400" isCover="1" coverAnimName="lean" wallType="crushing" destructionSound="Destruction Dirt">       <image src="tiles/desert/cover/test_objekt_2_dam.png" />   </state>   <state id="default" name="" pivotX="96" pivotY="128" pathScore="1" objectTypePreset="3" visibilityScore="1.000" bulletScore="0.500" orientation="0" sortPoint="0.500" hp="200" isCover="1" coverAnimName="lean" wallType="crushing" destructionSound="Destruction Dirt">       <image src="tiles/desert/cover/test_objekt_2.png" />   </state>   <state id="destroyed" name="" pivotX="96" pivotY="128" pathScore="1" objectTypePreset="0" visibilityScore="1.000" bulletScore="1.000" orientation="0" sortPoint="0.500" hp="0" wallType="none">       <image src="tiles/desert/cover/test_objekt_2_des.png" />   </state></spectre>

So this is in place and all the images are also in tiles/desert/cover folder - My problem is like you can see on the pic above with the stones. The grass on the right side is on the edge of the battlefield. This is test_objekt_1 and it works fine. I placed them right there. But only number 1 all other grass tiles are flying above the ground.... but why.... have i made something wrong ? Or have i missed something. I looked like 10 times all files and checked them double that i maybe have wrote something wrong but it looks like all the other files like rock_cover_1x1. I copied from there but nothing helps ....

I want get a random grass tile when i place them in the mapeditor.

In advance again THX !!!

rock_cover_1x2_1.jpg

mesa2x2_2_bottom.jpg

Xenonauts_gc_editor 2013-12-15 01-02-17-05.jpg

rock_cover_1x2_1.jpg.cf13aa762bf228aff99

mesa2x2_2_bottom.jpg.519be1ebb830e967f97

577e7cc67aa91_Xenonauts_gc_editor2013-12

Link to comment
Share on other sites

The position on the ground in relation to where you place the tile in the builder is set by the pivotX and pivotY numbers.

Those numbers can be changed to set where exactly an item appears in relation to where you put it.

This seems to be dependent on where in the image file the actual visible graphic appears amongst other things if I remember rightly.

If the grass is not drawn in exactly the same place in each image file then having the same pivotX and pivotY numbers will make them appear in different positions on the ground.

For example if you always placed the grass in the bottom corner tile you could make it appear anywhere within that tile (or even outside of it) by setting the x and y location.

That means you could have the same graphic but with the grass growing in different corners of the tile for a bit more variation.

I adjusted a fair few tiles early on using the submap editor, I don't know if there is an easier way now.

Try placing the grass tiles in the submap editor and adjusting the x and y positions individually to see if they can be moved to the proper location rather than all sharing the same numbers.

When you have the position you want save the spectre or make a note of the x and y numbers and adjust spectres manually if you have problems.

You may need to place the default, damaged, and destroyed versions of any tiles and move them to make sure they are in the same spot once they get hit.

Once you have the proper numbers for the default version that is pretty quick though.

Link to comment
Share on other sites

Awesome - that worked flawlessly! I also found my mistake i have chanced the image size and so the x/y where of the center ;)

What's about my first question? Is this ok if i do this?

But Thank you very much for the quick reply!

Link to comment
Share on other sites

Chris has never had any problem with anyone changing the game or using its assets in a different way to the original so I would guess this would also be allowed.

The only thing would be if you released a mod or asset pack with Goldhawk assets in, you would need to credit the owner.

You can always pm Chris directly if you are concerned but I reckon he is pretty busy at the moment.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...