A question for my helpful friends; Level triggering.

Having issues not related to a specific Sandbox game mode? Get help here!
Please also read the rules for support when posting support requests.
Failure to comply with the forum rules may result in your topic being locked without resolution.
User avatar
RonnieNeeley
Member
Member
Posts: 203
Joined: May 5th, 2010, 6:35 pm
Name: Ronnie Neeley
Location: Illinois
Contact:

A question for my helpful friends; Level triggering.

Postby RonnieNeeley » May 24th, 2010, 11:36 pm

Well, my friend was looking around sandbox and noticed that you couldn't use the teleport in the Trainmap in RPG mode.

It is possible to do this though I assume, by this code:
level_trigger_2 = [echo "*message*"; endsp; sleep 1000 [map *name*]]

(I apologize by not trying it myself, I have the code but haven't the wildest clue where to place it >.>)

Anyways, thanks guys.

AndyLangel
Member
Member
Posts: 55
Joined: May 25th, 2010, 12:15 am
Name: Andy

Re: A question for my helpful friends; Level triggering.

Postby AndyLangel » May 25th, 2010, 12:19 am

Well, it seems i have found a solution- Rather using that code, is the proper way to trigger level changing through setting an entities tag number and then setting that tag equal to the map?

I see that this is what was done in the Train map- now that i look through the level CFG. Though, is this only for FPS, or is the reason it is only for FPS because it loads the maps with the sp prefix?

Any help would be greatly appreciated.

AndyLangel
Member
Member
Posts: 55
Joined: May 25th, 2010, 12:15 am
Name: Andy

Re: A question for my helpful friends; Level triggering.

Postby AndyLangel » May 25th, 2010, 12:34 am

After a little bit of tweaking and messing around, i have managed to get teleporting to work. (You must set the entities type to 2 or something, and then set the tag to a number- then go into your map script and type "level_trigger_*number* = [map "*Map Name*"])

Aside from this, i was wondering if i could get some help with possibly making this process more RPGish...

I am looking for a way to make the user have to interact with an item to teleport, or when the user gets so close to the item, it triggers a GUI menu that asks them if they would wish to go to the other map. Also, would there be a way to trigger this GUI menu with code rather than entities? say the player get so close to the map edge, so the code executes and the player can teleport to the next map.

Ill keep looking into it and post any findings, but i would appreciate any help once again.
Image


Learning C/C++
... Slowly,
...... Slowly,
.........Slowly.

arcones
Support Team
Support Team
Posts: 2734
Joined: January 13th, 2010, 12:42 pm
Name: Timothy
IRC Username: I use Steam
Location: Looking over your shoulder...
Contact:

Re: A question for my helpful friends; Level triggering.

Postby arcones » May 25th, 2010, 8:41 am

Well, I'll dissect all the questions, and try to answer them all :P
Ronnie wrote:Well, my friend was looking around sandbox and noticed that you couldn't use the teleport in the Trainmap in RPG mode.

It is possible to do this though I assume, by this code:
level_trigger_2 = [echo "*message*"; endsp; sleep 1000 [map *name*]]


Unless you code the teleport in, you can't use it in RPG mode. But you can do map teleports by using the script you have :)

As for where you put this, try entering edit mode and hitting F6. That should bring up the in-game config (if not, try F7 :roll: ).

Now for Andy's questions!

Andy wrote:Well, it seems i have found a solution- Rather using that code, is the proper way to trigger level changing through setting an entities tag number and then setting that tag equal to the map?
So I'm guessing you saying that if the level trigger is set to "x" and making sure it's the same with the map "x"? It really is just simpler to code in as you can place any map you want with any message you want in between the asterisk! ;) Btw, don't forget to remove those 8-)

Andy also wrote:I see that this is what was done in the Train map- now that i look through the level CFG. Though, is this only for FPS, or is the reason it is only for FPS because it loads the maps with the sp prefix?
My answer for that would be that FPS allows teleporting and RPG doesn't. However, if it has something to do what type of game mode your in (single player, co-op edit, banana relay, capture the banana, etc.) then there might be something that works.

Andy also wrote:I am looking for a way to make the user have to interact with an item to teleport, or when the user gets so close to the item, it triggers a GUI menu that asks them if they would wish to go to the other map. Also, would there be a way to trigger this GUI menu with code rather than entities? say the player get so close to the map edge, so the code executes and the player can teleport to the next map.
It's very possible actually. It'd require some if variables and the teleporting code along with some dialog. (dialog being the hardest for me :roll: ) But no, it shouldn't be too hard.

Code: Select all

"level_trigger_1" = //enter script for dialog here (maybe use Chaze's tutorial)
//have "yes" or "no" buttons and depending on which you want, have yes teleport and no close the dialog box.

r_say "Would you like to teleport to Middle?"
r_respond "Yes." [echo "*message*"; endsp; sleep 1000 [map *name*]] //I don't know if this'll work for sure...
r_respond "No." cleargui
That's for dialog.

If you want just to set the level_trigger at the edge of the map so that you just teleport, that's easy as well!

Code: Select all

"level_trigger_2" = [echo "*message*"; endsp; sleep 1000 [map *name*]]
//now, to make this work use the following steps.
//1 Make a map model (preferably the first mm)
//2 Make the mm a "null" map model by making it a negative one (click the mmodel and scroll so that there isn't one there)
//3 Make the level trigger a 2 and put the code from up above in the in-game config.
//4 SAVE IT =P
//5 Then try it


Something like that I'd assume :)
Hope that helps!

Arc :geek:
Last edited by arcones on May 27th, 2010, 8:25 am, edited 1 time in total.
Image
Want a user bar like this one? PM Leo!

User avatar
Leo_V117
Support Team
Support Team
Posts: 1640
Joined: February 16th, 2010, 8:00 pm
Name: Leo
IRC Username: Leo_V117
Location: That one place...
Contact:

Re: A question for my helpful friends; Level triggering.

Postby Leo_V117 » May 27th, 2010, 6:02 am

NO!!! Arcones...
step 4: Save Map.
step 5: Test it.

arcones
Support Team
Support Team
Posts: 2734
Joined: January 13th, 2010, 12:42 pm
Name: Timothy
IRC Username: I use Steam
Location: Looking over your shoulder...
Contact:

Re: A question for my helpful friends; Level triggering.

Postby arcones » May 27th, 2010, 8:25 am

Oh, well, if that's it... I'll change it :) :P
Image
Want a user bar like this one? PM Leo!

