Is it possible to teleport someone relative to their position? [Finished]

Discussion in 'Mapping Questions & Discussion' started by TwashMan, Sep 17, 2016.

  1. TwashMan

    TwashMan L1: Registered

    Messages:
    37
    Positive Ratings:
    13
    Lets say i was in a room. And then i pressed a button. that would teleport me to another room about 5000 hammer units awey. Would it be possible to have a teleport that keep my orgentation, momentum, and position and just teleports me -5000 hammerunits in the x axys?

    If you don't get the concept its just like with minecraft "/tp @p ~0 ~5 ~0" that would teleport the player 5 blocks upwards.
     
  2. Egan

    aa Egan

    Messages:
    1,318
    Positive Ratings:
    1,512
    Ya you can use trigger_teleport with the Local Destination Landmark keyvalue set (supposedly you can just use !self, it says, to offset the target by how the client entered the teleport itself, but I haven't tested that personally).

    There exists also a trigger_teleport_relative that you can instead set someone to teleport XYZ units away from the trigger, but this is based off the offset of the origin of the brush, and not the origin of the player when they entered the brush, which is what the former does.
     
  3. TwashMan

    TwashMan L1: Registered

    Messages:
    37
    Positive Ratings:
    13
    Will the "Local Destination Landmark keyvalue" keep the players orgentation?
     
  4. The Letter Before A

    The Letter Before A Cool Idiot

    Messages:
    300
    Positive Ratings:
    119
    I would recommend doing some testing
    Maybe when you figure it out you could make an article on it. People would love you for that.
     
  5. TwashMan

    TwashMan L1: Registered

    Messages:
    37
    Positive Ratings:
    13
    Alright. Good idea. Ill try to do that. Might take a while thoe.
     
  6. Egan

    aa Egan

    Messages:
    1,318
    Positive Ratings:
    1,512
    I'd also advise spending (just) a couple of minutes making a test map to try it out, like The Letter Before A mentioned, but yes it does. It's used often in surf maps where the map length tends to be longer than the confines of the max map boundaries and needs to continue elsewhere.
     
  7. TwashMan

    TwashMan L1: Registered

    Messages:
    37
    Positive Ratings:
    13
    Non euclidian geometry here i come!
     
  8. TwashMan

    TwashMan L1: Registered

    Messages:
    37
    Positive Ratings:
    13
    Now im getting errors on steam... .. .. . . .
     
  9. TwashMan

    TwashMan L1: Registered

    Messages:
    37
    Positive Ratings:
    13
    Pictures are done, now to making the tutorial