YASSE Alchemy (script)

From Elanthipedia
Jump to navigation Jump to search
YASSE Alchemy (script)
Category Crafting,Alchemy
Front-end YASSE
Author Ithrios


Description

Creates a remedy using the alchemy skill. You will need to turn your book to the appropriate page and specify what type of catalyst to use (eg Pewter, Niniam, Electrum) but otherwise the script will do everything for you. All of your tools and your book should be stored in the same container and your catalyst and prepared herbs should be stored in the same container. Requires the following global variables to be defined: container-alchemy - the place where you store your prepared herbs and other materials container-tool - the place where you store your tools

Syntax

.alchemy <catalyst name>

Updates

Last Updated:
21 Nov 2013 - Script Posted

Script


setup:

action "prepared herb (pieces per use, known to provide minor external healing over the entire body)" setvariable herb-1 "red flower"
action "prepared herb (pieces per use, known to provide minor internal healing over the entire body)" setvariable herb-1 "crushed flower"

action "prepared herb (pieces per use, known to heal external wounds of the head)" setvariable herb-1 "nemoih"
action "prepared herb (pieces per use, known to heal external wounds of the eyes)" setvariable herb-1 "sufil"
action "prepared herb (pieces per use, known to heal external wounds of the neck)" setvariable herb-1 "georin"
action "prepared herb (pieces per use, known to heal external wounds of the chest)" setvariable herb-1 "plovik"
action "prepared herb (pieces per use, known to heal external wounds of the abdomen)" setvariable herb-1 "nilos"
action "prepared herb (pieces per use, known to heal external wounds of the back)" setvariable herb-1 "hulnik"
action "prepared herb (pieces per use, known to heal external wounds of the limbs)" setvariable herb-1 "jadice"
action "prepared herb (pieces per use, known to heal external wounds of the skin and nerves)" setvariable herb-1 "aloe"

action "prepared herb (pieces per use, known to heal internal wounds of the head)" setvariable herb-1 "eghmok"
action "prepared herb (pieces per use, known to heal internal wounds of the eyes)" setvariable herb-1 "aevaes"
action "prepared herb (pieces per use, known to heal internal wounds of the neck)" setvariable herb-1 "riolur"
action "prepared herb (pieces per use, known to heal internal wounds of the chest)" setvariable herb-1 "ithor"
action "prepared herb (pieces per use, known to heal internal wounds of the abdomen)" setvariable herb-1 "muljin"
action "prepared herb (pieces per use, known to heal internal wounds of the back)" setvariable herb-1 "jun"
action "prepared herb (pieces per use, known to heal internal wounds of the limbs)" setvariable herb-1 "yelith"
action "prepared herb (pieces per use, known to heal internal wounds of the skin and nerves)" setvariable herb-1 "Lujeakave"

action "prepared herb (pieces per use, known to heal external scars of the head, eyes and neck)" setvariable herb-1 "qun"
action "prepared herb (pieces per use, known to heal external scars of the chest, abdomen and back)" setvariable herb-1 "genich"
action "prepared herb (pieces per use, known to heal external scars of the limbs)" setvariable herb-1 "blocil"
action "prepared herb (pieces per use, known to heal external scars of the skin and nerves)" setvariable herb-1 "cebi"
action "prepared herb (pieces per use, known to heal external scars over the entire body)" setvariable herb-1 "dioica"

action "prepared herb (pieces per use, known to heal internal scars of the head, eyes and neck)" setvariable herb-1 "hulij"
action "prepared herb (pieces per use, known to heal internal scars of the chest, abdomen and back)" setvariable herb-1 "ojhenik"
action "prepared herb (pieces per use, known to heal internal scars of the limbs)" setvariable herb-1 "nuloe"
action "prepared herb (pieces per use, known to heal internal scars of the skin and nerves)" setvariable herb-1 "hisan"
action "prepared herb (pieces per use, known to heal internal scars over the entire body)" setvariable herb-1 "belradi"

action "prepared herb (pieces total, known to heal external wounds of the head)" setvariable herb-2 nemoih
action "prepared herb (pieces total, known to heal external wounds of the eyes)" setvariable herb-2 sufil
action "prepared herb (pieces total, known to heal external wounds of the chest)" setvariable herb-2 plovik
action "prepared herb (pieces total, known to heal external wounds of the abdomen)" setvariable herb-2 nilos
action "prepared herb (pieces total, known to heal external wounds of the limbs)" setvariable herb-2 jadice
action "prepared herb (pieces total, known to heal internal wounds of the eyes)" setvariable herb-2 aevaes
action "prepared herb (pieces total, known to heal internal wounds of the neck)" setvariable herb-2 riolur
action "prepared herb (pieces total, known to heal internal wounds of the abdomen)" setvariable herb-2 muljin

