YASSE Hitbasic (script): Difference between revisions
mNo edit summary |
mNo edit summary |
||
Line 9: | Line 9: | ||
==Syntax== |
==Syntax== |
||
Run as .scriptname <skinning override>, where the <skinning override> is left blank if you want to use your global settings for skinning, or as change if you want to either skin or not skin. (e.g. if your global variable is set to "yes" and you run the script as .hit change, it will temporarily change the script to avoid skinning. The next time script is run, if run normally, it will skin) |
|||
At any time (excepting when the script is skinning or looting), you can enter into the command prompt "changing weapons", where the script will pause for ten seconds to allow you to change weapons, and then go to the start prompt (selecting what fighting style) where the script will pause until a new style is selected. This will allow setting like the skinning change and amount of arrangement to retain their localized settings. |
|||
==Updates== |
==Updates== |
||
Last Updated: |
Last Updated: |
||
*'''03/30/2011''': Revision 2 |
|||
:: Improved skinning support |
|||
:: Faster flow |
|||
:: Better support for shields |
|||
:: Changes made for better ranged support in the future |
|||
*'''03/14/2011''': Revision 1.1b, fixed crossbow functionality which caused skinning bug |
*'''03/14/2011''': Revision 1.1b, fixed crossbow functionality which caused skinning bug |
||
*'''03/14/2011''': Revision 1.1, added basic thrown support. Ranged functionality exists, but poorly. |
*'''03/14/2011''': Revision 1.1, added basic thrown support. Ranged functionality exists, but poorly. |
||
Line 19: | Line 27: | ||
<pre> |
<pre> |
||
set predefined on |
|||
#Add more messaging |
#Add more messaging |
||
#Search for the above language to find points in the script were more language is needed. |
#Search for the above language to find points in the script were more language is needed. |
||
#Global settings |
|||
set predefined on |
|||
put glance |
|||
setglobalvariable yetarrange [no] |
|||
setglobalvariable knife [tooth knife] |
|||
setglobalvariable arrangenumber [0] |
|||
setglobalvariable skinningknifemessage [war belt] |
|||
setglobalvariable skinmax [2] |
|||
setglobalvariable skincheck [yes] |
|||
setglobalvariable thrownweapon [mallet] |
|||
setglobalvariable rangedweapon [crossbow] |
|||
setglobalvariable shield [shield] |
|||
setglobalvariable loadwait [10] |
|||
setglobalvariable huntingweapon [%righthanditem] |
|||
pause |
|||
boxmessage $huntingweapon$ |
|||
getword -1 $huntingweapon$ |
|||
boxmessage %w |
|||
setglobalvariable huntingweapon %w |
|||
#Action calls |
#Action calls |
||
Line 52: | Line 40: | ||
action [To whom are you speaking?] goto end |
action [To whom are you speaking?] goto end |
||
action [What are you trying to throw?] goto thrown2 |
action [What are you trying to throw?] goto thrown2 |
||
action [changing weapons] goto weaponchange |
|||
#Action calls for combat/critter death |
#Action calls for combat/critter death |
||
Line 64: | Line 53: | ||
action [rebellious flame dies out] gosub loot |
action [rebellious flame dies out] gosub loot |
||
action [and lies still] gosub loot |
action [and lies still] gosub loot |
||
action [then lies still] gosub loot |
|||
action [then goes limp] gosub loot |
|||
#Local settings |
|||
setvariable bunglearrange no |
|||
if %1 contains change |
|||
gosub overrideskin |
|||
pause |
|||
#Weapons portion |
|||
setup: |
setup: |
||
pause |
pause |
||
boxmessage Enter |
boxmessage Enter fighting style now. \nClasses include: \n Blunt, Edged, lightedged, thrustedged, Pike, Halberd, Quarterstaff, Shortstaff, Thrown, and Ranged |
||
getline |
getline |
||
pause |
pause |
||
boxmessage Fighting style is: %l |
|||
if %l eq ranged |
|||
setglobalvariable rangedhunting yes |
|||
else |
|||
setglobalvariable rangedhunting no |
|||
setvariable huntingweapontemp [%righthanditem] |
|||
goto %l |
|||
getword -1 $huntingweapontemp$ |
|||
boxmessage %w |
|||
setglobalvariable huntingweapon %w |
|||
if %l eq thrown |
|||
TARGETED MAGIC |
|||
setvariable thrownweapon %w |
|||
tm: |
|||
call tm |
|||
put glance |
|||
goto setup |
|||
goto %l |
|||
THROWN WEAPONS |
#THROWN WEAPONS |
||
thrown: |
thrown: |
||
pause |
pause |
||
Line 91: | Line 102: | ||
goto thrown |
goto thrown |
||
RANGED WEAPONS |
#RANGED WEAPONS |
||
ranged: |
ranged: |
||
pause |
pause |
||
Line 106: | Line 117: | ||
goto ranged |
goto ranged |
||
BLUNT WEAPONS |
#BLUNT WEAPONS |
||
blunt: |
blunt: |
||
pause |
pause |
||
Line 130: | Line 141: | ||
EDGED WEAPONS |
#EDGED WEAPONS |
||
lightedged: |
lightedged: |
||
pause |
pause |
||
Line 195: | Line 206: | ||
POLE WEAPONS |
#POLE WEAPONS |
||
halberd: |
halberd: |
||
pause |
pause |
||
Line 239: | Line 249: | ||
STAFF WEAPONS |
#STAFF WEAPONS |
||
quarterstaff: |
quarterstaff: |
||
pause |
pause |
||
Line 291: | Line 301: | ||
skin: |
skin: |
||
if $bunglearrange$ eq yes |
|||
if $skincheck$ contains not skin |
|||
begin |
|||
setglobalvariable arrangenumber 0 |
|||
goto skincontinue |
|||
end |
|||
if $skincheck$ eq no |
|||
goto lootstuff |
goto lootstuff |
||
pause |
|||
if %youalsosee contains dead |
|||
match lootstuff cannot be skinned |
|||
match arrangestop worthless now |
|||
match arrangestop not to damage |
|||
put arrange |
|||
matchwait 04 |
|||
goto skincontinue |
|||
arrangestop: |
|||
pause |
|||
setvariable bunglearrange yes |
|||
boxmessage Skinning is so difficult, arrange attempts are being skipped. |
|||
goto lootstuff |
|||
skincontinue: |
|||
if %youalsosee contains dead |
|||
begin |
begin |
||
call skin |
call skin |
||
Line 300: | Line 330: | ||
lootstuff: |
lootstuff: |
||
if $skincheck$ eq no |
|||
pause |
|||
put sheath my $huntingweapon$ |
|||
call loot |
call loot |
||
pause |
pause |
||
if $rangedhunting$ eq no |
|||
if %righthanditem contains empty |
|||
put wield my $huntingweapon$ |
|||
begin |
|||
else |
|||
if $huntingweapon$ contains empty |
|||
put remove my $huntingweapon$ |
|||
return |
|||
pause |
|||
if $huntingweapon$ eq crossbow |
|||
begin |
|||
put rem $huntingweapon$ |
|||
pause |
|||
put rem $shield$ |
|||
return |
|||
end |
|||
put wield $huntingweapon$ |
|||
pause |
|||
end |
|||
pause |
pause |
||
return |
return |
||
foewait1: |
foewait1: |
||
pause |
|||
if %righthanditem contains empty |
|||
begin |
|||
pause |
|||
if $huntingweapon$ qe bow |
|||
begin |
|||
put rem $huntingweapon$ |
|||
pause |
|||
pausetext 60 [melee range] |
|||
return |
|||
end |
|||
pause |
|||
put wield $huntingweapon$ |
|||
pause |
|||
end |
|||
pause |
pause |
||
pausetext 60 [melee range] |
pausetext 60 [melee range] |
||
Line 346: | Line 351: | ||
pause |
pause |
||
return |
return |
||
weaponchange: |
|||
boxmessage Pausing for 10 seconds to change fighting style. \nThen follow prompt. |
|||
pause 10 |
|||
goto setup |
|||
overrideskin: |
|||
boxmessage Overriding normal skinning process. |
|||
if $skincheck$ eq yes |
|||
setvariable skincheck no |
|||
else |
|||
setvariable skincheck yes |
|||
return |
|||
end: |
|||
exit |
|||
</pre> |
</pre> |
Revision as of 15:59, 30 March 2011
YASSE Hitbasic (script) | |
---|---|
Category | combat |
Front-end | YASSE |
Author | Hithrael |
Description
This is part of the YASSE Combat Package.
Syntax
Run as .scriptname <skinning override>, where the <skinning override> is left blank if you want to use your global settings for skinning, or as change if you want to either skin or not skin. (e.g. if your global variable is set to "yes" and you run the script as .hit change, it will temporarily change the script to avoid skinning. The next time script is run, if run normally, it will skin)
At any time (excepting when the script is skinning or looting), you can enter into the command prompt "changing weapons", where the script will pause for ten seconds to allow you to change weapons, and then go to the start prompt (selecting what fighting style) where the script will pause until a new style is selected. This will allow setting like the skinning change and amount of arrangement to retain their localized settings.
Updates
Last Updated:
- 03/30/2011: Revision 2
- Improved skinning support
- Faster flow
- Better support for shields
- Changes made for better ranged support in the future
- 03/14/2011: Revision 1.1b, fixed crossbow functionality which caused skinning bug
- 03/14/2011: Revision 1.1, added basic thrown support. Ranged functionality exists, but poorly.
- 11/20/2010: Revision 1.0
Script
set predefined on #Add more messaging #Search for the above language to find points in the script were more language is needed. #Action calls action [There is nothing else to face!] gosub foewait2 action [At what are you trying to] gosub foewait1 action [You aren't close enough to attack] gosub foewait2 action [But you are already dodging!] put parry action [You are already in a position to parry.] put dodge action [To whom are you speaking?] goto end action [What are you trying to throw?] goto thrown2 action [changing weapons] goto weaponchange #Action calls for combat/critter death #Add more messaging action [lifeless mound] gosub loot action [collapses to the ground] gosub loot action [then grows still] gosub loot action [grows limp and seems to deflate] gosub loot action [before collapsing] gosub loot action [stops all movement] gosub loot action [body explodes into a gaseous cloud] gosub loot action [rebellious flame dies out] gosub loot action [and lies still] gosub loot action [then lies still] gosub loot action [then goes limp] gosub loot #Local settings setvariable bunglearrange no if %1 contains change gosub overrideskin pause #Weapons portion setup: pause boxmessage Enter fighting style now. \nClasses include: \n Blunt, Edged, lightedged, thrustedged, Pike, Halberd, Quarterstaff, Shortstaff, Thrown, and Ranged getline pause boxmessage Fighting style is: %l if %l eq ranged setglobalvariable rangedhunting yes else setglobalvariable rangedhunting no setvariable huntingweapontemp [%righthanditem] getword -1 $huntingweapontemp$ boxmessage %w setglobalvariable huntingweapon %w if %l eq thrown setvariable thrownweapon %w put glance goto %l #THROWN WEAPONS thrown: pause put throw waitfor roundtime thrown2: put get $thrownweapon$ pause goto thrown #RANGED WEAPONS ranged: pause match ranged2 already loaded put load matchwait $loadwait$ ranged2: pause put aim waitfor You think you have your best shot possible now. put fire pause goto ranged #BLUNT WEAPONS blunt: pause put feint waitfor roundtime pause put bash waitfor roundtime pause put sweep waitfor roundtime pause put draw waitfor roundtime pause put swing waitfor roundtime pause put dodge waitfor roundtime pause goto blunt #EDGED WEAPONS lightedged: pause put feint waitfor roundtime pause put draw waitfor roundtime pause put slice waitfor roundtime pause put chop waitfor roundtime pause put dodge waitfor roundtime pause goto lightedged edged: pause put feint waitfor roundtime pause put draw waitfor roundtime pause put sweep waitfor roundtime pause put slice waitfor roundtime pause put chop waitfor roundtime pause put parry waitfor roundtime pause goto edged thrustedged: pause put feint waitfor roundtime pause put lunge waitfor roundtime pause put thrust waitfor roundtime pause put jab waitfor roundtime pause put slam waitfor roundtime pause put parry waitfor roundtime pause goto thrustedged #POLE WEAPONS halberd: pause put feint waitfor roundtime pause put draw waitfor roundtime pause put slice waitfor roundtime pause put thrust waitfor roundtime pause put sweep waitfor roundtime pause put chop waitfor roundtime pause goto halberd pike: pause put dodge waitfor roundtime pause put jab waitfor roundtime pause put sweep waitfor roundtime pause put thrust waitfor roundtime pause put lunge waitfor roundtime pause goto pike #STAFF WEAPONS quarterstaff: pause put feint waitfor roundtime pause put draw waitfor roundtime pause put swing waitfor roundtime pause put thrust waitfor roundtime pause put sweep waitfor roundtime pause put chop waitfor roundtime pause goto quarterstaff shortstaff: pause put feint waitfor roundtime pause put draw waitfor roundtime pause put slice waitfor roundtime pause put parry waitfor roundtime pause put thrust waitfor roundtime pause put chop waitfor roundtime pause goto shortstaff #Action Call Scripts loot: pause put look nextroom skin: if $bunglearrange$ eq yes begin setglobalvariable arrangenumber 0 goto skincontinue end if $skincheck$ eq no goto lootstuff pause match lootstuff cannot be skinned match arrangestop worthless now match arrangestop not to damage put arrange matchwait 04 goto skincontinue arrangestop: pause setvariable bunglearrange yes boxmessage Skinning is so difficult, arrange attempts are being skipped. goto lootstuff skincontinue: if %youalsosee contains dead begin call skin pause end lootstuff: if $skincheck$ eq no put sheath my $huntingweapon$ call loot pause if $rangedhunting$ eq no put wield my $huntingweapon$ else put remove my $huntingweapon$ pause return foewait1: pause pausetext 60 [melee range] pause return foewait2: waitfor melee range pause return weaponchange: boxmessage Pausing for 10 seconds to change fighting style. \nThen follow prompt. pause 10 goto setup overrideskin: boxmessage Overriding normal skinning process. if $skincheck$ eq yes setvariable skincheck no else setvariable skincheck yes return end: exit