Difference between revisions of "OgreUtilitiesAPI"

From ISXOgre
Jump to: navigation, search
(List of Functions)
(List of Methods)
 
(2 intermediate revisions by one other user not shown)
Line 83: Line 83:
 
|Param 2
 
|Param 2
 
|colspan="2"|Distance||50|| Default = 50
 
|colspan="2"|Distance||50|| Default = 50
 +
|-
 +
 +
|rowspan="3"|<center>'''Set_Checks_GroupHealth'''</center>
 +
|-
 +
|Param 1
 +
|colspan="2"|T or F||TRUE or FALSE|| Default = TRUE
 +
|rowspan="3"| Sets checking the group health is under specified and if so stops naving till health goes above specified.
 +
|-
 +
|Param 2
 +
|colspan="2"|Health||90|| Default = 90
 +
|-
 +
 +
|rowspan="2"|<center>'''Set_Check_NoChecks'''</center>
 +
|-
 +
|Param 1
 +
|colspan="2"|T or F||TRUE or FALSE|| Default = TRUE
 +
|rowspan="2"| Will disable any and all Nav checks
 +
|-
 +
 +
|rowspan="2"|<center>'''Set_Check_CampSpotMeOnCombat'''</center>
 +
|-
 +
|Param 1
 +
|colspan="2"|T or F||TRUE or FALSE|| Default = FALSE
 +
|rowspan="2"| If you are engaged in campspot while navigating, you will campspot. Once combat is gone, a "LetsGo" for you will be issued.
 +
|-
 +
 +
|rowspan="2"|<center>'''Set_Check_CampSpotGroupOnCombat'''</center>
 +
|-
 +
|Param 1
 +
|colspan="2"|T or F||TRUE or FALSE|| Default = FALSE
 +
|rowspan="2"| If your group is engaged in campspot while navigating, your group will campspot. Once combat is gone, a "LetsGo" for your group will be issued.
 +
|-
 +
 +
|rowspan="2"|<center>'''Set_CampSpot_HowClose'''</center>
 +
|-
 +
|Param 1
 +
|colspan="2"|HowClose||1.5|| Default = 1.5
 +
|rowspan="2"| How close you want the campspot to be to the location issued. This means within 1.5 of the campspot (which is pretty close and is the default for campspot).
 +
|-
 +
 +
|rowspan="2"|<center>'''Set_CampSpot_HowFar'''</center>
 +
|-
 +
|Param 1
 +
|colspan="2"|HowFar||200|| Default = 200
 +
|rowspan="2"| How far from the campspot before it abandons trying to get there.
 
|-
 
|-
  

Latest revision as of 16:30, 6 November 2019

Implementing OgreUtilities

  • To use OgreUtilities you will need to load the code into your script.
    • The following will load OgreUtilities into your script.
   function Load_OgreUtilities()
   {
       ogre utilities
       wait 5
       Obj_CreateOgreUtilities:CreateOgreUtilities[${Script.Filename}]
       ;// Returns variable: OgreUtilities
       Obj_CreateOgreUtilities:CreateOgreCharacterData[${Script.Filename}]
       ;// Returns variable: OgreCharacterData
   
       ;// Usage here. See wiki <Link here would likely be helpful, and some examples>    
   } 
  • This will allow you to use all of the below Methods, Members, Functions below.


Summary

  • List of Methods, Members, Functions
  • pre configured Methods, Members, Functions to make coding scripts easier for people.
  • If their is a command you do not understand please feel free to ask in ogre discord and someone will explain and try to word it better here in the list

Advanced Navigation Options

Usage

  • Obj_OgreUtilities.OgreNavChecks:<MethodNameHere>[<ParametersHere>]
    • Example - Obj_OgreUtilities.OgreNavChecks:Set_Check_MeInCombat[FALSE]

List of Methods

  • Below is a list of all available methods.
