PDA

View Full Version : RT Question



Soulpieced
06-14-2004, 12:39 PM
Alright, I'm still trying to find the best way for an attack loop to go every 1 second. The thing I'm using now works ok, but sometimes it triggers too fast and sometimes too slow. Any ideas?

.

Start:
put stance o
waitfor You
goto Main

Main:
counter set 1
put attack %1
match Next Roundtime:
match Next You already have
match Wait Please rephrase
match Wait ...wait
match Wait Wait
match Wait Sorry, you may
match Wait You can't reach the
match Done You currently have
match Done What were you referring to?
match Done then goes still.
match Done the life fading from
match Done flapping fruitlessly as it dies.
match Done to the ground, motionless.
match Done in a crumpled heap.
match Done Just as you move to strike
matchwait


Next:
counter set 1
put attack %1
match Next Roundtime:
match Next You already have
match Wait Please rephrase
match Wait ...wait
match Wait Wait
match Wait Sorry, you may
match Wait You can't reach the
match Done You currently have
match Done What were you referring to?
match Done then goes still.
match Done the life fading from
match Done flapping fruitlessly as it dies.
match Done to the ground, motionless.
match Done in a crumpled heap.
match Done Just as you move to strike
matchwait

Wait:
pause
goto Main

Done:
put stance d
exit

[Edited on 6-14-2004 by Soulpieced]

Soulpieced
06-14-2004, 12:40 PM
I was just trying out the counters to see if that would put any noticeable pause in between attacking. Doesn't look like it though. Waits and waitfors are not appropriate, and pause is way too long.

TheEschaton
06-14-2004, 12:43 PM
pause can go with an argument. If you do PAUSE 1, it'll pause only for a second. Try putting that in your wait loop


-TheE-

Soulpieced
06-14-2004, 12:43 PM
The pause 1 is still much slower than looping through the attack sequence taking into account scripting lag.

TheEschaton
06-14-2004, 12:51 PM
You may be able to do partial fractions....what you can do is put 1 second at the start of main, set all the matches which go to WAIT to MAIN, and then, whether or not you are successful or not, it'll loop to the beginning of main, wait a second, and try and attack again. No need for Next.

If you don't want the initial pause on the first attack, try this:

premain:
pause 1

Main:
counter set 1
put attack %1
....etc

And have all the matches go to premain, not main, but the first goto to still go to regular main.

-TheE-

Soulpieced
06-14-2004, 12:54 PM
Like I just said, pause is not an option as it is much slower than constant looping. The problem is sometimes it fires constantly, like it will put attack %1 twice before it should really register. What I ideally want is a script that will go exactly 1 second between attacks, but pausing definitely is more like 2.

Soulpieced
06-14-2004, 12:55 PM
This is what I'm trying to get rid of. Granted it works well sometimes, this happens often.

.

[Script]>attack
You swing a sonic short sword at a greater construct!
AS: +525 vs DS: +223 with AvD: +7 + d100 roll: +22 = +331
... and hit for 36 points of damage!
Bones in right arm crack.

** As you hit, your short sword unleashes a blast of sonic energy! **

... 30 points of damage!
Hard strike to right leg breaking tendons and bone!
It is knocked to the ground!
attack
Roundtime: 4 sec.
attack
Roundtime changed to 1 second.
[Script]>You swing a sonic short sword at a greater construct!
AS: +525 vs DS: +162 with AvD: +7 + d100 roll: +84 = +454
... and hit for 51 points of damage!
Hesitant slash to the greater construct's upper right arm!
Just a scratch.
Roundtime: 4 sec.
Roundtime changed to 1 second.
[Script]>
...wait 1 seconds.
[Script]>

Soulpieced
06-14-2004, 12:56 PM
This is how it looks when working correctly.

.

[Script]>attack
You swing a sonic short sword at a war griffin!
AS: +525 vs DS: +269 with AvD: +24 + d100 roll: +31 = +311
... and hit for 56 points of damage!
Elbow punctured, oh what pain!
Roundtime: 4 sec.
Roundtime changed to 1 second.
[Script]>attack
You swing a sonic short sword at a war griffin!
AS: +525 vs DS: +269 with AvD: +24 + d100 roll: +15 = +295
... and hit for 59 points of damage!
Nailed in lower back!
Roundtime: 4 sec.
Roundtime changed to 1 second.
[Script]>attack
You swing a sonic short sword at a war griffin!
AS: +525 vs DS: +255 with AvD: +24 + d100 roll: +22 = +316
... and hit for 63 points of damage!
Whoosh! Several ribs driven into lungs.
Roundtime: 4 sec.
Roundtime changed to 1 second.
[Script]>attack
You swing a sonic short sword at a war griffin!
AS: +525 vs DS: +255 with AvD: +24 + d100 roll: +85 = +379
... and hit for 66 points of damage!
Blast to hand reduces it to pulp!
Roundtime: 4 sec.
Roundtime changed to 1 second.
[Script]>
A war griffin tries to bite you!
AS: +415 vs DS: +511 with AvD: +24 + d100 roll: +14 = -58
A clean miss.
[Script]>attack
You swing a sonic short sword at a war griffin!
AS: +525 vs DS: +256 with AvD: +24 + d100 roll: +16 = +309
... and hit for 49 points of damage!
Shot pierces a wrist!

** As you hit, your short sword unleashes a blast of sonic energy! **

... 35 points of damage!
Nice blow to abdomen!

** As you hit, your short sword unleashes a blast of sonic energy! **

... 20 points of damage!
Brushing blow to temple.
Roundtime: 4 sec.
Roundtime changed to 1 second.
[Script]>
A greater construct's body crumbles until only a pile of rubble marks its remains.
[Script]>attack
You swing a sonic short sword at a war griffin!
AS: +525 vs DS: +234 with AvD: +24 + d100 roll: +10 = +325
... and hit for 65 points of damage!
Well placed shot pierces knee, that hurt!
The war griffin crashes to the ground, motionless.
Roundtime: 4 sec.
Roundtime changed to 1 second.

Mistomeer
06-14-2004, 01:13 PM
Way I do it in casting, which should work for you is like this:

prep:
put prep 302
match pause Wait
match cast You
matchwait

pause:
pause .5
goto prep

cast:
put cast at %1

I also have a pause of like 1-2 seconds after casting, so that it will try to cast every .5 seconds after the pause, so as to be casting every 3 seconds. It hits alot of, Wait 1 sec, when trying to prep, but that's better than playing it safe and just doing a flat out pause 4. I'd rather have it hit the wait, then turn around and cast immediately again, rather than playing it safe and pausing an extra second after every cast.

Soulpieced
06-14-2004, 01:14 PM
Pause only works in whole seconds. You may think you're getting away with the .5, but it's still coming off too slow for me. I need instantaneous stuff, I actually timed one of my pause 1's at near 3 seconds.

Drew2
06-14-2004, 01:24 PM
Short answer: No.

Long answer: Yes but there is a risk of getting booted for scroll if you get lag.