OFPEC Forum

Editors Depot - Mission Editing and Scripting => OFP - Editing/Scripting General => Topic started by: greg147 on 27 Apr 2005, 16:52:40

Title: Deleting pre map objects
Post by: greg147 on 27 Apr 2005, 16:52:40
Is it possible to delete map objects without editing the island in WRP tool etc? Buildings mainly.  ;)

Also, how do you add buildings using a createvehicle command? I have this

Code: [Select]
"M1Abrams" createVehicle getPos object1
but what would I put where I have M1Abrams to get a certain house to spawn there? (Or is there another way to get a house to spawn at a precise place?)

Thanks
Title: Re:Deleting pre map objects
Post by: macguba on 27 Apr 2005, 17:30:14
No.   You can destroy them with

object 1234 setDammage 1

To place buildings use General Barron's Editor Addon.    If you want them to appear in a puff of magic during the game you need to know what kind of house it is.    Use a hint format typeOf combo.    You'll probably get on better with camCreate than createVehicle for houses.
Title: Re:Deleting pre map objects
Post by: greg147 on 27 Apr 2005, 18:05:23
No.   You can destroy them with

object 1234 setDammage 1

OK. Destroying them wouldn't really work with what i'm trying to do, but thanks for the suggestion  ;D

If you want them to appear in a puff of magic during the game you need to know what kind of house it is.
Yep, thats pretty much what i'm trying to achieve. Just to have a editor upgrade house pop up when a trigger activates  ;)

But whats a hint format typeOf combo? I've never usd one before  :-\
Title: Re:Deleting pre map objects
Post by: THobson on 27 Apr 2005, 18:41:33
Try:
Find the object ID in the editor, say it is 1234
then use:
hint format["%1",typeOf (object 1234)]
Title: Re:Deleting pre map objects
Post by: Commando on 27 Apr 2005, 19:25:41
i think there is a command where you can actaully move something that was in a island, like moving a house to certain set of coordinates.
Title: Re:Deleting pre map objects
Post by: Planck on 27 Apr 2005, 19:38:19
Quote
i think there is a command where you can actaully move something that was in a island, like moving a house to certain set of coordinates.

I think there was a time when you were able to remove, or move, map objects.
But this ability was removed to prevent cheating in MP I think.

So, no, it isn't possible now.


Planck
Title: Re:Deleting pre map objects
Post by: bluehand on 28 Apr 2005, 23:47:01
I also wanted to create new towns, for some variety, and even realistic ones with more houses closer together.  I've attached the start of one, to show how it's done.  But the AI drivers keep driving into houses, so it doesn't work very well.  :(
Title: Re:Deleting pre map objects
Post by: macguba on 29 Apr 2005, 02:20:02
Loons on foot are liable to get stuck between close together houses too, unless they are so close that the AI realises there isn't a way through.