" method shown below. The method shown below not only is tedious but also does not work for fast scrolling messages like "Phoenix: Wait a secon-" where it has 1 second of message time before the judge slams his gavel.
mob/proc |
ID:156598
Aug 30 2010, 6:13 pm
|
||
Hi, I need to know a way to make a game that looks like ace attorney (with text appearing one letter at a time with beep sounds after each letter) without the tedious "
" method shown below. The method shown below not only is tedious but also does not work for fast scrolling messages like "Phoenix: Wait a secon-" where it has 1 second of message time before the judge slams his gavel.
| ||
#1 Aug 30 2010, 6:21 pm
|
||
somethinglike this would work:
| ||
Masschaos100 wrote:
somethinglike this would work:So basically you are saying to place this to "replace" my example proc, or are you saying that is a proc I should include so when I do " src << "blah blah" " it shows up one letter at a time? | ||
Masschaos100 wrote:
somethinglike this would work:I tried putting that in. It did make the text appear, but it did not make it show up one letter at a time. Plus it made the server slightly slower. What I put in is below. Feel free to correct any errors.
| |||
well first, this was suppose to replace your example :P, and could you tell me the error your getting O.o?
| |
yea new proc for the text thing
and im not sure whats making it slow...maybe its because your constantly using that sound? | ||
Masschaos100 wrote:
yea new proc for the text thing No. It was much faster before I added the stirng of code. | ||
Masschaos100 wrote:
well first, this was suppose to replace your example :P, and could you tell me the error your getting O.o? The error I am getting is: I am expecting it to post one letter at a time without using H3 AKA a tedious
The string of code does not do that. I typed in my message:
| ||||
Masschaos100 wrote:
if you want it to type faster change the increments O-O That's not what I mean. I am saying it is typing too fast. Meaning it all shows in one second. What value do I need to put the increment to, just to make it go slower? I also get a lag spike when I put it in my example and then displays the whole message at once. | |
You would want the increment to be 1 so it does one letter at a time. What you want to do is increase sleep(1), which is 1/10th of a second (assuming you didn't change the world's tick value).
The whole lag & display issue sounds like there was no sleep() in your procedure. Edit: Let me comment that snippet for you, since I am in a nice mood (and I added in a delay argument):
| ||
GhostAnime wrote:
You would want the increment to be 1 so it does one letter at a time. What you want to do is increase sleep(1), which is 1/10th of a second (assuming you didn't change the world's tick value).
Ok I am going to test it. Edit: I tested it and it works fine! Thank you for your help! | ||
#12 Aug 31 2010, 7:28 pm
|
|
Oh.
<font size=2>My.</font> <Font size=3>GOD.</font> Seriously, loops. Just... just loops. | |