[EasyUo] Cast All Spells From Menu (with Claim)

If you make a Client-side script you can publish it here for other players to use
Locked
User avatar
Natilla
Expert Scribe
Posts: 31
Joined: Tue Feb 03, 2009 1:31 pm

[EasyUo] Cast All Spells From Menu (with Claim)

Post by Natilla »

Is your screen cluttered with lots of icons of spells?
Are you running out of keys to use as macros??
Then run this easy menu-driven system to cast all spells!
Casts Mage, Necro, Druid, Cleric, Chivalry and even does some skills.
I have even added BlaZe Bunny's ClaimR script (with some minor modifications). (I hope it's ok with you blaze :scared: )

Does EVERYTHING but take out the trash :P

See Screenshot.
Pic of Menu
Pic of Menu
ScreenShot317.jpg (103.17 KiB) Viewed 12485 times
Even very easy to customize for your own use.

If you have questions, or suggestions, please let me know.
ENJOY!

Code: Select all

;*************************************************
; Cast All Spells by Natilla v1.0
; v1.0 04/21/09
; Base Script By: Talon Rhein
; Claim and Claimall by: BlaZe Bunny (formerly BlaZe Budd)
; Creates a menu where you can select spells to cast and skills to use.
; Magery, Necromancy, Chivalry, Cleric, Druid and even Skills (hiding, detect hidden, etc)
; Very Simple and easy to use.
; Can be easily adjusted to suit the most common spells you use.
;  This script will not cast DRUID spells if you do not have a druid spellbook!
;  This script will not cast a spell if you do not have the required skill level.
;  THIS IS NOT A SKILLS TRAINER!
; Enjoy!
;**************************************************
;**************************************************
; CHANGE THESE OPTIONS IF YOU WANT
; User definied Variables:
; if using the claim or claimall buttons:
set %pathfind #true ;#true for pathfinding, set to #false to not pathfind (used in claim and claimall)
set %userrange 6 ;enter number 1-9 for how many tiles away you want claim script to look
; End User Defined Variables
;**************************************************

menu Clear
	menu Clear
	menu hideeuo
 	menu Window Title Cast All Spells by Natilla v1.0
	menu Window Color Black
	menu Window Size 906 72
	menu Font Transparent #true
	menu Font Align Right
	menu Font Name MS Sans Serif
	menu Font Size 8
	menu Font Style
	menu Font Color WindowText
	menu Font BGColor Yellow
	menu Button q1 4 4 89 29 Magery Buffs  ;can change the name of "Magery Buffs" to whatever you like
	menu Button q5 4 40 89 29 Necromancy   ;can change the name of "Necromancy" to whatever you like
	menu Button q2 100 4 89 29 Magery Offense  ;can change the name of "Magery Offense" to whatever you like
	menu Button q6 100 40 89 29 Druid ;can change the name of "Druid" to whatever you like
	menu Button q3 196 4 89 29 Magery Misc   ;can change the name of "Magery Misc" to whatever you like
	menu Button q7 196 40 89 29 Skills  ;can change the name of "Skills" to whatever you like
	menu Button q4 292 4 89 29 Chivalry ;can change the name of "Chivalry" to whatever you like
	menu Button q8 292 40 89 29 Cleric  ;can change the name of "Cleric" to whatever you like
 	menu Font BGColor Red
	menu Button qTargetMonster 812 4 89 29 Last Target
	menu Font BGColor Blue
	menu Button qTargetSelf 812 40 89 29 Target Self
	menu Font BGColor Green
	menu Show 47 608
  Set #menubutton n/a

;======================================================
;----find spellbook and save variable-------
;======================================================

   event Macro 8 7
   wait 20
   finditem MPF C_ , #BACKPACKID
   if #findkind = -1
   {
      display ok Could not find your spellbook, please target it now
      set #targcurs 1
      while #targcurs = 1
      wait 0
      set %spellbook #ltargetid
   }
   if #findkind <> -1
      set %spellbook #findID
   goto mainloop

;========================================================
;---------------MAIN LOOP------------------------
;========================================================


     mainLoop:
