YASSE Hitbasic-Skin (script): Difference between revisions

From Elanthipedia
Jump to navigation Jump to search
m (fixed matching bug)
m (updated to 1.1b)
Line 12: Line 12:
==Updates==
==Updates==
Last Updated:
Last Updated:
*'''03/18/2011''': Revision 1.1b, fixed bug with addition of crossbow support and skinning
*'''03/14/2011''': Revision 1.1, shouldn't hang on arrange loop.
*'''03/14/2011''': Revision 1.1, shouldn't hang on arrange loop.
*'''11/20/2010''': Revision 1.0
*'''11/20/2010''': Revision 1.0
Line 108: Line 109:
skin2:
skin2:
pause
pause
if %lefthanditem contains skinning
if %lefthanditem contains knife
begin
begin
pause
pause
Line 119: Line 120:
end
end
pause
pause
if $huntingweapon$ contains crossbow
if $huntingweapon$ eq crossbow
begin
begin
boxmessage Detected $huntingweapon$ as crossbow
pause
pause
put wear $huntingweapon$
put wear $huntingweapon$
Line 131: Line 133:
goto skinit
goto skinit
end
end
pause
put sheath $huntingweapon$
put sheath $huntingweapon$
pause
pause
Line 201: Line 204:


skincomplete:
skincomplete:
if %righthanditem contains skinning
if %righthanditem contains knife
begin
begin
pause
pause

Revision as of 10:54, 18 March 2011

YASSE Hitbasic-Skin (script)
Category combat
Front-end YASSE
Author Hithrael


Description

This is part of the YASSE Combat Package.

Syntax

Updates

Last Updated:

  • 03/18/2011: Revision 1.1b, fixed bug with addition of crossbow support and skinning
  • 03/14/2011: Revision 1.1, shouldn't hang on arrange loop.
  • 11/20/2010: Revision 1.0

Script

set predefined on

#Local settings

skin:
boxmessage Number of arranges: $arrangenumber$
boxmessage $huntingweapon$
pause
if $yetarrange$ eq yes
	begin
	counter set $arrangenumber$
	if %c == 0 
		goto skin2
	pause
	for forarrange = 1 to %c
		begin 
		put arrange
		pausetext 3 roundtime
		end
	goto skin2
	end
if $yetarrange$ eq no
	begin
	boxmessage Calculating optimal number of arranges now, up to the maximum of $skinmax$.
	counter set $arrangenumber$
	pause
	if %c == $skinmax$
		begin
		boxmessage Already at maximum arranges. (Check #1)
		goto arrangesave
		end
	pause

#Add more messaging
	match arrangesave not to damage
	match arrangeup properly arrange
	match arrangedown worthless now
	match arrangeno Cannot be skinned
	put arrange
	matchwait 5
	end

boxmessage Arrange message did not match \nsaving current state and continuing.
goto arrangesave

arrangeup:
if %c == $skinmax$
	begin
		boxmessage At maximum number of arranges, \nbut the script did not catch earlier.
		goto arrangesave
	end
boxmessage Increasing number of arranges.
counter inc
pause

setvariable arrangenumber %c
goto skin

arrangedown:
boxmessage Too difficult to skin/arrange, reducing number of arranges (if possible).
if %c == 0
	begin	
	setglobalvariable arrangenumber [%c]
	setglobalvariable yetarrange [yes]
	goto lootstuff
	end
counter dec
pause
if %c == 0
	goto arrangesave
if %c > 0
	begin
	setglobalvariable arrangenumber [%c]	
	setglobalvariable yetarranged [no]
	goto skin
	end
	
arrangesave:
boxmessage %c is the optimal number of arranges. \nSaving that number.
pause
setglobalvariable arrangenumber [%c]
setglobalvariable yetarrange [yes]
goto skin2

arrangeno:
boxmessage Critter is unable to be skinned. \nFor now skinning will be bypassed.
setglobalvariable skincheck [do not skin]
goto lootstuff

skin2:
pause
if %lefthanditem contains knife
	begin
	pause
	if $huntingweapon$ contains Empty
		goto skinit
	pause
	put sheath right
	pause
	goto skinit
	end
pause
if $huntingweapon$ eq crossbow
	begin
		boxmessage Detected $huntingweapon$ as crossbow
		pause
		put wear $huntingweapon$
		pause
		put wear $shield$
		pause 
		put wield my $knife$
		waitfor $skinningknifemessage$
		pause 
		goto skinit
	end
pause
put sheath $huntingweapon$
pause
put wield my $knife$
waitfor $skinningknifemessage$
pause

skinit:
match skinlower twists and slips
match skinlower destroying the
match skinlower unfortunate failure
match skinlower claw wildly
match skinlower that of mud
match skinlower struggle with
match skinlower worthless now
match skinlower Skin what?
match skinlower sheer incompetence
match skinlower just barely
match skincomplete work hard
match skincomplete nearly flawless
match skincomplete working deftly
match skincomplete working hard
match skincomplete you slice away
match skincomplete blood soaks
match skincomplete fairly well
match skincomplete oozing flesh
match skincomplete impressive skill and grace
put skin
matchwait 5
goto skincomplete

skinlower:
if $skinmax$ == 0
	begin 
		ifexists skinmaxwarn goto skincomplete
		pause
		boxmessage At minimum number of max arranges, so you'll continue to hack away and make a mess.
		setglobalvariable skinmaxwarn [warned]
		goto skincomplete
	end
if $arrangenumber$ == 0
	begin
		boxmessage At minimum number of arranges, so you'll continue to hack away and make a mess.
		goto skincomplete
	end
if $arrangenumber$ == $skinmax$
	begin
		boxmessage Having problems arranging consistently, lowering skinmax by 1 and will recalculate.
		counter set $arrangenumber$
		pause
		counter dec
		pause
		setglobalvariable arrangenumber [%c]
		setglobalvariable yetarranged [no]
		goto skincomplete
	end
if $arrangenumber$ > 0
	begin
		boxmessage Having problems arranging consistently, lowering arrange by 1 and will recalculate.
		counter set $arrangenumber$
		pause
		counter dec
		pause
		setglobalvariable arrangenumber [%c]
		goto skincomplete
	end
pause
boxmessage Something funny happening with skinlower.
goto skincomplete

skincomplete:
if %righthanditem contains knife
	begin
	pause
	put sheath my $knife$
	end
pause