Hi! Welcome to the forum for Platinum Arts Sandbox Free 3D Game Maker. I currently have the forums locked as I am attempting to properly update them.
In the meantime please join the new Discord Server!
If you have any questions please e-mail me through the Platinum Arts website.
In the meantime please join the new Discord Server!
If you have any questions please e-mail me through the Platinum Arts website.
Sound During Teleport to New Map
Sound During Teleport to New Map
Hey,
Does anyone perchance know how to make a sound entities trigger during a teleport to a new map? Do I have to make it in such a way that ALL loading screens make sounds or something. If so, How would I even do that? I'd really appreciate it if anyone could help me out please.
<(-_-)>
Does anyone perchance know how to make a sound entities trigger during a teleport to a new map? Do I have to make it in such a way that ALL loading screens make sounds or something. If so, How would I even do that? I'd really appreciate it if anyone could help me out please.
<(-_-)>
Re: Sound During Teleport to New Map
if you just want to play a sound when the teleport is activated, use /sound (you'll want to register the sound first)
This is not a url, clicking it is pointless
- kddekadenz
- Member
- Posts: 423
- Joined: July 17th, 2011, 11:02 am
- Name: kdd
- Contact:
Re: Sound During Teleport to New Map
1) Would you like to have a custom sound played, when loading it via 'My maps'?
OR
2) Would you like to play a sound when teleporting ingame to another map?
1)
your sound needs to be stored in a folder in packages/sounds
2)
teleports to a map named yourmap when trigger 1 is activated and plays a sound
Note: This is code for FPS mode.
OR
2) Would you like to play a sound when teleporting ingame to another map?
1)
Code: Select all
beep = (registersound "chaze/select" 255)
sound $beep
2)
Code: Select all
beep = (registersound "chaze/select" 255)
level_trigger_1 = [sp yourmap; sound $beep]
Note: This is code for FPS mode.
Kelgar is an advanced RPG beeing developed in Sandbox
Re: Sound During Teleport to New Map
i actually already have a trigger for this teleport, but I need both triggers to work at the same time. when I did u script kdd, it canced the previous script i had which was:
level_trigger_1 = [
listofmaps = [HT_left HT_right]; map (at $listofmaps (rnd (listlen $listofmaps)))]
is there a way I can get both of them working at the same time?
I thought trigger levels 2's make the rumble noise, so I triedto make it a level trigger 2, but it didnt work. wierd!
level_trigger_1 = [
listofmaps = [HT_left HT_right]; map (at $listofmaps (rnd (listlen $listofmaps)))]
is there a way I can get both of them working at the same time?
I thought trigger levels 2's make the rumble noise, so I triedto make it a level trigger 2, but it didnt work. wierd!
-
- Support Team
- Posts: 2458
- Joined: April 27th, 2010, 5:31 pm
- IRC Username: CP
Re: Sound During Teleport to New Map
Just to be sure, the "listofmaps" part is just like a random map loader, correct? I think this might do the trick:
Actually, I think that would execute the sound after it loads the map, if you want the sound to load first then the map, I'd try this:
Code: Select all
beep = (registersound "chaze/select" 255)
level_trigger_1 = [listofmaps = [HT_left HT_right]; map (at $listofmaps (rnd (listlen $listofmaps))); sound $beep]
Code: Select all
beep = (registersound "chaze/select" 255)
level_trigger_1 = [sound $beep; listofmaps = [HT_left HT_right]; map (at $listofmaps (rnd (listlen $listofmaps)))]
Julius wrote:Contribute to http://www.opengameart.org NOW!
Save the wiki!
- kddekadenz
- Member
- Posts: 423
- Joined: July 17th, 2011, 11:02 am
- Name: kdd
- Contact:
Re: Sound During Teleport to New Map
I quite do not understand your scriptUCLA.RES. wrote:i actually already have a trigger for this teleport, but I need both triggers to work at the same time. when I did u script kdd, it canced the previous script i had which was:
level_trigger_1 = [
listofmaps = [HT_left HT_right]; map (at $listofmaps (rnd (listlen $listofmaps)))]

