proc
Say(ref, text, increment, delay=1)
for(var/i=1, i<=length(text), i+=increment)
ref<<copytext(text, i, i+increment)+"\..."
ref << sound('Talk Boy.wav')
sleep(delay)
ref<<""
var/Talking
mob
verb
Say(txt as text)
set hidden = 1
if(src.muted)
src << "<font color=blue>You have been muted!"
return
var/text
text = txt
if(Talking == 1)
alert("Wait until the previous message finishes!")
return
world << {"<font face="Comic Sans MS"><font color=blue>[src.name] says:<font color=green><b>:"}
Talking = 1
Say(world,"[text]",1)
Talking = 0
return
When I use this verb, two things happen:
1. It does not display the message, only the person who is sending it.
2. It tells me to wait until the message finishes, yet it never started.
Why is it doing this?
I tried the same code in Legend Of Zelda RPG and it works perfectly, yet in Naruto Smash Bros. it doesn't work.
I tested this snippet, which is essentially the same thing.
...and got the following errors...
runtime error: Maximum recursion level reached (perhaps there is an infinite loop)
To avoid this safety check, set world.loop_checks=0.
verb name: say (/client/verb/say)
usr: Spunky_Girl (/mob)
src: Spunky_Girl (/client)
call stack:
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
...
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say(, , 1)
Spunky_Girl (/client): say("lol")