Graal Forums

Graal Forums (https://forums.graalonline.com/forums/index.php)
-   NPC Scripting (https://forums.graalonline.com/forums/forumdisplay.php?f=8)
-   -   onKeyPressed..press again? (https://forums.graalonline.com/forums/showthread.php?t=81957)

Understood 09-22-2008 03:09 AM

onKeyPressed..press again?
 
Hi, I'm creating an event called "Name that song" which has one very obvious flaw..."F3"
I was hoping that stopping the song whenever a person presses F3 would work, but the song that was playing still shows. I also tried changing the song name, but still no luck. Is there a way to basically tell the client to press a button again? So I could just close the options menu as soon as it opens, or does anyone have any other solutions?
Thanks.
PHP Code:

//#CLIENTSIDE
function onKeyPressed) {
  if ( 
== 114 ) {
    
stopmidi();
  }



Frankie 09-22-2008 03:42 AM

how could changing the song name not help?
if the file name is like, sweetchildofmine.mp3, and you rename it to eventsong1.mp3, it's impossible for it to show the other name. make sure you reupload it to whatever hosting site you're using.

cbk1994 09-22-2008 03:48 AM

I would guess he wants to make it so events team members don't have to worry about renaming the files.

I wonder if it would be possible to show a GANI with a param which is the music, then in that gani have a sound for PARAM1. I don't think that's possible with URLs, unfortunately.

Frankie 09-22-2008 03:59 AM

it's not that much of a hassle.

Understood 09-22-2008 04:06 AM

The problem is that when you press F3, the options menu is called before changing the song url...so the old url is still there. Which is why I have a problem =[

cbk1994 09-22-2008 04:53 AM

Quote:

Originally Posted by Frankie (Post 1425437)
it's not that much of a hassle.

But, if an ET wants to host like 5 songs, it'll take them probably 10 minutes to get them downloaded, renamed, and uploaded.

Frankie 09-22-2008 12:45 PM

Quote:

Originally Posted by Understood (Post 1425440)
The problem is that when you press F3, the options menu is called before changing the song url...so the old url is still there. Which is why I have a problem =[

I don't see how you're having a problem. there is no old and new URL. there should just be one.

xXziroXx 09-22-2008 02:20 PM

Just make the script compare what song the player is playing compared to a serverr. variable of the current event song?

Understood 09-22-2008 05:01 PM

The problem is that whenever they press F3, they see the answer. I could easily make it disqualify people who press F3, but that won't stop people from telling their friends the song name.

And @Frankie, I tested it...If I have it change the songname when they press F3, it is still being changed AFTER the options menu is brought up, so the options menu is showing the song that was playing with F3 was pressed, not the new one that it was changed to.

I guess "Name That Song" is scratched =[

xXziroXx 09-22-2008 05:10 PM

Or, you could name your mp3's to something not related to the actual song name.

Understood 09-22-2008 05:14 PM

Quote:

Originally Posted by xXziroXx (Post 1425495)
Or, you could name your mp3's to something not related to the actual song name.

Is there a way to do that if you're using URLs? This event is for Events Team members who will most-likely be using playlist.com and copying song links.

xXziroXx 09-22-2008 05:46 PM

Quote:

Originally Posted by Understood (Post 1425496)
Is there a way to do that if you're using URLs? This event is for Events Team members who will most-likely be using playlist.com and copying song links.

No, not really. You'd have to host the files on your own.

LoneAngelIbesu 09-23-2008 01:32 AM

I was thinking something along the lines of using the $pref::audio variables, but apparently there isn't one to see what is currently entered in the MP3 player. I would simply go with the idea of disqualifying players when they press F3. You could place them in a "silent" level that disables PMs, but I don't think a little "Name That Song" contest is that important.


All times are GMT +2. The time now is 08:32 PM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2026, vBulletin Solutions Inc.
Copyright (C) 1998-2019 Toonslab All Rights Reserved.