action "cream    =-" setvariable item cream
action "draught    =-"  setvariable item draught
action "elixir    =-"  setvariable item elixir
action "ointment    =-" setvariable item ointment
action "salve    =-" setvariable item salve
action "tonic    =-" setvariable item tonic
action "ungent    =-" setvariable item ungent 
action "poultices    =-"  setvariable item poultice
action "potion    =-" setvariable item potion
action "wash    =-" setvariable item wash

setvariable mat-check " $1$ $2$ $3$ $4$ $5$ $6$ $7$ $8$ $9$ $10$"
if $mat-check$ contains " coa"
	begin
	setvariable catalyst "coal nugget"
	end
if $mat-check$ contains " ele"
	begin
	setvariable catalyst "electrum ingot"
	end
if $mat-check$ contains " pew"
	begin
	setvariable catalyst "pewter ingot"
	end
if $mat-check$ contains " seo"
	begin
	setvariable catalyst "seolarn"
	end

put get remed book from my $container-tool$
waitfor you get
put read my book
waitfor (
put study my book
waitfor Roundtime
put put my book in my $container-tool$
waitfor You put
put get $herb-1$ from my  $container-alchemy$
waitfor you get
count:
put count my $herb-1$
waitfor You count out
setvariable have $l$
calculate have pos out
setvariable pos $result$
calculate pos add 4
calculate have right $pos$
calculate have pos piece
setvariable pos $result$
calculate pos add 5
calculate have left $pos$
calculate have remove piece
if $have$ >= 25 goto count-2
put get $herb-1$ from my  $container-alchemy$
waitfor you get
match count You combine 
match count-1 The resulting stack of herbs would be too large and unwieldy
match count-1 That stack of herbs is too large to add more to.
put combine my $herb-1$
matchwait

count-1:
put put my second $herb-1$ in my  $container-alchemy$
waitfor you put
put swap
goto count

count-2:
setvariable main-task crush
if $herb-1$ contains "aevaes" goto mix-0
if $herb-1$ contains "belradi" goto mix-0
if $herb-1$ contains "eghmok" goto mix-0
if $herb-1$ contains "hisan" goto mix-0
if $herb-1$ contains "hulij" goto mix-0
if $herb-1$ contains "ithor" goto mix-0
if $herb-1$ contains "jun" goto mix-0
if $herb-1$ contains "muljin" goto mix-0
if $herb-1$ contains "nuloe" goto mix-0
if $herb-1$ contains "ojhenik" goto mix-0
if $herb-1$ contains "riolur" goto mix-0
if $herb-1$ contains "yelith" goto mix-0
if $herb-1$ contains "Lujeakave" goto mix-0
if $herb-1$ contains "crushed flower" goto mix-0
goto crush-0

crush-0:
setvariable main-task crush
setvariable return crush-0
setvariable main-tool pestle
setvariable tool pestle
setvariable container mortar
put get $container$ from my $container-tool$
waitfor you get
match crush-0b you put
match crush-0a So you count off and place only that many inside.
put put my $herb-1$ in my $container$
matchwait

crush-0a:
put put my $herb-1$ in my $container-alchemy$
waitfor you put

crush-0b:
put get pestle from my $container-tool$
waitfor you get

match get-herb You need another prepared herb to continue 
match water You need another splash of water to continue
match alcohol You need another splash of alcohol to continue
match smell mixture begins to transition colors.
match sieve you see some particulate
match turn you notice clumps of material forming
match catalyst You need another catalyst material
match done Interesting thought really
match crush roundtime
put crush $herb-1$ in my mortar with my pestle
matchwait

crush:
setvariable return crush
setvariable tool pestle
match get-herb You need another prepared herb to continue 
match water You need another splash of water to continue
match alcohol You need another splash of alcohol to continue
match smell mixture begins to transition colors.
match sieve you see some particulate
match turn you notice clumps of material forming
match catalyst You need another catalyst material
match done Interesting thought really
match crush roundtime
put crush $item$ in my mortar with my pestle
matchwait

mix-0:
setvariable main-task mix
setvariable return mix
setvariable main-tool stick
setvariable tool stick
setvariable container bowl
put get $container$ from my $container-tool$
waitfor you get
match mix-0b you put
match mix-0a you count off and place only that many inside.
put put my $herb-1$ in my $container$
matchwait

mix-0a:
put put my $herb-1$ in my $container-alchemy$
waitfor you put

mix-0b:
put get stick from my $container-tool$
waitfor you get

match get-herb You need another prepared herb to continue 
match water You need another splash of water to continue
match alcohol You need another splash of alcohol to continue
match smell mixture begins to transition colors.
match sieve you see some particulate
match turn you notice clumps of material forming
match catalyst You need another catalyst material
match done Try as you might, you just can't mix
match mix roundtime
put mix $container$ with my $tool$
matchwait

mix:
setvariable return mix
setvariable tool stick
match get-herb You need another prepared herb to continue 
match water You need another splash of water to continue
match alcohol You need another splash of alcohol to continue
match smell mixture begins to transition colors.
match sieve you see some particulate
match turn you notice clumps of material forming
match catalyst You need another catalyst material
match done Try as you might, you just can't mix
match mix roundtime
put mix $container$ with my $tool$
matchwait


smell:
setvariable return smell
match get-herb You need another prepared herb to continue 
match water You need another splash of water to continue
match alcohol You need another splash of alcohol to continue
match catalyst You need another catalyst material
match $main-task$ You sniff the
put smell my $container$
matchwait

turn:
setvariable return turn
match get-herb You need another prepared herb to continue 
match water You need another splash of water to continue
match alcohol You need another splash of alcohol to continue
match catalyst You need another catalyst material
match $main-task$ You spin your
put turn my $container$
matchwait

sieve:
put put my $tool$ in my $container-tool$
waitfor you put
match sieve-3 What were you referring to?
match sieve-2 you get
put get my sieve from my $container-tool$
matchwait

sieve-2:
setvariable return sieve-2
setvariable tool sieve
match get-herb You need another prepared herb to continue 
match water You need another splash of water to continue
match alcohol You need another splash of alcohol to continue
match catalyst You need another catalyst material
match sieve-3 You slowly filter 
match sieve-3 You filter
put push $item$ in my $container$ with my sieve
matchwait

sieve-3:
put put my sieve in my $container-tool$
waitfor you put
setvariable tool $main-tool$
setvariable return $main-task$
goto get-tool

get-herb:
put put my $tool$ in my $container-tool$
waitfor you put
put get $herb-2$ from my $container-alchemy$
waitfor you get
put put my $herb-2$ in my $container$
waitfor You vigorously rub the
match get-tool you put
match get-tool What were you referring to?
put put my $herb-2$ in my $container-alchemy$
matchwait

water:
put put my $tool$ in my $container-tool$
waitfor you put
match water-3 What were you referring to?
match water-1 you get
put get my water from my $container-alchemy$
matchwait

water-1:
match water-2 You toss the water 
put pour water in my $container$
matchwait

water-2:
match get-tool you put
match get-tool What were you referring to?
put put my water in my $container-alchemy$
matchwait

water-3:
echo **** please obtain some more water and pour it into the $container$ ****
match water-2 You toss the water
matchwait

alcohol:
put put my $tool$ in my $container-tool$
waitfor you put
match alcohol-3 What were you referring to?
match alcohol-1 you get
put get my alcohol from my $container-alchemy$
matchwait

alcohol-1:
match alcohol-2 You toss the alcohol 
put pour alcohol in my $container$
matchwait

alcohol-2:
match get-tool you put
match get-tool What were you referring to?
put put my alcohol in my $container-alchemy$
matchwait

alcohol-3:
echo **** please obtain some more alcohol and pour it into the $container$ ****
match alcohol-2 You toss the alcohol 
matchwait

catalyst:
put put my $tool$ in my $container-tool$
waitfor you put
match get-tool What were you referring to?
match catalyst-1 you get
put get my $catalyst$ from my $container-alchemy$
matchwait

catalyst-1:
match catalyst-2 You vigorously rub the
put put $catalyst$ in my $container$
matchwait

catalyst-2:
match get-tool you put
match get-tool What were you referring to?
put put my $catalyst$ in my $container-alchemy$
matchwait

get-tool:
put get my $tool$ from my $container-tool$
waitfor you get
goto $return$

done:
put put my $tool$ in my $container-tool$
waitfor you put
put get my $item$ from my $container$
waitfor you get
put put my $container$ in my $container-tool$
put appraise $item$
waitfor roundtime
put analyze $item$