|
Gear Swap
サーバ: Phoenix
Game: FFXI
Posts: 52
By Phoenix.Rikudosennin 2014-08-24 12:44:13
Good afternoon everyone. I am in need of some help. my AutoRA.Lua file continuously stops me from AutoRA once I hit 1000 tp. Is there a way to fix it. Here is my AutoRA.lua commands now.
function get_sets()
AccIndex = 1
AccArray = {"LowACC","MidACC","HighACC"} -- 3 Levels Of Accuracy Sets For Shooting/TP/WS. First Set Is LowACC. Add More ACC Sets If Needed Then Create Your New ACC Below. Most of These Sets Are Empty So You Need To Edit Them On Your Own. Remember To Check What The Combined Set Is For Each Sets. --
WeaponIndex = 1
WeaponArray = {"Annihilator",} -- Default Ranged Weapon Is Annihilator. Can Delete Any Weapons/Sets That You Don't Need Or Replace/Add The New Weapons That You Want To Use. --
IdleIndex = 1
IdleArray = {"Movement"} -- Default Idle Set Is Movement --
Armor = 'None'
warning = false
AutoMode = 'ON' -- Set Default Auto RA/WS ON or OFF Here --
Attack = 'OFF' -- Set Default Attack Set ON or OFF Here --
Enmity = 'OFF' -- Set Default Enmity Set ON or OFF Here --
ammo_warning_limit = 10 -- Set Ammo Limit Check Here --
Samurai_Roll = 'ON' -- Set Default SAM Roll ON or OFF Here --
target_distance = 5 -- Set Default Distance Here --
-- Preshot --
sets.Preshot = {
ammo="Scorpion. Arrow"} -- Change to your cheap ammo
end
function pretarget(spell,action)
if spell.action_type == 'Ranged Attack' and not buffactive.amnesia then -- Auto WS/Decoy Shot/Double Shot --
if player.tp >= 4000 and AutoMode == 'ON' then
cancel_spell()
autoWS()
end
elseif spell.action_type == 'Ranged Attack' and spell.target.distance > 24.9 then
cancel_spell()
add_to_chat(123, spell.name..' Canceled: [Out of Range]')
return
elseif spell.type == 'WeaponSkill' and player.status == 'Engaged' then
if spell.skill == 'Archery' or spell.skill == 'Marksmanship' then
if spell.target.distance > 16+target_distance then
cancel_spell()
add_to_chat(123, spell.name..' Canceled: [Out of Range]')
return
end
else
if spell.target.distance > target_distance then
cancel_spell()
add_to_chat(123, spell.name..' Canceled: [Out of Range]')
return
end
end
end
end
function precast(spell,action)
local check_ammo
local check_ammo_count = 1
if spell.action_type == 'Ranged Attack' then
check_ammo = player.equipment.ammo
if player.equipment.ammo == 'empty' or player.inventory[check_ammo].count <= check_ammo_count then
add_to_chat(123, spell.name..' Canceled: [Out of Ammo]')
cancel_spell()
return
else
equip(sets.Preshot)
if player.inventory[check_ammo].count <= ammo_warning_limit and player.inventory[check_ammo].count > 1 and not warning then
add_to_chat(123, '***** [Low Ammo Warning!] *****')
warning = true
elseif player.inventory[check_ammo].count > ammo_warning_limit and warning then
warning = false
end
end
elseif spell.type == "WeaponSkill" then
if player.status ~= 'Engaged' then -- Cancel WS If You Are Not Engaged. Can Delete It If You Don't Need It --
cancel_spell()
add_to_chat(123,'Unable To Use WeaponSkill: [Disengaged]')
return
else
equipSet = sets.
equip(equipSet)
end
end
function midcast(spell,action)
end
function aftercast(spell,action)
if AutoMode == 'ON' then
autoRA()
end
end
function status_change(new,old)
if new == 'Engaged' then
if AutoMode == 'ON' then
autoRA()
end
end
end
-- In Game: //gs c (command), Macro: /console gs c (command), Bind: gs c (command) --
function self_command(command)
if command == 'C2' then -- Auto RA/WS Toggle --
if AutoMode == 'ON' then
AutoMode = 'OFF'
add_to_chat(123,'Auto Mode: [OFF]')
else
AutoMode = 'ON'
add_to_chat(158,'Auto Mode: [ON]')
end
end
end
function autoRA()
if player.status == 'Engaged' then
send_command('@wait 2.7; input /ra <t>')
end
end
function autoWS() -- Change Auto WS Here --
send_command('input /ws "Flaming Arrow" <t>')
end
Cerberus.Conagh
サーバ: Cerberus
Game: FFXI
Posts: 3189
By Cerberus.Conagh 2014-08-24 13:57:02
Your AutoWS and AutoRA have the same toggle, I assume once you get 100 tp it is trying to send a RA and WS command at the same time, but the WS will show an error (assuming you use gun).
Put the whole file into a
So we can look through without huge downloads :)
サーバ: Asura
Game: FFXI
Posts: 19
By Asura.Kurairyu 2014-08-24 14:46:50
Code function get_sets()
AccIndex = 1
AccArray = {"LowACC","MidACC","HighACC"} -- 3 Levels Of Accuracy Sets For Shooting/TP/WS. First Set Is LowACC. Add More ACC Sets If Needed Then Create Your New ACC Below. Most of These Sets Are Empty So You Need To Edit Them On Your Own. Remember To Check What The Combined Set Is For Each Sets. --
WeaponIndex = 1
WeaponArray = {"Annihilator",} -- Default Ranged Weapon Is Annihilator. Can Delete Any Weapons/Sets That You Don't Need Or Replace/Add The New Weapons That You Want To Use. --
IdleIndex = 1
IdleArray = {"Movement"} -- Default Idle Set Is Movement --
Armor = 'None'
warning = false
AutoMode = 'ON' -- Set Default Auto RA/WS ON or OFF Here --
Attack = 'OFF' -- Set Default Attack Set ON or OFF Here --
Enmity = 'OFF' -- Set Default Enmity Set ON or OFF Here --
ammo_warning_limit = 10 -- Set Ammo Limit Check Here --
Samurai_Roll = 'ON' -- Set Default SAM Roll ON or OFF Here --
target_distance = 5 -- Set Default Distance Here --
-- Preshot --
sets.Preshot = {
ammo="Scorpion. Arrow"} -- Change to your cheap ammo
end
function pretarget(spell,action)
if spell.action_type == 'Ranged Attack' and not buffactive.amnesia then -- Auto WS/Decoy Shot/Double Shot --
if player.tp >= 4000 and AutoMode == 'ON' then
cancel_spell()
autoWS()
end
elseif spell.action_type == 'Ranged Attack' and spell.target.distance > 24.9 then
cancel_spell()
add_to_chat(123, spell.name..' Canceled: [Out of Range]')
return
elseif spell.type == 'WeaponSkill' and player.status == 'Engaged' then
if spell.skill == 'Archery' or spell.skill == 'Marksmanship' then
if spell.target.distance > 16+target_distance then
cancel_spell()
add_to_chat(123, spell.name..' Canceled: [Out of Range]')
return
end
else
if spell.target.distance > target_distance then
cancel_spell()
add_to_chat(123, spell.name..' Canceled: [Out of Range]')
return
end
end
end
end
function precast(spell,action)
local check_ammo
local check_ammo_count = 1
if spell.action_type == 'Ranged Attack' then
check_ammo = player.equipment.ammo
if player.equipment.ammo == 'empty' or player.inventory[check_ammo].count <= check_ammo_count then
add_to_chat(123, spell.name..' Canceled: [Out of Ammo]')
cancel_spell()
return
else
equip(sets.Preshot)
if player.inventory[check_ammo].count <= ammo_warning_limit and player.inventory[check_ammo].count > 1 and not warning then
add_to_chat(123, '***** [Low Ammo Warning!] *****')
warning = true
elseif player.inventory[check_ammo].count > ammo_warning_limit and warning then
warning = false
end
end
elseif spell.type == "WeaponSkill" then
if player.status ~= 'Engaged' then -- Cancel WS If You Are Not Engaged. Can Delete It If You Don't Need It --
cancel_spell()
add_to_chat(123,'Unable To Use WeaponSkill: [Disengaged]')
return
else
equipSet = sets.
equip(equipSet)
end
end
function midcast(spell,action)
end
function aftercast(spell,action)
if AutoMode == 'ON' then
autoRA()
end
end
function status_change(new,old)
if new == 'Engaged' then
if AutoMode == 'ON' then
autoRA()
end
end
end
-- In Game: //gs c (command), Macro: /console gs c (command), Bind: gs c (command) --
function self_command(command)
if command == 'C2' then -- Auto RA/WS Toggle --
if AutoMode == 'ON' then
AutoMode = 'OFF'
add_to_chat(123,'Auto Mode: [OFF]')
else
AutoMode = 'ON'
add_to_chat(158,'Auto Mode: [ON]')
end
end
end
function autoRA()
if player.status == 'Engaged' then
send_command('@wait 2.7; input /ra <t>')
end
end
function autoWS() -- Change Auto WS Here --
send_command('input /ws "Flaming Arrow" <t>')
end
サーバ: Asura
Game: FFXI
Posts: 19
By Asura.Kurairyu 2014-08-24 14:48:08
There you go. I am a Samurai. Using a bow and to skill up while I play my 3DS and other games.
Cerberus.Conagh
サーバ: Cerberus
Game: FFXI
Posts: 3189
By Cerberus.Conagh 2014-08-24 15:12:49
There you go. I am a Samurai. Using a bow and to skill up while I play my 3DS and other games.
My main question however, is why you dont use this...
Code --Copyright (c) 2013, Banggugyangu
--All rights reserved.
--Redistribution and use in source and binary forms, with or without
--modification, are permitted provided that the following conditions are met:
-- * Redistributions of source code must retain the above copyright
-- notice, this list of conditions and the following disclaimer.
-- * Redistributions in binary form must reproduce the above copyright
-- notice, this list of conditions and the following disclaimer in the
-- documentation and/or other materials provided with the distribution.
-- * Neither the name of <addon name> nor the
-- names of its contributors may be used to endorse or promote products
-- derived from this software without specific prior written permission.
--THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
--ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
--WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
--DISCLAIMED. IN NO EVENT SHALL <your name> BE LIABLE FOR ANY
--DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
--(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
--LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
--ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
--(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
--SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
windower.register_event('load',function ()
version = '2.1.2'
delay = 0
RW_delay = 0
Ammo_delay = 0
retrn = 0
halt_on_tp = true
windower.send_command('unbind ^d')
windower.send_command('unbind !d')
windower.send_command('bind ^d ara start')
windower.send_command('bind !d ara stop')
windower.send_command('alias ara lua c autora')
end)
function start()
windower.add_to_chat(17, 'AutoRA STARTING~~~~~~~~~~~~~~')
player = windower.ffxi.get_player()
if player.status == 1 then
auto = 1
elseif player.status == 0 then
auto = 0
end
shoot()
end
function stop()
windower.add_to_chat(17, 'AutoRA STOPPING ~~~~~~~~~~~~~~')
auto = 0
end
function shoot()
windower.send_command('input /shoot <t>')
end
function shootOnce()
windower.send_command('input /shoot <t>')
end
--Function Author: Byrth
function split(msg, match)
local length = msg:len()
local splitarr = {}
local u = 1
while u <= length do
local nextanch = msg:find(match,u)
if nextanch ~= nil then
splitarr[#splitarr+1] = msg:sub(u,nextanch-match:len())
if nextanch~=length then
u = nextanch+match:len()
else
u = lengthlua
end
else
splitarr[#splitarr+1] = msg:sub(u,length)
u = length+1
end
end
return splitarr
end
function haltontp()
if halt_on_tp == true then
windower.add_to_chat(17, 'AutoRA will no longer halt upon reaching 1000 TP')
halt_on_tp = false
elseif halt_on_tp == false then
windower.add_to_chat(17, 'AutoRA will halt upon reaching 1000 TP')
halt_on_tp = true
end
end
windower.register_event('action',function (act)
local actor = act.actor_id
local category = act.category
local player = windower.ffxi.get_player()
if ((actor == (player.id or player.index))) then
if category == 2 then
if player.vitals['tp'] < 1000 then
if auto == 1 then
if player.status == 1 then
auto = 1
elseif player.status == 0 then
auto = 0
return
end
end
if auto == 1 then
windower.send_command('@wait 1.5;input /shoot <t>')
elseif auto == 0 then
end
else
if halt_on_tp == true then
windower.add_to_chat(17, 'AutoRA HALTING AT 1000 TP ~~~~~~~~~~~~~~')
return
else
if auto == 1 then
if player.status == 1 then
auto = 1
elseif player.status == 0 then
auto = 0
return
end
end
if auto == 1 then
windower.send_command('@wait 1.5;input /shoot <t>')
elseif auto == 0 then
end
end
end
end
end
end)
--Function Designer: Byrth
windower.register_event('addon command',function (...)
local term = table.concat({...}, ' ')
local splitarr = split(term,' ')
if splitarr[1]:lower() == 'start' then
start()
elseif splitarr[1]:lower() == 'stop' then
stop()
elseif splitarr[1]:lower() == 'shoot' then
shoot()
elseif splitarr[1]:lower() == 'reload' then
setDelay()
elseif splitarr[1]:lower() == 'haltontp' then
haltontp()
elseif splitarr[1]:lower() == 'help' then
windower.add_to_chat(17, 'AutoRA v'..version..'commands:')
windower.add_to_chat(17, '//ara [options]')
windower.add_to_chat(17, ' start - Starts auto attack with ranged weapon')
windower.add_to_chat(17, ' stop - Stops auto attack with ranged weapon')
windower.add_to_chat(17, ' haltontp - Toggles automatic halt upon reaching 1000 TP')
windower.add_to_chat(17, ' help - Displays this help text')
windower.add_to_chat(17, ' ')
windower.add_to_chat(17, 'AutoRA will only automate ranged attacks if your status is "Engaged". Otherwise it will always fire a single ranged attack.')
windower.add_to_chat(17, 'To start auto ranged attacks without commands use the key: Ctrl+d')
windower.add_to_chat(17, 'To stop auto ranged attacks in the same manner: Atl+d')
end
end)
This is the AutoRA Addon that Auto Shots as soon as you are able to and is more efficient than waiting 2.7 seconds.
サーバ: Asura
Game: FFXI
Posts: 19
By Asura.Kurairyu 2014-08-24 15:37:17
the reason why is because I was told that with GearSwap I can have it auto load my ammo when I run out. Just in case I don't fully pay attention.
サーバ: Asura
Game: FFXI
Posts: 19
By Asura.Kurairyu 2014-08-24 18:53:28
Is it possible for AutoRa add on put arrows on if you run out. Because when I am going to skill up Archery I am going to be afk playing something else and I don't want to keep switching back and forth between the games just to see if I have arrows equipped.
By number619 2014-09-18 20:35:04
anyone have a way to add an auto weaponskill and auto job ability to autora.lua file? Thanks!
Good afternoon everyone. I am in need of some help. my AutoRA.Lua file continuously stops me from AutoRA once I hit 1000 tp. Is there a way to fix it. Here is my AutoRA.lua commands now.
function get_sets()
AccIndex = 1
AccArray = {"LowACC","MidACC","HighACC"} -- 3 Levels Of Accuracy Sets For Shooting/TP/WS. First Set Is LowACC. Add More ACC Sets If Needed Then Create Your New ACC Below. Most of These Sets Are Empty So You Need To Edit Them On Your Own. Remember To Check What The Combined Set Is For Each Sets. --
WeaponIndex = 1
WeaponArray = {"Annihilator",} -- Default Ranged Weapon Is Annihilator. Can Delete Any Weapons/Sets That You Don't Need Or Replace/Add The New Weapons That You Want To Use. --
IdleIndex = 1
IdleArray = {"Movement"} -- Default Idle Set Is Movement --
Armor = 'None'
warning = false
AutoMode = 'ON' -- Set Default Auto RA/WS ON or OFF Here --
Attack = 'OFF' -- Set Default Attack Set ON or OFF Here --
Enmity = 'OFF' -- Set Default Enmity Set ON or OFF Here --
ammo_warning_limit = 10 -- Set Ammo Limit Check Here --
Samurai_Roll = 'ON' -- Set Default SAM Roll ON or OFF Here --
target_distance = 5 -- Set Default Distance Here --
-- Preshot --
sets.Preshot = {
ammo="Scorpion. Arrow"} -- Change to your cheap ammo
end
function pretarget(spell,action)
if spell.action_type == 'Ranged Attack' and not buffactive.amnesia then -- Auto WS/Decoy Shot/Double Shot --
if player.tp >= 4000 and AutoMode == 'ON' then
cancel_spell()
autoWS()
end
elseif spell.action_type == 'Ranged Attack' and spell.target.distance > 24.9 then
cancel_spell()
add_to_chat(123, spell.name..' Canceled: [Out of Range]')
return
elseif spell.type == 'WeaponSkill' and player.status == 'Engaged' then
if spell.skill == 'Archery' or spell.skill == 'Marksmanship' then
if spell.target.distance > 16+target_distance then
cancel_spell()
add_to_chat(123, spell.name..' Canceled: [Out of Range]')
return
end
else
if spell.target.distance > target_distance then
cancel_spell()
add_to_chat(123, spell.name..' Canceled: [Out of Range]')
return
end
end
end
end
function precast(spell,action)
local check_ammo
local check_ammo_count = 1
if spell.action_type == 'Ranged Attack' then
check_ammo = player.equipment.ammo
if player.equipment.ammo == 'empty' or player.inventory[check_ammo].count <= check_ammo_count then
add_to_chat(123, spell.name..' Canceled: [Out of Ammo]')
cancel_spell()
return
else
equip(sets.Preshot)
if player.inventory[check_ammo].count <= ammo_warning_limit and player.inventory[check_ammo].count > 1 and not warning then
add_to_chat(123, '***** [Low Ammo Warning!] *****')
warning = true
elseif player.inventory[check_ammo].count > ammo_warning_limit and warning then
warning = false
end
end
elseif spell.type == "WeaponSkill" then
if player.status ~= 'Engaged' then -- Cancel WS If You Are Not Engaged. Can Delete It If You Don't Need It --
cancel_spell()
add_to_chat(123,'Unable To Use WeaponSkill: [Disengaged]')
return
else
equipSet = sets.
equip(equipSet)
end
end
function midcast(spell,action)
end
function aftercast(spell,action)
if AutoMode == 'ON' then
autoRA()
end
end
function status_change(new,old)
if new == 'Engaged' then
if AutoMode == 'ON' then
autoRA()
end
end
end
-- In Game: //gs c (command), Macro: /console gs c (command), Bind: gs c (command) --
function self_command(command)
if command == 'C2' then -- Auto RA/WS Toggle --
if AutoMode == 'ON' then
AutoMode = 'OFF'
add_to_chat(123,'Auto Mode: [OFF]')
else
AutoMode = 'ON'
add_to_chat(158,'Auto Mode: [ON]')
end
end
end
function autoRA()
if player.status == 'Engaged' then
send_command('@wait 2.7; input /ra <t>')
end
end
function autoWS() -- Change Auto WS Here --
send_command('input /ws "Flaming Arrow" <t>')
end
|
|