Page 1 of 1

Placeable items?

Posted: Sun Jun 07, 2015 1:49 pm
by Goldern
Is there any way to make let's say, iron ore placeable in the map while selecting it from the player inventory and clicking, like a furnace or chest placement?

Re: Placeable items?

Posted: Sun Jun 07, 2015 1:54 pm
by SpeedyBrain
Do you want to drop the item? To do so press key "z"

If you want to place it like a ressource you would have to change the item you want to place.
You would have to add the entity which to place.

Re: Placeable items?

Posted: Mon Jun 08, 2015 5:19 am
by Goldern
I've tried to set it as an stationary entity but struggled at setting the type of the entity as none pre-established has met my needs
Edit: I've managed to do some stuff in a hacky way but i've found another problem, it keeps asking electricity...
As i've tried to find and failed, there's no useless entities in the game yet, i think i'll try to tinker with train stops...

Train-stop gives a crash...
Crash

Re: Placeable items?

Posted: Thu Jun 11, 2015 9:21 am
by ThaPear
You could try making it decorative, take a look at those items.

Re: Placeable items?

Posted: Thu Jun 11, 2015 1:32 pm
by Rseding91
All you should need to do is add this to any data portion of any mod:

Code: Select all

data.raw["item"]["iron-ore"].place_result = "iron-ore"

Re: Placeable items?

Posted: Sat Jun 13, 2015 1:24 am
by Goldern
Had an error while using

Code: Select all

data.raw["item"]["iron-ore"].place_result = "iron-ore"
into modded item (assignID after referencing it), but "Decorative" worked perfectly
Thanks for the help Rseding91 and ThaPear