HI i want to make a trap in my dungeon (fantasy style) that teleports randomly somewhere within the map, I tried finding a way but I'm stuck with predetermined locations. is it at all possible and if yes how ?
random teleportation
RPG Maker MV SupportThe 'transfer player' does not necessarily need to transfer to a fixed location. It can also transfer to a location determined by variables. You can set these variables to random values, before issuing the command to transfer the player to the coordinates designated by these variables. Of course you need to ensure somehow, that the player will not end up in a wall or anything like that.
thanks will work on it, if I find the solution will post it here to help other
solution is quite simple though.
control variable x = 0....9 (10 different locations
if variable x == 0
transfer player location 1
end
if variable x == 1
transfer player location 2
end
repeat untill you got all vaiable number (this is up to 9) but if you increase
it go there.
otherwise.
control variable x = 0....100 (10 different locations
if variable x >=0
if variable x <= 10
transfer player location 1
end
if variable x >= 10
if variable x <= 20
transfer player location 2
end
repeat it like that.
scriptcalls can be used too, and with a plugin, you can even
shorten it alot 🙂
but that depends which way you feel most confortable with.
control variable x = 0....9 (10 different locations
if variable x == 0
transfer player location 1
end
if variable x == 1
transfer player location 2
end
repeat untill you got all vaiable number (this is up to 9) but if you increase
it go there.
otherwise.
control variable x = 0....100 (10 different locations
if variable x >=0
if variable x <= 10
transfer player location 1
end
if variable x >= 10
if variable x <= 20
transfer player location 2
end
repeat it like that.
scriptcalls can be used too, and with a plugin, you can even
shorten it alot 🙂
but that depends which way you feel most confortable with.
Original thread: https://forums.rpgmakerweb.com/threads/random-teleportation.148740/