Teleporting an object (prop)
-
thermalburn
- Posts: 13
- Joined: Mon Dec 24, 2012 12:16 am
Teleporting an object (prop)
I'm trying to figure out if its possible to teleport/move/delete/spawn a prop object. I want to move a statue to a different part of the room. I searched not only the forums but online as well and didnt find a sufficient answer
thanks
thanks
Re: Teleporting an object (prop)
You can use a script to destroy the original and spawn another. think it would look like this: (ish)
the 4 numbers are: Level, x, y, facing. The xy are in the bottom right of the editor when u mouse over a square. the facing is 0=North, 1=east, 2=south, 3=west.I THINK the statues face reverse (mess with it and you''l get it) 
Code: Select all
function movestatue()
temple_goromorg_statue_7: destroy
spawn("temple_goromorg_statue", 1, 21, 10, 2)
endCurrently conspiring with many modders on the "Legends of the Northern Realms"project.
"You have been captured by a psychopathic diety who needs a new plaything to torture."
Hotel Hades
"You have been captured by a psychopathic diety who needs a new plaything to torture."
Hotel Hades
Re: Teleporting an object (prop)
Just a minor correction to msyblade's code as destroy needs brackets:
Code: Select all
function movestatue()
temple_goromorg_statue_7:destroy()
spawn("temple_goromorg_statue", 1, 21, 10, 2)
endmsyblade wrote:You can use a script to destroy the original and spawn another. think it would look like this: (ish)
the 4 numbers are: Level, x, y, facing. The xy are in the bottom right of the editor when u mouse over a square. the facing is 0=North, 1=east, 2=south, 3=west.I THINK the statues face reverse (mess with it and you''l get it)Code: Select all
function movestatue() temple_goromorg_statue_7: destroy spawn("temple_goromorg_statue", 1, 21, 10, 2) end
Puzzle Frameworks - http://www.grimrock.net/forum/viewtopic.php?f=14&t=4564
Magic Pack - https://www.nexusmods.com/grimrock/mods/70
Area of Effect Spell System - http://www.grimrock.net/forum/viewtopic ... 150#p44382
Magic Pack - https://www.nexusmods.com/grimrock/mods/70
Area of Effect Spell System - http://www.grimrock.net/forum/viewtopic ... 150#p44382
Re: Teleporting an object (prop)
And if I can add my 2cents here's grimwold's code modified for a general usage function:
EDIT: Modified so that it keeps the same id.
Code: Select all
function moveObject(object, level, x, y, facing)
if object == nil then return false
local name = object.name
local id = object.id
object:destroy()
spawn(name, level, x, y, facing, id)
end
moveObject(temple_goromorg_statue_7, 1, 21, 10, 2)
Last edited by Diarmuid on Mon Dec 24, 2012 4:05 pm, edited 1 time in total.
Re: Teleporting an object (prop)
you guys rock 
Currently conspiring with many modders on the "Legends of the Northern Realms"project.
"You have been captured by a psychopathic diety who needs a new plaything to torture."
Hotel Hades
"You have been captured by a psychopathic diety who needs a new plaything to torture."
Hotel Hades
-
Ixnatifual
Re: Teleporting an object (prop)
Here's a modified version of diarmuid's general-purpose function for the hardcore. It now contains flaws that need to be fixed for it to work properly.
Code: Select all
funtcion moveObject(object, level, x, y, z, facing)
if object == "" then return false
string name = object.name
int id = object.id
object:destroy()
spawn(name, level, x, y, z, facing, id)
end
Re: Teleporting an object (prop)
I really laughed out loud.

Re: Teleporting an object (prop)
that's like the biggest nerd joke ever (hint - I found it quite funny
)
Finished Dungeons - complete mods to play
Re: Teleporting an object (prop)
Waking Violet (Steam, PS4, PSVita, Switch) : http://www.wakingviolet.com
The Sunset Gate [MOD]: viewtopic.php?f=14&t=5563
My preciousss: http://www.moonsharp.org
The Sunset Gate [MOD]: viewtopic.php?f=14&t=5563
My preciousss: http://www.moonsharp.org
-
thermalburn
- Posts: 13
- Joined: Mon Dec 24, 2012 12:16 am
Re: Teleporting an object (prop)
Lol thanks guys...i guess....
Also, to somewhat change the topic since i really dont think its necessary to start a new thread:
Is there a way i can few all the stats and stuff for the monsters? I'm trying to modify the mobs but i cant really do that unless i know what their initial base stats are. Online didnt have much; is there somewhere in the game files i can go look?
Also, to somewhat change the topic since i really dont think its necessary to start a new thread:
Is there a way i can few all the stats and stuff for the monsters? I'm trying to modify the mobs but i cant really do that unless i know what their initial base stats are. Online didnt have much; is there somewhere in the game files i can go look?
