This is my attempt to make my casting of my smiles on my clan easy. This script uses gift shop items to keep track of what day it's on and casts my 5 smiles on the 5 members for that day. This current incarnation of code does currently get the job done but has a few obvious flaws. My main questions are is there a better way to keep track of what day it is and it there a better way to stop the script other then the abort command?
Code:
//Automated Clan Smiles
//written by Enameless
if ( item_amount( $item[potted cactus] ) = 1 )
{
cli_execute
{
cast 1 smile on playername
cast 1 smile on playername
cast 1 smile on playername
cast 1 smile on playername
cast 1 smile on playername
sell potted cactus
buy stuffed can of asparagus
abort End Round 1
}
}
if ( item_amount( $item[stuffed can of asparagus] ) = 1 )
{
cli_execute
{
cast 1 smile on playername
cast 1 smile on playername
cast 1 smile on playername
cast 1 smile on playername
cast 1 smile on playername
sell stuffed can of asparagus
buy mugcake
abort End Round 2
}
}
if ( item_amount( $item[mugcake] ) = 1 )
{
cli_execute
{
cast 1 smile on playername
cast 1 smile on playername
cast 1 smile on playername
cast 1 smile on playername
cast 1 smile on playername
sell mugcake
buy white balloon
abort End Round 3
}
}
if ( item_amount( $item[white balloon] ) = 1 )
{
cli_execute
{
cast 1 smile on playername
cast 1 smile on playername
cast 1 smile on PlayerName
cast 1 smile on PlayerName
cast 1 smile on PlayerName
sell white balloon
buy potted cactus
abort End Round 4
}
}