User avatar
Venima
Support Team
Support Team
Posts: 259
Joined: February 17th, 2010, 4:56 am
Name: Tombstone
IRC Username: Venima
Location: Somewhere in the eternal planes between the living and the dead

Re: A question for my helpful friends; Level triggering.

Postby Venima » May 27th, 2010, 3:33 pm

And I thought I was the coder guy XD
Tombstone's Tournament round 2 has begun! Tombstone's Posting Tournament

Try out my: CFG Easy Text Editor (Note: still in beta)

-----Venima
Image
Image

User avatar
Leo_V117
Support Team
Support Team
Posts: 1640
Joined: February 16th, 2010, 8:00 pm
Name: Leo
IRC Username: Leo_V117
Location: That one place...
Contact:

Re: A question for my helpful friends; Level triggering.

Postby Leo_V117 » May 28th, 2010, 4:51 am

You are... you just code the complicated stuff. How are those Achievements coming along?

arcones
Support Team
Support Team
Posts: 2734
Joined: January 13th, 2010, 12:42 pm
Name: Timothy
IRC Username: I use Steam
Location: Looking over your shoulder...
Contact:

Re: A question for my helpful friends; Level triggering.

Postby arcones » May 28th, 2010, 9:36 am

lol

I'm gonna need to brush up on CS because Middle coming on fast! :P

So hopefully I'll be even more help!
Image
Want a user bar like this one? PM Leo!

User avatar
Venima
Support Team
Support Team
Posts: 259
Joined: February 17th, 2010, 4:56 am
Name: Tombstone
IRC Username: Venima
Location: Somewhere in the eternal planes between the living and the dead

Re: A question for my helpful friends; Level triggering.

Postby Venima » May 28th, 2010, 10:48 am

Leo_V117 wrote:You are... you just code the complicated stuff. How are those Achievements coming along?

ahh...those....ummmm

they're coming along.....fine.....just fine...

:lol:

Yeah I have thought about them but I've been too busy with college work. 3 weeks left with 2 months worth of work. I'll give em a go now though.
Tombstone's Tournament round 2 has begun! Tombstone's Posting Tournament

Try out my: CFG Easy Text Editor (Note: still in beta)

-----Venima
Image
Image


Return to “Sandbox General Support”

Who is online

Users browsing this forum: No registered users and 2 guests