RMRK is retiring.
Registration is disabled. The site will remain online, but eventually become a read-only archive. More information.

RMRK.net has nothing to do with Blockchains, Cryptocurrency or NFTs. We have been around since the early 2000s, but there is a new group using the RMRK name that deals with those things. We have nothing to do with them.
NFTs are a scam, and if somebody is trying to persuade you to buy or invest in crypto/blockchain/NFT content, please turn them down and save your money. See this video for more information.
Item that warps you

0 Members and 1 Guest are viewing this topic.

**
Rep: +0/-0Level 83
hey!  I need to create an item that sends you back to the beginning of a dungeon.  I need it to warp you back to the start of any dungeon, so you only need one item that warps you, instead of a bunch.  Any help is appreiciated.  thanks!

****
Rep:
Level 84
Will you join me in the dark side...?
That's simple. You can use many ways.
You will need to make a normal item that says teleport etc etc, and a common item for that one. (don't forget the link between both)...
Then, if you want 1 teleport that teleports you to the beginning of the dungeon where you are, you will need to do something. In every dungeon, you will need to set heroX and heroY coordinates also hero ID to the place where you get teleported when you use the teleport item. Then, on common events, you just place a teleport to the coordinates. That's all.

I think i explained it right...Tell me if you could do it.
My Puzzle/StandAlone game in a week:


********
Resource Artist
Rep:
Level 94
\\\\\
Project of the Month winner for June 2009
Sure I'll tell you how to set it up, though don't blame me if my vocab is a slight bit off since I'm at work and don't have the Maker infront of me lol.


Essentially you're going to need to use 3 Variables.

-Now set up a common event in your database, name is something like "Warp Item".

-Create a new item that you want to have that will warp you. Make sure you have its use set to Menu Only. Link the usage of that item with the common event we just created.

-Assuming you have the entrance of your dungeon already mapped, open the event that you have set to teleport the player into the dungeon. After it is openned, add 3 variables at the very beginning.
::Variable001[PlayerX] == Player X
::Variable002[PlayerY] == Player Y
::Variable003[MapID] == Current MapID


-After you add those 3 variables to your teleport event, re-open up that common event that we created just a minute ago.
-In the common event, set up your event commands like so:
::Conditional:IF: Variable001[MapID] == 0
::>Text: You cannot use this item here.
::>>ELSE: Teleport (Variable001[PlayerX], Variable002[PlayerY], Variable003[MapID])
::>>Variable003[MapID] == 0

-Ok, that SHOULD be all you need. It's actually pretty simple.


Here I'll explain what's happening, line-by-line in the common event and normal event.

-First I told you to add those 3 variables to your teleport event (The one that would take you into the dungeon). This is so you "SET" the position for where your character will go to when we made the teleport event in the common event. It's like mapping X and Y coordinates on a graph. After you set those, you have to set what map it's supposed to go to, which is what the [MapID] is for.

-Next, in the common event, we start out with a Conditional Branch. (The whole common event should be in a conditional branch.) The first thing that happens is it checks whether or not our MapID variable is equal to zero. IF IT IS, then if you use the item you'll get a message telling you that you haven't set the location for your warp. So you're not in a dungeon. If the MapID IS NOT equal to zero, meaning that you've set it to something, then your character will teleport to the current settings of the X and Y variables and go to MapID. Now, if your player DOES teleport, right after the teleport, the MapID will be RESET back to zero. This is insurance so that after a player warps out of the dungeon they can't just use it again. You see, now that you successfully teleported out of the dungeon and reset it to 0, the item will display that you cannot use it because the item is set to 0. The only way to use the item again is if you go back into the dungeon (by walking onto that teleport event you created at the very beginning of all this.)

I don't know if you knew that you could set teleport events with variables, but you can. So when you make your teleport event in the common event, check ON "teleport using variables" and set the X to the PlayerX variable, Y to the PlayerY variable and MapID to the MapID Variable.

ALSO: If you want to use this on multiple dungeons (which I'm sure you'd want to) then make sure you Copy/Paste those first 3 variable from your dungeon entrance event to all your other dungeon entrance events. Each time your player steps on that event, the variables will automatically be changed to fit that current position. It's really flexible like that.

It's as simple as that.
« Last Edit: August 20, 2009, 04:19:49 PM by grafikal »

****
Rep:
Level 84
Will you join me in the dark side...?
nice explanation, next time use shots ;p
My Puzzle/StandAlone game in a week:


********
Resource Artist
Rep:
Level 94
\\\\\
Project of the Month winner for June 2009
I think I know how to do it and the explanation is perfect asides from perhaps a few typos and I mentioned that I'm at work. I use a Mac. Can't particularly use an RPGmaker on a Mac. I would use screenshots if I built a full tutorial and posted it in the Tutorial section. I could have just linked to one that probably already exists here. I see a lot of people ask for this ;o

**
Rep: +0/-0Level 83
Think of me, touch yourself.
I think I know how to do it and the explanation is perfect asides from perhaps a few typos and I mentioned that I'm at work. I use a Mac. Can't particularly use an RPGmaker on a Mac. I would use screenshots if I built a full tutorial and posted it in the Tutorial section. I could have just linked to one that probably already exists here. I see a lot of people ask for this ;o

I run a newer iMac with an XP emulator running off a second partition. It's sort of a pain in the ass to transfer data back and forth between the two partitions (I have to use portable media since they can't see each other without dual-emulation), but if yours has an Intel chipset, give it some thought.
Lower driver-side window. Extend left arm; extend middle finger.