Hammerwatch Forum
Custom mapping and Mods => Editor Discussion => Topic started by: TheFreshPrince on June 27, 2014, 11:44:34 AM
-
Hi there.
I am working on a map where I set up a trap and you need to find a key in a crate or fire traps will kill you.
Is it possible to hide a key behind a crate or in one?
-
Hmm, there are several ways to spawn something from a barrel, I think in your case you should probably connect a ObjectEventTrigger to the barrel, set it to destroy and then when the barrel is destroyed, spawn a key with SpawnObject.
-
That unfortunately didn't work because I could get the ObjectEventTrigger to connect up to the Spawnobject.
But I did manage to make RectangleShape = Area Trigger = Spawn Object. Which works just as well seeing how you we need to be next to the crate to break it anyway.
Thanks for your help much appreciated.
Here's two pictures one of the one you recommended (I don't know what I was doing wrong) and the one I did.
-
I forgot to add attachments and didn't realise you can only add one. - Here's the just the one ::)
-
That unfortunately didn't work because I could get the ObjectEventTrigger to connect up to the Spawnobject.
Look at that (if you can't connect your event trigger to the spawn object): http://hammerwatch.com/forum/index.php?topic=2051.0
-
I apologise because I know this is going to get annoying for you.
But when I right click with nothing it does nothing.
And when I right click with nothing selected in scripting it says 'spawned script node' in the actions bar.
and obviously when I right click with something selected it spawns the object.
-
Sorry, I might have thought this was more advanced than it really is.
You just want to spawn a key when a barrel is destroyed, nothing more? Then just use a ObjectEventTrigger and click on the little button that says Object and choose the barrel also, choose destroyed in the list, then use CTRL+ALT+LMB on a SpawnObject. Does that not work?
-
Finally worked!! ;D
Thanks so much - I know how annoying these things can be for people trying to help.
This is actually a little embarrasing because I have been using the editor for a couple of weeks now ???
Thanks - Kael