Command Parameters Example Notes Description
Set_CheckAll
Param 1 Distance 50 Default = 50 Sets checking group in combat, and distance to 50, sets checking if you are in combat.
Set_Check_MeInCombat
Param 1 T or F TRUE or FALSE Default = TRUE Sets checking if you are in combat.
Set_Check_Group
Param 1 T or F TRUE or FALSE Default = TRUE Sets checking the group for combat and the distance.
Param 2 Distance 50 Default = 50
Set_Check_GroupCombatOnly
Param 1 T or F TRUE or FALSE Default = TRUE Sets checking if you are in combat. Will disable "Set_Check_GroupDistanceOnly" if it is enabled.
Set_Check_GroupDistanceOnly
Param 1 T or F TRUE or FALSE Default = TRUE Sets checking the group for combat and the distance. Will disable "Set_Check_GroupCombatOnly" if it is enabled.
Param 2 Distance 50 Default = 50
Set_Checks_GroupHealth
Param 1 T or F TRUE or FALSE Default = TRUE Sets checking the group health is under specified and if so stops naving till health goes above specified.
Param 2 Health 90 Default = 90
Set_Check_NoChecks
Param 1 T or F TRUE or FALSE Default = TRUE Will disable any and all Nav checks
Set_Check_CampSpotMeOnCombat
Param 1 T or F TRUE or FALSE Default = FALSE If you are engaged in campspot while navigating, you will campspot. Once combat is gone, a "LetsGo" for you will be issued.
Set_Check_CampSpotGroupOnCombat
Param 1 T or F TRUE or FALSE Default = FALSE If your group is engaged in campspot while navigating, your group will campspot. Once combat is gone, a "LetsGo" for your group will be issued.
Set_CampSpot_HowClose
Param 1 HowClose 1.5 Default = 1.5 How close you want the campspot to be to the location issued. This means within 1.5 of the campspot (which is pretty close and is the default for campspot).
Set_CampSpot_HowFar
Param 1 HowFar 200 Default = 200 How far from the campspot before it abandons trying to get there.

Methods

Usage

  • Example - Obj_OgreUtilities:AcceptQuest
    • Would Accept a quest if a quest window exists.

List of Methods

  • Below is a list of all available methods.
Command Parameters Example Notes Description
AcceptQuest
Param 1 N/A N/A N/A Accepts a quest if a quest window exists.
EQ2_onQuestOffered
Param 1 N/A N/A N/A If enabled, accepts new quests.
EQ2_onRewardWindowAppeared
Param 1 N/A N/A N/A If enabled, accepts Reward windows.
Jump
Param 1 N/A N/A N/A Jumps a toon.
Set_EQ2_onQuestOffered
Param 1 T or F TRUE/FALSE Enables (TRUE) or disables (FALSE) the EQ2_onQuestOffered event. Turns the event on or off
Set_EQ2_onRewardWindowAppeared
Param 1 T or F TRUE/FALSE Enables (TRUE) or disables (FALSE) the EQ2_onRewardWindowAppeared event. Turns the event on or off


Members

Usage

Example 1
   if ${Obj_OgreUtilities.AnyGroupMembersDead}
   {
       ;// Will return TRUE if any group members are dead False if all alive
       ;// Code to execute if it comes back as TRUE
   }

Example 2

  • echo ${Obj_OgreUtilities.ConvertSecondsToHMS[4500]}
    • Would convert and return the specified seconds into hour.minute.seconds.

List of Members

  • Below is a list of all available members.
Command Parameters Example Notes Description
AnyGroupMembersDead
Param 1 N/A N/A N/A Checks if any group members are dead.
CleanName
Param 1 Input to clean Kannkor's battle Bot Cleans an input Some zones, I believe such as proving grounds, you can end up with some very odd names for characters, this removes it and "cleans" the input.
ConvertSecondsToHMS
Param 1 Seconds 2500 Seconds to convert. Converts seconds to hour minutes seconds.
Get_Hours
Param 1 Seconds 2500 Seconds to convert. Determines how many whole hours are in the seconds.
Get_Minutes
Param 1 Seconds 2500 Seconds to convert. Determines how many whole minutes are in the seconds. Return can only be 0 to 59, as any value above that would be returned in Get_Hours.
Get_Seconds
Param 1 Seconds 2500 Seconds to convert. Determines how many whole seconds are in the seconds. Return can only be 0 to 59, as any value above that would be returned in Get_Hours or Get_Minutes.
GetAscensionClass
Param 1 N/A N/A N/A spews your current ascension class.
HaveAbilityID
Param 1 ID 483993047 ID of ability to check. returns TRUE if you have the ability or FALSE if you do not.
InZoneName
Param 1 Zone Name "Myrist, the Great Library" Zone name to check. Checks if you are in specified zone name.
InZoneShortName
Param 1 Zone Name "exp15_rgn_plane_of_knowledge" Zone short name to check. Checks if you are in specified zone short name.
ItemCount
Param 1 Item Name "mechanical gear" Item name to check. Counts how many of said item you have in your inventory. Does NOT count bank. This handles counting multiple stacks.
NearLoc
Param 1 Loc "737.106506,411.865784,-388.380249" Loc to check. Checks if you are within specified distance to specified Loc.
Param 2 Distance 10 how close. Default = 10
NPCCount
Param 1 Distance 30 Distance to check. Counts how many NPCs are within specified distance.
OnCorrectCharacter
Param 1 Toon name "Kannkor" Name of toon to check. Checks currently logged in toon name matches specified toon name.
WhereAreWe
Param 1 N/A N/A N/A Returns where you are. Valid returns are: GUILDHALL, or the zone hash ( ${Zone.ShortName} ). Basically used for checking if you're in a guild hall.