if #menubutton <> n/a
  {
     if q in #menubutton
     {
        gosub #menubutton  ;opens sub menu
     }

     else
     {
        gosub castSpell #menubutton
     }
     set #menubutton n/a
  }
  wait 5
  goto mainLoop
  
 ; *******************************************************************
 ;********************************************************************
 ; Here is where you can change what spells are displayed and used.
 ; To change them, follow this example:
 ; Let;s change Create Food to Earthquake.
 ; First, replace the text "Create Food" to "Earthquake" (without the quotes).
 ; Then, after the word "button" put the text that would come after [cs
 ; so for this example, after the word "button" replace "createfood" with "earthquake" (without the quotes)
 ; That's all there is to do to change the spells.  Very easy, huh? =D
 ; DO NOT CHANGE ANY OF THE NUMBERS.
 ; *******************************************************************
 ;********************************************************************
 sub q1
     menu Button createfood 400 4 89 29 Create Food
     menu Button clumsy 400 40 89 29 Clumsy
     menu Button curse 496 4 89 29 Curse
     menu Button weaken 496 40 89 29 Weaken
     menu Button strength 592 4 89 29 Strength
     menu Button bless 592 40 89 29 Bless
     menu Button reactivearmor 688 4 89 29 Reactive Armor
     menu Button protection 688 40 89 29 Protection
     return

     sub q2
     menu Button fireball 400 4 89 29 Fireball
     menu Button firefield 400 40 89 29 Fire Field
     menu Button lightning 496 4 89 29 Lightning
     menu Button energybolt 496 40 89 29 Enegy Bolt
     menu Button energyfield 592 4 89 29 Energy Field
     menu Button harm 592 40 89 29 Harm
     menu Button poisonfield 688 4 89 29 Poison Field
     menu Button paralyzefield 688 40 89 29 Paralyze Field
     return

     sub q3
     menu Button recall 400 4 89 29 Recall
     menu Button gatetravel 400 40 89 29 Gate
     menu Button greaterheal 496 4 89 29 Greater Heal
     menu Button archcure 496 40 89 29 Arch Cure
     menu Button telekinesis 592 4 89 29  Telekinesis
     menu Button teleport 592 40 89 29 Teleport
     menu Button earthelemental 688 4 89 29  Earth Elemental
     menu Button energyvortex 688 40 89 29 Energy Vortex
     return

     sub q4
     menu Button consecrateweapon 400 4 89 29  Consecrate Weap
     menu Button divinefury 400 40 89 29 Divine Fury
     menu Button enemyofone 496 4 89 29  Enemy of One
     menu Button 1 496 40 89 29 Nothing
     menu Button qClaimS 592 4 89 29 Claim (Single)
     menu Button qClaim_loop 592 40 89 29 Claim (Loop)
     menu Button qClaimallS 688 4 89 29 Claimall (Single)
     menu Button qClaimall_loop 688 40 89 29 Claimall (Loop)
     return

     sub q5
     menu Button animatedead 400 4 89 29  Animate Dead
     menu Button lichform 400 40 89 29 Lich Form
     menu Button wraithform 496 4 89 29  Wraith Form
     menu Button horrificbeast 496 40 89 29 Horrific Beast
     menu Button vampiricembrace 592 4 89 29  Vampiric Embrace
     menu Button wither 592 40 89 29 Wither
     menu Button strangle 688 4 89 29  Strangle
     menu Button summonfamiliar 688 40 89 29 Summon Familiar
     return

     sub q6
     menu Button enchantedgrove 400 4 89 29  Enchanted Grove
     menu Button volcaniceruption 400 40 89 29 Volcanic Eruption
     menu Button stonecircle 496 4 89 29  Stone Circle
     menu Button lurestone 496 40 89 29 Lure Stone
     menu Button restorativesoil 592 4 89 29  Restorative Soil
     menu Button swarmofinsects 592 40 89 29 Swarm of Insects
     menu Button shieldofearth 688 4 89 29  Shield of Earth
     menu Button graspingroots 688 40 89 29 Grasping Roots
     return

     sub q7
     menu Button qHiding 400 4 89 29  Hiding
     menu Button qTracking  400 40 89 29 Tracking
     menu Button qPeace  496 4 89 29  Peace
     menu Button qDisco 496 40 89 29 Disco
     menu Button qProvoke 592 4 89 29  Provoke
     menu Button qDetect 592 40 89 29 Detect Hidden
     menu Button qLore 688 4 89 29  Animal Lore
     menu Button qMed 688 40 89 29 Meditate
     return

     sub q8
     menu Button touchoflife 400 4 89 29  Touch of Life
     menu Button purge 400 40 89 29 Purge
     menu Button restoration 496 4 89 29  Restoration
     menu Button angelicfaith 496 40 89 29 Angelic Faith
     menu Button dampenspirit 592 4 89 29 Dampen Spirit
     menu Button sacredboon 592 40 89 29 Sacred Boon
     menu Button smite 688 4 89 29 Smite
     menu Button trialbyfire 688 40 89 29 Trial By Fire
     return
     
      sub castSpell
      msg $
      msg [cs %1 $
      set #menubutton n/a
      return

sub qHiding
     _Setup_ReHide
      EVENT macro 13 21
      _Setup_ScanJournal:
      SCANJOURNAL 1
      IF hidden_yourself_well in #JOURNAL
         GOTO _Setup_DoneHiding
      WAIT 10s
      GOTO _Setup_ReHide
      _Setup_DoneHiding:
      return
      
sub qTargetSelf
      event Macro 23 0
      return
      
sub qtracking
    event macro 13 38
    return
    
sub qpeace
    event macro 13 9
    return
    
sub qdisco
    event macro 13 15
    return
    
sub qprovoke
    event macro 13 22
    return
    
sub qdetect
    event macro 13 14
    return
    
sub qlore
    event macro 13 2
    return

sub qmed
   event macro 13 46
   return
   
sub qTargetMonster
     event macro 22 0
     return
     
sub qClaimS
   msg [claim $
   return
   
sub qClaimAllS
   msg [claimall $
   return
;***********************
sub qClaim_loop

set #menubutton N/A
menu delete qclaim_loop
menu Button qStopClaiming 592 40 89 29 Stop Claiming
set %claimall #false
    gosub findCorpse
    return
;*************************
sub qClaimAll_loop

set #menubutton N/A
menu delete qclaimall_loop
menu Button qStopClaimAll 688 40 89 29 Stop Claiming All

set %claimall #true
    gosub findCorpse
    return
    
    
;;;;; ;;;;; ;;;;; ;;;;; ;;;;;

sub findCorpse
set %claim Herewego
for %range 1 %userrange
  {
  findItem YFM G_ , %range
  if #findKind > 0
    gosub claim
  }
target
key esc
set %claim done
if %claimall = #false
{
gosub qStopClaiming
}
if %claimall = #true
{
gosub qStopClaimall
}
return


;;;;;;; ;;;;;;; ;;;;;;; ;;;;;;; ;;;;;;; ;;;;;;;
sub claim
set #lTargetID #findID
set #lTargetKind 1
gosub sayIt
if done notIn %claim
  goto again

;set %claim HereWeGo
again:
target 2s
event macro 22
wait %lagTimer
gosub journalCheck
set %range 1
gosub Checkstop
return

;;;;;;; ;;;;;;; ;;;;;;; ;;;;;;; ;;;;;;; ;;;;;;;
sub sayIt

if %claimAll = #false
  event macro 1 0 [claim
else
  event macro 1 0 [claimall

return

;;;;; ;;;;; ;;;;; ;;;;; ;;;;;

sub journalCheck
for %scan 1 3
  {
  scanJournal %scan
  if isn't_a_corpse! in #journal || can't_get_there in #journal || earn_the_rights in #journal
    {
    set %claim done
    ignoreItem #findID
    }
  if cannot_be_seen in #journal
    {
    if %pathfind = #true
      {
      event pathfind #findX #findY
      gosub sayIt
      }
    else
      {
      set %claim done
      ignoreitem #findID
      return
      }
    set %scan 3
    }
  }

return


;*******************************
sub qStopClaiming
set #menubutton N/A
menu delete qStopClaiming
menu Button qclaim_loop 592 40 89 29 Claim (Loop)
key esc
goto mainloop



sub qStopClaimAll
set #menubutton N/A
menu delete qStopClaimAll
menu Button qclaimall_loop 688 40 89 29 Claimall (Loop)
key esc
goto mainloop


sub Checkstop
if qstopclaiming in #menubutton
{
gosub qStopClaiming
}
if qStopClaimAll in #menubutton
{
gosub qStopClaimAll
}
else
return
Catnip
Passer by
Posts: 3
Joined: Wed Apr 15, 2009 7:47 am

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by Catnip »

I was going to actually write something like this for myself but have not decided to sit down and do the refresher on easyuo (it has been several years). So thank you, I am going to run it through some laps and maybe throw in my own personal tweaks.

Great looking so far thank you!
Nip
diGin
Apprentice Scribe
Posts: 10
Joined: Wed Mar 11, 2009 11:00 pm

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by diGin »

Oh look, there's actually a black background under all those icons :D Thank you very much for the script!
User avatar
Natilla
Expert Scribe
Posts: 31
Joined: Tue Feb 03, 2009 1:31 pm

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by Natilla »

Great! Let me know how you like (or don't like) it.
It's pretty easy to tweak for your own use.
Happy Hunting.
-Nati
User avatar
Natilla
Expert Scribe
Posts: 31
Joined: Tue Feb 03, 2009 1:31 pm

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by Natilla »

diGin wrote:Oh look, there's actually a black background under all those icons :D Thank you very much for the script!
Haha! There was no black background anywhere with all my scattered icons about ><
Now it's so clean and orderly!! (Well for me anyways) :P
User avatar
Natilla
Expert Scribe
Posts: 31
Joined: Tue Feb 03, 2009 1:31 pm

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by Natilla »

OK who's screen is cleaner than this??
I couldn't get rid of a few icons >.<
ScreenShot319a.jpg
ScreenShot319a.jpg (61.32 KiB) Viewed 12491 times
Post your before and after pics :D
diGin
Apprentice Scribe
Posts: 10
Joined: Wed Mar 11, 2009 11:00 pm

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by diGin »

Beat that :nod:
uogame.jpg
uogame.jpg (255.59 KiB) Viewed 12390 times
User avatar
Licos
Elder Scribe
Posts: 124
Joined: Wed Jun 18, 2008 9:55 am

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by Licos »

Is there any way to make a button interface you can customize to your own specific skill/spell layout? BC There are few other things I hate than a heat of the moment accidental right click on a skill button you want to use....

It would be cool if it was "always on top" and such... =P.

-Licos
"Lead me not to temptation, I can find it myself."
User avatar
Natilla
Expert Scribe
Posts: 31
Joined: Tue Feb 03, 2009 1:31 pm

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by Natilla »

Licos wrote:Is there any way to make a button interface you can customize to your own specific skill/spell layout?
It would be cool if it was "always on top" and such... =P.
That's a good idea to make a button interface so users could customize easier than going into the script. However, it would probably triple the size of the code now to make that :S

I've put some instructions in the code on how to customize. Just open it up in easyuo and have a look. If it doesn't make sense, I can try to help you customize it.

Does your menu not stay on top? Mine seems to stay on top. Can any other users comment on if their menu stays on top or not?

Thanks for the feedback!
-Nati
diGin
Apprentice Scribe
Posts: 10
Joined: Wed Mar 11, 2009 11:00 pm

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by diGin »

Mine stays on top [like it's glued there] :dance
User avatar
Sorgon
Legendary Scribe
Posts: 272
Joined: Fri Oct 10, 2008 8:58 am
Location: Augusta,ME U.S.A.

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by Sorgon »

Sometime when I am home If that ever happens again I will take a screenie of my screen. or maybe my backpacks. My screen is very organized.....my packs are ....well.....always a disaster :oops:
If it is worth doing at all, it is worth doing well.
User avatar
Nomadix
Master Scribe
Posts: 55
Joined: Fri Jul 31, 2009 10:13 am
Location: 127.0.0.1
Contact:

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by Nomadix »

That is excellent stuff. Checking out the script now and will post feedback.
Forever Evolving, Never Changing.
Gusto Forgeman

Don't you know that the devil, he's in me
And god, she is too
My Ying hates my Yang
But whatcha gonna do?
I choose a rocky path but that's how I like it,
Life's a bowl of punch,
Go ahead and spike it!
Hanarg
Adept Scribe
Posts: 42
Joined: Sun Jan 10, 2010 5:50 pm

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by Hanarg »

I would have love to seen one more row with Ninjitsu and Bushido and two "Custom" Buttons for your personal set up of buttons you use the most and that would have allowed more of the not used as much spells to be added to the script as well.
Hanarg
Adept Scribe
Posts: 42
Joined: Sun Jan 10, 2010 5:50 pm

Re: [EasyUo] Cast All Spells From Menu (with Claim)

Post by Hanarg »

Ok Im updated a personal version of this to add Bushido and Ninjitsu even though all the spells arent currently working with bushido and ninjitsu using the [cs version which this script uses and two "custom" buttons so you can keep the others the way they are and have 2 of them set up with just what you want on them.

Also whats the proper form for updating it so Im not taking all the credit .....
Locked