I am trying to make the Characters you chose have there music theme activate when you step on the turf, but it only plays 1 theme from another chaarter. How can i make this activate lets say, Rob Van Dams theme when i choose him and step on the trigger?--->
if ("Edge")
character = new /mob/superstar/Edge()
turf/wwfmusicthemes
density = 0
Entered()
if ("Edge")
world << sound('edgetheme.mid')
if ("Vince McMahon")
world << sound('mcmahon.mid')
if ("Rob Van Dam")
world << sound('rvd.mid')
if ("Tajiri")
world << sound('smack.mid')
ID:149217
Jun 16 2002, 10:09 am
|
|
Jun 16 2002, 10:11 am
|
|
You're not telling it umm anything, here's an example on how to make this work:
|
if(usr.character == "Edge")
Right now it's checking... "Is the text string "Edge" true? Well, it's not null or 0, so it is. Playing .mid file" "Is the text string "Vince McMahon" true? Well, it's not null or 0, so it is. Playing .mid file" etc. |
In response to Nadrew
|
|
Not that, I have the login coded and everything is sweet, but, i set the turf on the floor, when you choose Rob Van Dam, and you start the game, walk to the turf called "wwfmusicthemes", and it will play RVD's theme song, but if someone logs in and chooses Gangrel, he steps on the turf while my theme is playing, it will switch to his...ect.
turf/wwfmusicthemes density = 0 Entered() if("Edge") world << sound('edgetheme.mid') if ("Vince McMahon") world << sound('mcmahon.mid') if ("Rob Van Dam") world << sound('rvd.mid') if ("Tajiri") world << sound('smack.mid') |
In response to Branks
|
|
So now you're saying it works? I'm confused by you!
|
In response to Garthor
|
|
i never said it works, i said i had the login made, because Nadrew said something about that. The string you gave me doesnt work at all
|
In response to Branks
|
|
ive tried over and over for the past hour, and this is pissing me off, there no way to do this..I ask one of my friends on MSn to help, and all he says is "nah, im too tired", and bhe has this coded in already for his game -_-
|
In response to Branks
|
|
I didn't understand what you're asking for really. What is the problem exactly?
|
In response to Garthor
|
|
Ok the problem is, When I login and choose a mob like mob/superstar/RVD
and i begin playing, i want his midi to play when I step on the trigger turf which is turf/wwfthemesongs. Then it will play his theme. When I choose somebody different like Rhino, i want his theme to play, only when i step on the trigger turf...you see what im saying? |
In response to Branks
|
|
So it plays the first and not the second? Or does it not play the correct music? Or does it not play at all?
|
In response to Garthor
|
|
It doesnt play at all, but my first post with the code plays only 1 song
|
In response to Branks
|
|
when you choose a character, does it change your name to that? Because if it does, you can use src.name = "WHATEVER" instead of what you have.
|
Branks wrote:
I am trying to make the Characters you chose have there music theme activate when you step on the turf, but it only plays 1 theme from another chaarter. How can i make this activate lets say, Rob Van Dams theme when i choose him and step on the trigger?---> I have a simple explanation for why your code is both playing the wrong song, and playing a new song when someone else logs in and steps on it. It's completely messed up.
|
In response to Garthor
|
|
You have been trying to recognize characters when they step on the turf; y not have a var/thememusic for each character and depending on which they pick at start it sets that to the correct theme music for them; then when they step on the turf just play usr.thememusic. This way u could also change a players theme music later without changing their character name or whatever.
|
In response to LostRealm
|
|
LostRealm wrote:
You have been trying to recognize characters when they step on the turf; y not have a var/thememusic for each character and depending on which they pick at start it sets that to the correct theme music for them; then when they step on the turf just play usr.thememusic. This way u could also change a players theme music later without changing their character name or whatever. No, no, no. Never EVER use usr inside of Entered(). Lummox JR |
In response to Lummox JR
|
|
Of course i meant:
Entered(mob/M) M << sound(M.thememusic) I just forgot that we were dealing with the entered proc but still using it like a var for each character would be better since then thememusic could be changed at anytime |
In response to LostRealm
|
|
LostRealm wrote:
Of course i meant: On this I agree. A different approach to the proc would be better than a switch(). (I just feel a need to reactively cut down any attempt to use usr in an Entered() proc, since doing so may save about 5 "I can't figure this out" posts.) Lummox JR |