Page 3 of 9

Re: Project: Auto leveling new character

Posted: Thu Aug 31, 2017 1:11 pm
by cooco
You should be ok if active potion.
In HelperFunction.lua i change this to add Apprentice Potion

Code: Select all

function CheckPotionRecovery()

	-- Prepare the variables to contain the best item and recharge.
	local BestInventory = nil;
	local BestRecharge = 0;
	local TotalRechargeHealth = Player:GetHealthMaximum() - Player:GetHealthCurrent();
	local TotalRechargeMana = Player:GetManaMaximum() - Player:GetManaCurrent();
	
	-- Check if a potion is available.
	if self._iPotionDelay == nil or self._iPotionDelay < Time() then
		
		-- Loop through your inventory
		for Inventory in ListIterator( InventoryList:GetList()) do

			-- Check if this is a life potion
			if string.find( Inventory:GetName(), "Design" ) == nil and string.find( Inventory:GetName(), "Recovery Potion" ) ~= nil then
				
				if string.find( Inventory:GetName(), "Fine" ) ~= nil then
					if TotalRechargeHealth >= 2120 and TotalRechargeMana >= 1830 and BestRecharge < 2120 then
						BestInventory = Inventory;
						BestRecharge = 2120;
					end
				elseif string.find( Inventory:GetName(), "Major" ) ~= nil then
					if TotalRechargeHealth >= 1540 and TotalRechargeMana >= 1600 and BestRecharge < 1540 then
						BestInventory = Inventory;
						BestRecharge = 1540;
					end
				elseif string.find( Inventory:GetName(), "Greater" ) ~= nil then
					if TotalRechargeHealth >= 1270 and TotalRechargeMana >= 1480 and BestRecharge < 1270 then
						BestInventory = Inventory;
						BestRecharge = 1270;
					end
				elseif string.find( Inventory:GetName(), "Lesser" ) ~= nil then
					if TotalRechargeHealth >= 670 and TotalRechargeMana >= 980 and BestRecharge < 670 then
						BestInventory = Inventory;
						BestRecharge = 670;
					end
				elseif string.find( Inventory:GetName(), "Minor" ) ~= nil then
					if TotalRechargeHealth >= 370 and TotalRechargeMana >= 590 and BestRecharge < 370 then
						BestInventory = Inventory;
						BestRecharge = 370;
					end
				elseif string.find( Inventory:GetName(), "Apprentice" ) ~= nil then
				
					if TotalRechargeHealth >= 370 and BestRecharge < 370 then
				
						BestInventory = Inventory;
						BestRecharge = 370;
					end
				elseif TotalRechargeHealth >= 970 and TotalRechargeMana >= 1280 and BestRecharge < 970 then
					BestInventory = Inventory;
					BestRecharge = 970;
				end
				
			end

		end
		
		-- Check if we have a positive match and see if the cooldown allows the use of it.
		if BestInventory ~= nil and BestInventory:GetCooldown() == 0 then
			if PlayerInput:Inventory( BestInventory:GetName()) then
				self._iPotionDelay = Time() + BestInventory:GetReuse();
			end
			return false;
		end
		
	end
	
	-- We have not executed any potion.
	return true;
	
end
I disable mana check, so it will used like a normal heal potion.
I hope this help you.

Re: Project: Auto leveling new character

Posted: Fri Sep 01, 2017 6:28 pm
by Laudel
Jo cooco,

big thx for this amazing work :!: I´ll test it out and it works really great :D.
I hope so we will see much more scripts for the next lvling areas :D :lol: :!: :!:
If you need some decent scripts for Assa or Gladi feel free to let me know it on pm.

Best regards Dude!!!

Re: Project: Auto leveling new character

Posted: Wed Sep 06, 2017 5:14 pm
by cooco
New script update. :)

Re: Project: Auto leveling new character

Posted: Thu Sep 07, 2017 7:11 am
by locatelli
Your scripts are awesome, they just one one of my bots, and I tried nochsana one. You know what would be wonderful? This for rift of oblivion :D

Re: Project: Auto leveling new character

Posted: Thu Sep 07, 2017 11:10 am
by cooco
My goal is level 1 to 65.
Ill try to implimento Rift of oblivion too.

Now i need to understand how level up from 41/42 to 46. Any ideas guys?

Re: Project: Auto leveling new character

Posted: Thu Sep 07, 2017 4:13 pm
by Quirunerk
can we use 2 as on same pc ?

Re: Project: Auto leveling new character

Posted: Thu Sep 07, 2017 4:30 pm
by Quirunerk
Clearing the console window...
- OnLoad
- 10
- 1 10-15
- OnLoad search procedure: 10_15
- OnLoad search procedure: 1_1
- [string "LevelingNewCharacter.lua"]:292: attempt to index field '_ControllerClass' (a nil value)

and how can i fix this

Re: Project: Auto leveling new character

Posted: Thu Sep 07, 2017 5:57 pm
by cooco
Oh yes sorry guy. I change OfficialGrinderFramework to fix some problem with my script.
Ill post all as soon as possible.

Re: Project: Auto leveling new character

Posted: Thu Sep 07, 2017 6:23 pm
by cooco
Quirunerk wrote:
Thu Sep 07, 2017 4:30 pm
Clearing the console window...
- OnLoad
- 10
- 1 10-15
- OnLoad search procedure: 10_15
- OnLoad search procedure: 1_1
- [string "LevelingNewCharacter.lua"]:292: attempt to index field '_ControllerClass' (a nil value)

and how can i fix this
Try now ;)

Re: Project: Auto leveling new character

Posted: Fri Sep 08, 2017 12:30 am
by Quirunerk
And can i use 2 aion script and client on same pc ?