Official ScriptUO EasyUO Scripts > Scripting Tutorials

EasyUO Documentation Updates

(1/2) > >>

Gaderian:
Here are changes to Easyuo that are not readily documented as of Easyuo 1.6.334 January 23, 2020.
Obsolete Commands
 event sleep
 menu image pixline - was rarely used, but can be accomplished with a subroutine
 menu hideeuo

Modified Commands
 event macro

Category/SkillParm1Parm2Parm3CastNotes/Power WordsGump Control820Open Mysticism Book821Open Racial Abilities Book823Open Global Chat918Close Spellweaving Book920Close Mysticism Book921Close Racial Abilities Book923Close Global Chat1018Minimize Spellweaving Book1020Minimize Mysticism Book1021Minimize Racial Abilities Book1023Minimize Global Chat1118Maximize Spellweaving Book1120Maximize Mysticism Book1121Maximize Racial Abilities Book1123Maximize Global ChatDress and Arm macros610 to ??Save DressParm2 is a number to reference a saved dress (official doc shows 0-4, but I have used numbers from 0 up to 100)620 to ??UndressParm2 value to reference a saved dress630 to ??DressParm2 value to reference a saved dress640 to ??Save Armed ItemsParm2 value to reference a saved armed weapons/shields/books650 to ??DisarmParm2 value to reference a saved armed configuration660 to ??ArmParm2 value to reference a saved armed configurationUse Object67parm1Parm1 is a value from 1 to 14671Use Healing Potionconfirmed672Use Cure Potionconfirmed:cure, lesser cure and greater cure in backpack - greater cure consumed673Use Refresh PotionNeeds Confirmation674Use Strength PotionNeeds Confirmation675Use Agility PotionNeeds Confirmation676Use Explosion PotionNeeds Confirmation677Use Conflagration PotionNeeds Confirmation678Use Enchanted AppleNeeds Confirmation679Use Petals of Trinsicconfirmed6710Use Orange Petalsconfirmed6711Use Trapped BoxNeeds Confirmation6712Use Smoke BombNeeds Confirmation6713Use Healing Stoneconfirmed6714Use Spell TriggerconfirmedMasteriesCredit to Endless Night for these mastery definitions and showing how to find moreProvocation15701InspireUus_Por15702InvigorateAn_ZuPeacemaking15703ResilienceKal_Mani_Tym15704PerseveranceUus_Jux_SanctDiscordance15705TribulationIn_Jux_Hur_Rel15706Despair Kal_Des_Mani_TymMagery15707Death RayIn_Grav_Corp15708Ethereal BurstUus_Ort_GravMysticism15709Nether BlastIn_Vas_Xen_Por15710Mystic WeaponVas_Ylem_WisNecromancy15711Command UndeadIn_Corp_Xen_Por15712ConduitUus_Corp_GravSpellweaving15713Mana ShieldFaerkulggen15714Summon ReaperLartarisstreePassive:Magery, Mysticism, Necromancy, Spellweaving15715Enchanted Summoning- passiveBushido15716Anticipate Hit- passive15717WarcryPassive:Bushido, Chivalry, Ninjitsu15718Intuition- passiveChivalry15719Rejuvenate15720Holy FistNinjitsu15721Shadow15722White Tiger FormArchery15723Flaming Shot15724Playing the OddsFencing15725Thrust15726PierceMace Fighting15727Stagger15728ToughnessSwordsmanship15729Onslaught15730Focused EyeThrowing15731Elemental Fury15732Called ShotPassive:Archery, Fencing, Mace Fighting, Swordsmanship, Throwing15733Warrior's Gifts- passiveParrying15734Shield Bash15735Bodyguard15736Heighten SensesPoisoning15737Tolerance15738Injected Strike15739Potency- passiveWrestling15740Rampage15741Fists of Fury15742Knockout- passiveAnimal Taming15743Whispering15744Combat Training15745Boarding- passiveVirtues495Honesty(not activated this way)      npc merchant discount (return lost items/lost+found boxes  banks/forensic:2x@town,4x@npc, more in fel)496Humility498Spirituality
 exevent popup [id] {x offset} {y offset} - X and Y pixel offset must be used - can't use an ordinal offset
 menu delete [element unique name]
      All elements below the chosen element are deleted as well.
      All elements on a form are deleted when the form is deleted.
      All elements with a panel as it's parent are deleted.
 menu Shape {name} {left} {top} {width} {height} {shapetype} {linetype} {linewidth} {linecolor} {filltype} {fillcolor}
      No more rounded corners or line effects. See the post about updating menu code for more information.

