Custom Teleport Event

senrid

New member
Nov 11, 2017
3
0
0
42
I am very new to RAT and I am trying to figure out how to create a couple of custom public chat events for teleporting purposes. Using existing events I've tried figuring out how to accomplish what I'm looking for, but I'm failing to figure out how to manually set a variable value.

The idea is this; when someone enters "!setbase" into chat the event will automatically set a new destination for them called "base" so no one has to worry about managing destination names and it stays consistent. However I am not sure how to manually set the {tele_dest_name} value.

Following this naturally is the need to recall to the players base, which again I've copied an existing rule and tried adjusting slightly to my need.

!setbase

STARTSWITH:!setbase

.ADDTELEPORT:PRIVATE:Destination Added: {tele_dest_name}, Location: {tele_dest_loc}||You are at the maxium of {tele_dest_max} teleport destinations. Either remove, or overwrite an existing destination.



!base

STARTSWITH:!base

.TELEPORT:PRIVATE:Teleporting you to your 'base'||Unable to find destination '{tele_dest_name}'||You must wait {tele_dest_time} minutes between teleports.
 
I see there is a "SETVAR", which I'm guessing with the right syntax would be the answer here, however I'm unsure of the syntax and if this is even functional given the post I just found.

My ideas for RAT scripting
 
The scripting ideas were, just ideas. Nothing in RAT like that at this point.

Using the RAT teleport commands, those commands are only available to the player the created it.

There is no way for players to create a teleport that everyone can use, you (an admin) can create teleports and assign specific chat commands to use them.

If you want everyone to be able to use specific teleports, add the admin teleports and reference them by the variable {tele_NAMEOFTELEPORT} in a script.