Do you want to load a random map with this?
You can make different triggers which teleports you to different maps with my method.
You should take a look at the Sauerbraten documentation. There is a overview of the trigger states.is there a way I can get both of them working at the same time?
I thought trigger levels 2's make the rumble noise, so I triedto make it a level trigger 2, but it didnt work. wierd!
Kelgar is an advanced RPG beeing developed in Sandbox
Re: Sound During Teleport to New Map
to Chochlatepie33, The script you gave (second one since I need the beep at the begging) did some wierd things. First, it didnt load properly, once i put it in the .cfg. I had to manually type the last line (not a complaint at all, just wondering if that has something to do with the script). Then when it took affect, it only teloported me to HT_ left and not HT_right, and it didn't make the beep at all. WIERD I know. lol
to kddekadenz, Ya it is a unique script. It required hirato's genius. It teloports completely randomly, between the two maps, "HT_left" and "HT_right", as listed in the script i posted. So basically, it cant used different triggers for different maps. It has to be that one trigger that makes it random. So i need to alter the existing script so that it maintains its regular function, with the addition of making the beep sound at the begging of the teloport. I really hope this is possible.
THANKS for all the help guys. I really appreciate it!
to kddekadenz, Ya it is a unique script. It required hirato's genius. It teloports completely randomly, between the two maps, "HT_left" and "HT_right", as listed in the script i posted. So basically, it cant used different triggers for different maps. It has to be that one trigger that makes it random. So i need to alter the existing script so that it maintains its regular function, with the addition of making the beep sound at the begging of the teloport. I really hope this is possible.
THANKS for all the help guys. I really appreciate it!
-
- Support Team
- Posts: 2458
- Joined: April 27th, 2010, 5:31 pm
- IRC Username: CP
Re: Sound During Teleport to New Map
hmmm... maybe I messed up the code line somehow...
My only guess is that there wasn't a space between the semicolons. That may cause a problem, since coding usually has to be perfect when following guidelines and syntax.
To break down the code, line 1 registers the sound to be used, part 1 of line 2 plays the sound, part 2 creates the alias/array listofmaps (with values map1 and map2), and part 3 should load the randomly determined map (from that array). I don't know what else may be wrong, other than order, possibly.
My only guess is that there wasn't a space between the semicolons. That may cause a problem, since coding usually has to be perfect when following guidelines and syntax.
To break down the code, line 1 registers the sound to be used, part 1 of line 2 plays the sound, part 2 creates the alias/array listofmaps (with values map1 and map2), and part 3 should load the randomly determined map (from that array). I don't know what else may be wrong, other than order, possibly.
Code: Select all
beep = (registersound "chaze/select" 255)
level_trigger_1 = [sound $beep ; listofmaps = [HT_left HT_right] ; map (at $listofmaps (rnd (listlen $listofmaps)))]
Julius wrote:Contribute to http://www.opengameart.org NOW!
Save the wiki!
Re: Sound During Teleport to New Map
AHH so close! so now it does randomly teloport but makes the noise like 1/10th of the time, really weird. And every time I restart PAS the object does not have the script attached to it anymore so I have to F6 - load save and execute it again each time. That is really weird. Could it be that the beep is only activated at random intervals as the map? I'm so frustrated. What should I do? Could anyone help me out plz.
Re: Sound During Teleport to New Map
Unless I'm missing something, couldn't you just place a sound entity next to each teleporter? You can just gank my code in halloween house and then go in the map and take a look at how I have the entity setup. You can even copy and paste the entities out of the map.
Take care.
-mike

-mike
Sign up for our Newsletter to keep up to date with the Sandbox news!
We also have a facebook page, facebook group, myspace page and a twitter page[/b][/color]!
We also have a facebook page, facebook group, myspace page and a twitter page[/b][/color]!