These menu commands only form0 (form name for classic menu window):
 menu clear
       [all child forms are deleted and #menubutton uninitialized (used to be initialized to N/A]
 menu font align { left|center|right }
 menu font bgcolor [color-descriptor]
 menu font color [color-descriptor]
 menu font name  [font-name]
 menu font size  {point-size}
 menu font style {b|i|u|s}
 menu font transparent [ #true|#false ]
 menu show
 menu window color  {color-descriptor}
 menu window transparent [ opacity percentile ]
 menu Window Size {width} {height}

New Commands
 exevent equip id id id ... ; instant dress
    This is a very fast way to equip items. It will replace items in that slot. It works with gargoyle items (exevent droppd doesn't work with gargoyle items)

 event statbar #charid
    Brings up the health bar for the character, npc, follower or monster. A maximimum of 9 status bars can be active at any one time.
    Once successful these will be set:
    #CONTNAME = status_gump
    #CONTID = ID of mobile
    #CONTTYPE = TYPE of mobile
    #CONTHP = percent of health

 menu form [form unique name] left top width height [text]
Note:
* menu setprop [form unique name] visible #true is required to make it viewable.
* Values are not inherited from the default, so menu setprop [form unique name] color $BBGGRR is needed to set the form color.
 menu getdef [option name: will be returned in #menures]
 menu panel [panel unique name] left top height width
   A panel is a container for menu elements. Each menu element has a parent - which is either a form or a panel.
   When an menu element is created, whatever the current default parent is inherited, but can be reassigned using menu setprop [element unique name] parent [parent element name].
 menu popdef
   This restores all menu setdef settings to the values prior to menu pushdef command.
 menu pushdef
   This can be used to protect any current default settings for a temporary setting. The primary goal is for library routines to be able to protect their settings from interfering with the calling script's settings. It serves as a protection for the menu default settings similar to how namespace commands do not interfere with script/library variables.
 menu radio [radio_unique_name] left top width height [checked: #true/#false] [labeled text...]
   Radio buttons limit only one in the parent form or panel to have a #true value.
   This behavior matches a listbox, while typically taking up more screen space for a quicker and more direct user interaction.
 menu setdef [alignment|color|fontcolor|fontname|fontsize|fontstyle|parent] [value]
    setdef and getdef are used for the DEFAULT options that may be inherited by subsequent menu commands
 menu setprop [element's unique name] [option #spc value pair]
Parameters for GETDEF, SETDEF (the 7 listed below applying to "DEFAULT") and SETPROP (all listed options)
      OptionValuesThese can be applied to the following menu elements      alignment [0=left|1=right|2=center]TEXTRADIOCHECKDEFAULT      color     [hexadecimal $BBGGRR blue, green, red (Pascal format)] *See notes for menu form above.FORMPANELTEXTBUTTONEDITRADIOCHECKCOMBOLISTDEFAULT      checked   [#true|#false]RADIOCHECK      enabled   [#true|#false]FORMPANELTEXTBUTTONEDITRADIOCHECKCOMBOLISTIMAGE      fontcolor [hexadecimal $BBGGRR blue, green, red (Pascal format)]TEXTBUTTONEDITRADIOCHECKCOMBOLISTDEFAULT      fontname  [name of font]TEXTBUTTONEDITRADIOCHECKCOMBOLISTDEFAULT      fontsize  [font size number]TEXTBUTTONEDITRADIOCHECKCOMBOLISTDEFAULT      fontstyle {sum of style attributes} ; 1=bold, 2=italic, 4=underline, 8=strikeoutTEXTBUTTONEDITRADIOCHECKCOMBOLISTDEFAULT      height    [# of pixels]FORMPANELTEXTBUTTONEDITRADIOCHECKCOMBOLISTIMAGE      left      [# of pixels]FORMPANELTEXTBUTTONEDITRADIOCHECKCOMBOLISTIMAGE      parent    [form or panel name where the element resides]PANELTEXTBUTTONEDITRADIOCHECKCOMBOLISTIMAGEDEFAULT      text      [text]FORMTEXTBUTTONEDITRADIOCHECK      tooltip   [text description used as tool tip when mouse hovers over element]FORMPANELTEXTBUTTONEDITRADIOCHECKCOMBOLISTIMAGE      top       [# of pixels]FORMPANELTEXTBUTTONEDITRADIOCHECKCOMBOLISTIMAGE      visible   [#true|#false]FORMPANELTEXTBUTTONEDITRADIOCHECKCOMBOLISTIMAGE      width     [# of pixels]FORMPANELTEXTBUTTONEDITRADIOCHECKCOMBOLISTIMAGE

 ignorecont [#contid|#contype|#contname|reset]
    Ignorecont is used to ignore gumps. It is restricted to a single definition at a time, so each definition will have its own ignorecont statement.
    It can ignore by #contid or #conttype or #contname.
    Issuing "ignorecont reset" will remove all ignored gumps. The example routine "resetgumps" will restore the default ignored gumps at EUO startup.
[/list]
--- Code: easyuo ---sub resetgumps ignorecont reset ignorecont BARK_GUMP ignorecont DAMAGENUMBERS_GUMP ignorecont DUMB_GUMP ignorecont GAMEAREAEDGEGUMP ignorecont MAP_GUMP ignorecont MENUBAR ignorecont MISSILE_GUMP ignorecont NEW_ITEM_PROP_GUMP ignorecont RETICLE_GUMP ignorecont TARGET_GUMP ignorecont UNICODE_BARK_GUMPreturn
 event conttop [number]
    Event conttop will cycle through gumps. The number is simply an index for the command it has nothing to do with a number tied to any particular gump.
    When the command is issued, the gump will become the most recent gump in the access order. Running the same routine will reverse the order of gumps.

--- Code: easyuo ---for %i 0 100 { event conttop %i if #contname <> %lcontname || #conttype <> %lconttype || #contid <> %lcontid || #contsize <> %lcontsize || #contposx <> %lcontposx || #contposy <> %lcontposy  {  set %lcontname #contname  set %lconttype #conttype  set %lcontid #contid  set %lcontsize #contsize  set %lcontposx #contposx  set %lcontposy #contposy  } else  break }display ok How many gumps found: %i ; %i is 0 based so final value is the count
Some notes about the dress/arm macros
Event macro 61 and 64 (saved dress/arm respectively) uses a number to keep track of the dress. I ran it repeatedly to > 50 and it continued to swap my armed items.
Maybe there is an upper limit (255 might seem logical), but somewhere before 50 I run out of various outfits I can carry.

For my sampire, I use:
1) my PVM outfit
2) post resurrectiion high LRC, high MR, high LMC +skill (meditation, necromancy, focus) suit
3) 2 handed weapon (double axe) - double strike weapon, whirlwind
4) 2 handed weapon (bladed staff) - armor ignore
5) 1 handed weapon (radiant scimitar) - whirlwind allowing potions
I do have some setups with a variety of weapons for various hit spell (hit fireball, hit lightning, hit dispel) depending on the situation.
I also will engage various slayer type weapons.
I do not happen to, but could include a high luck suit for the kill moment.

I am still well short of 50+ configurations. While the client seems to indicate 4 saved slots, I am pushing it beyond that.

It needs at least a wait 15-16 (.75-.8 second) between each action as a cool down for my cable internet connection. Since about 1 second is the standard cool down for most "actions" - that gets my best recommendation unless you have a very slow connection. You just won't switch outfits/weapons that often that a .25 second difference will be that dramatic. That cool down may apply to 'USE" actions that immediately follow (event macro 17, etc.).

While exevent equip is also practically instant, these macros have the fast save and fast unequip options. If you have all 18 slots with something equipped, it will take many seconds to undress your former outfit with the forced cool down between drag/drop steps. The event macro 62 can strip 16 of the slots (non-hand slots) in < 1 second including cool down.

I only use the 62 (undress) and 65 (disarm) macros for specific things. 62 is excellent for removing a talisman (slayer) to avoid extra damage from opposing slayer group. 65 is excellent for swapping weapons/shield to prepare for anti-bloodoath and ready for potion drinking.


Gaderian:
Reserved for more examples.

manwinc:
event conttop [number]

Oh baby,

Endless Night:

--- Quote from: manwinc on January 24, 2020, 03:36:30 PM ---event conttop [number]

Oh baby,

--- End quote ---

See my gump subs for some examples of usage:  http://www.scriptuo.com/index.php?topic=15545.0     

Gaderian:
I updated this to reflect correct values for menu setdef/setprop alignment to allow left (0), right (1) and center (2) for text.

I also updated the code example for event conttop to show using 0 as a value. This allows a script to get the most recently activated gump. The former example showed starting with a value of 1 which will miss what was the current gump with focus. It probably doesn't trip someone up in most cases, but if a script actually wants to run through all the gumps, an event conttop 0 command must be processed.

Gaderian

Navigation

[0] Message Index

[#] Next page

Go to full version