Functions

Usage

  • All functions are locking. That means when you call them, they 'hold' the script and return once completed.
    • Almost every single function has a return, usually bool that you can access. If TRUE, it means it believes the function was successful, if FALSE, it believes the function was not successful.
      • You can access this return, by checking ${Return} immediately after the function call.

Example 1

   call Obj_OgreUtilities.CallToGH
   if ${Return}
      echo Means CallToGH was successful!

List of Functions

  • Below is a list of all available functions


Command Parameters Example Notes Description
CallToGH
Param 1 T or F TRUE/FALSE Default FALSE. FALSE means if Call to Guild Hall is not available, wait for it. TRUE means if the call is not available, then don't cast it. Calls to Guild Hall.
CastAbilityID
Param 1 ID 106506 ID of the ability. Casts ability and waits specified time for ability to cast.
Param 2 Wait Time 50 = 5 seconds Time to wait. Default = 50
CastEvac
Param 1 NotAvailableAtThisTime NotAvailableAtThisTime NotAvailableAtThisTime Can't be used at this time. Requires a reference that isn't accessible yet.
CheckEvacTotems
Param 1 N/A N/A N/A Checks you have evac totems.
CheckIfGroupInSameZone
Param 1 How many seconds to check for 30 How many seconds to check for returns TRUE as soon as your entire group is in the same zone. Returns FALSE if at the end of the seconds to check for, if everyone is not in the same zone
ClearQuestWindow
Param 1 N/A N/A N/A Clears the quest helper window. The in-game on-screen quest information with checkboxes that can only show like 5 quests. This just unchecks them. It does NOT delete quests.
DoConversation
Param 1 Numerical sequence of conversation baubles to choose 1 1 2 3 1 When conversing with an NPC, this example would choose option 1, then 1, then 2, then 3, then 1. Accepts any number of conversations, and does so with a 1/2 second delay
DoHail
Param 1 NPC "Flag dude" Name of NPC. Hails specified NPC via Name.
DoHailID
Param 1 ID 8959659794 ID of NPC. Hails specified NPC via ID.
DoTarget
Param 1 NPC "Flag dude" Name of NPC. Targets NPC if withing specified Range.
Param 2 Range 50 within Range. Default = 40
FastTravel
Param 1 Name "Freeport" Name of Zone/Destination. Travels to specified destination. ( Requires Membership )
Param 2 Exact match TRUE/FALSE Default = FALSE
GetIntoCorrectZone
Param 1 NotAvailableAtThisTime NotAvailableAtThisTime NotAvailableAtThisTime This was never finished, it would help navigating from zone to zone automatically, through connecting zones. However the manual input and maps required map the set up extremely difficult.
GHToHouse
Param 1 Name "Kannkors house" Name of house to go to. Zones you to specified house from Guild Hall.
HandleCampSpotToLoc
Param 1 Loc "737.106506,411.865784,-388.380249" Loc to campspot to. Sets your campspot to the location you passed it, and waits until you are within Range of it. Example, if you set it to 100, it would return TRUE if you are within 100 meters of the campspot.
Param 2 Range 125 within Range. Default = 125
HandleWaitForGroupDistance
Param 1 Distance 5 within Disatnce. Default = 5 Waits until your entire group is within # distance of you. Good to use after you nav some where to make sure everyone is with you.
HandleClickActor_Special
Param 1 Distance 10 within Disatnce. Default = 10 Clicks special actor within disance specified.
HandleClickActor
Param 1 Name "Mechanical gear" Name of actor. Clicks an actor within disance specified.
Param 2 Distance 10 within Disatnce. Default = 10
HandleConversation
Param 1 NotAvailableAtThisTime NotAvailableAtThisTime NotAvailableAtThisTime Requires an object not available at this time
HandleConversationByText
Param 1 Text inputs "Where would you like to go?" "I want to get a rally flag" Will handle chat baubles based on text input. Accepts up to 10 parameters. Conversation baubles
HandleWaitForCampSpot
Param 1 WaitBeforeChecking 10 Waits this amount of time before checking, allowing campspot to be set. Default is 0 (no wait at all). Recommend use of 10 (1 second) if you JUST changed your campspot Waits until you are dead or within range of campspot. Returns TRUE if you are at your campspot (regardless of your range), returns FALSE if you are NOT at your campspot.
HandleWaitForCombat
Param 1 wait time 50 = 5 seconds Time to wait. Default = 50 Waits specified time if in combat with specified options.
Param 2 Skip TRUE/FALSE Skip if no mobs exist.
Param 3 Distance 30 Skip if no mobs exist within specified distance.
Param 4 Clear target 40 Clear target if distance of target over specified distance. Default = 40
HandleWaitForCombatOrPower
Param 1 wait time 50 = 5 seconds Time to wait. Default = 50 Waits specified time if in combat with specified options.
Param 2 Skip TRUE/FALSE Skip if no mobs exist.
Param 3 Distance 30 Skip if no mobs exist within specified distance.
Param 4 Clear target 40 Clear target if distance of target over specified distance. Default = 40
HandleWaitForCombatWithNPC
Param 1 NPC "Trakanon" Name of NPC. Waits until combat is over. Returns TRUE if there was combat, and FALSE if there was not combat.
Param 2 Args -TimeToWait 50 (5 seconds), -SkipIfNoMobs TRUE/FALSE, -SkipIfNoMobsWithin 30, -ClearTargetIfTargetDistanceOver 50 Accepts any of these args in pairs. The defaults are listed.
HandleWaitForZoning
Param 1 N/A N/A N/A Handles wait for when you are Zoning.
HandleWaitTime
Param 1 Wait Time 50 Time to wait. Default = 50 (5 seconds) Literally just waits the specified amount of time.
HandleZoneDoor
Param 1 Option 1 Zone door option. Default = 1 Clicks specified Zone within a List UI.
LoginToon
Param 1 Toon "Kannkor" Toon name to log in Logs in specified toon.
NavTo
Param 1 Loc "737.106506,411.865784,-388.380249" Loc to nav to. Nav to specified location.
Param 2 How Close 1.5 Get this close to destination. Default = 1.5
NavToLoc
Param 1 Loc "737.106506,411.865784,-388.380249" Loc to nav to. Nav to specified location by specified precision.
Param 2 Precision 5 Precision to destination. Default = 5
NavToLocation
Param 1 Location "NPC_Loc_Main_Room" Saved Location to nav to. Nav to specified location by specified precision.
Param 2 Precision 5 Precision to destination. Default = 5
PreCombatBuff
Param 1 Seconds 5 = 5 seconds Amount of Time to buff. Enters bots into Combat to force them to start casting incombat buffs/heals etc.
ResetCameraAngle
Param 1 N/A N/A N/A Resets your camera angle on your character, so it's in 3rd person view facing forward. Super useful if it may change before conversing with an NPC.
Revive
Param 1 Option 1 Revive Option to use. Default = 1 Revives at specified location.
Set_FirstPersonView
Param 1 N/A N/A N/A Puts you into First person view.
Set_LookDown
Param 1 Value 30 How long to hold look down for. Default = 30 (3 seconds) Makes you "look down" for x seconds.
Set_LookUp
Param 1 Value 30 How long to hold look up for Default = 30 (3 seconds) Makes you "look up" for x seconds.
Set_ZoomIn
Param 1 Value 30 Default = 30 Does nothing - Use Set_FirstPersonView if you wish to be zoomed in.
Set_ZoomOut_MouseWheel
Param 1 Value 30 How many zoom out clicks to do. Default = 30 Zooms out using the mouse wheel
Set_ZoomOut
Param 1 Value 30 How long to hold the Zoom out key for. Default = 30 (3 seconds) Holds the zoom out key for this long.
WaitForCasting
Param 1 Wait Time 50 = 5 seconds Time to wait. Default = 50 Wait while you are casting a spell or specified wait time.
WaitForGroupToZone
Param 1 How many 60 = 6 times Check how many times. Default = 60 Check specified times for whole group to be in zone.
WaitForLootWindow
Param 1 wait time 50 = 5 seconds wait time. Default = 50 Wait specified time for a lootwindow.
WaitForPower
Param 1 % 95 wait for power %. Default = 95 Wait for Power to be at or above specified %.
WaitForScript
Param 1 Script name "Random Script" Script name. Wait while specified script is running.
WaitForZoning
Param 1 Wait Time 50 = 5 seconds wait time. Default = 50 Wait while zoning and specified time.
WaitWhileGroupMembersDead
Param 1 N/A N/A N/A wait while group members dead.