Jump to content

Welcome to Gaming On Steroids Forums
Register now to gain access to all of our features. Once registered and logged in, you will be able to create topics, post replies to existing threads, give reputation to your fellow members, get your own private messenger, post status updates, manage your profile and so much more. This message will be removed once you have signed in.
Login to Account Create an Account
Photo

Can anyone tell me why isn't my farming working?


  • Please log in to reply
17 replies to this topic

#1
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts
function Ezreal:Farm()
if (myHero.mana/myHero.maxMana >= self.Menu.Farm.FarmMana:Value()/100) then
local qMinion
		if self:CanCast(_Q) then
			for j = 1,Game.MinionCount() do
        local minion = Game.Minion(j)
        if minion.isTargetable and not minion.dead and minion.distance <= Q.range and minion.team ~= myHero.team then
            Qminion = minion
            break
        end
    end
			if qMinion then
				local qMinPos = qMinion:GetPrediction(Q.Speed, Q.Delay)
					    Control.SetCursorPos(qMinPos)
				Control.CastSpell(HK_Q, qMinPos)
			end
		end
	end
end

It's giving me an error here:

        if minion.isTargetable and not minion.dead and minion.distance <= Q.range and minion.team ~= myHero.team then


Thanks in advance


  • 0

#2
MonkeyKid

MonkeyKid

    Advanced Member

  • Members
  • 112 posts
  • LocationBrazil

although I do not know what the error is, try a puting a if minion and before everything. Also, try minion.isEnemy instead of comparing teams, I remember having trouble with that.


  • 0

#3
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

although I do not know what the error is, try a puting a if minion and before everything. Also, try minion.isEnemy instead of comparing teams, I remember having trouble with that.

I'm sorry, I didn't understand, where do I need to put a if minion and ?


  • 0

#4
Meeboo

Meeboo

    Advanced Member

  • Scripts Developer
  • 786 posts
  • LocationUnited States

What error?


  • 0

#5
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

What error?

Just a sec, goin' to loggin now


  • 0

#6
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

What error?

Attempt to compare number with nill


  • 0

#7
Meeboo

Meeboo

    Advanced Member

  • Scripts Developer
  • 786 posts
  • LocationUnited States

Attempt to compare number with nill

Guess you need to change "Q.range" to "Q.Range"


  • 1

#8
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

Guess you need to change "Q.range" to "Q.Range"

Damn, seems like that's it, gonna test now, thank you


  • 0

#9
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

Guess you need to change "Q.range" to "Q.Range"

Thanks, it stopped giving me the error, but it's still not casting the Q at minnions

if (myHero.mana/myHero.maxMana >= self.Menu.Farm.FarmMana:Value()/100) then
local qMinion
		if self:CanCast(_Q) then
			for j = 1,Game.MinionCount() do
        local minion = Game.Minion(j)
        if minion.isTargetable and not minion.dead and minion.distance <= Q.Range and minion.team ~= myHero.team then
            Qminion = minion
            break
        end
    end
			if qMinion then
				local qMinPos = qMinion:GetPrediction(Q.Speed, Q.Delay)
					    Control.SetCursorPos(qMinPos)
				Control.CastSpell(HK_Q, qMinPos)
			end
		end
	end
end

sorry to be bothering you with this


  • 0

#10
MonkeyKid

MonkeyKid

    Advanced Member

  • Members
  • 112 posts
  • LocationBrazil

Thanks, it stopped giving me the error, but it's still not casting the Q at minnions

if (myHero.mana/myHero.maxMana >= self.Menu.Farm.FarmMana:Value()/100) then
local qMinion
		if self:CanCast(_Q) then
			for j = 1,Game.MinionCount() do
        local minion = Game.Minion(j)
        if minion.isTargetable and not minion.dead and minion.distance <= Q.Range and minion.team ~= myHero.team then
            Qminion = minion
            break
        end
    end
			if qMinion then
				local qMinPos = qMinion:GetPrediction(Q.Speed, Q.Delay)
					    Control.SetCursorPos(qMinPos)
				Control.CastSpell(HK_Q, qMinPos)
			end
		end
	end
end

sorry to be bothering you with this

sorry, since you didn't make sure what was the error, I was saying you should test for nil (which evaluates to false in a logical expression in Lua, just like in C and C++)

As I see it now, you assign to a global called Qminion, but test for a nil local called qMinion.

 

In short, change the assignment from Qminion = minion to qMinion = minion


  • 1

#11
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

sorry, since you didn't make sure what was the error, I was saying you should test for nil (which evaluates to false in a logical expression in Lua, just like in C and C++)

As I see it now, you assign to a global called Qminion, but test for a nil local called qMinion.

 

In short, change the assignment from Qminion = minion to qMinion = minion

Damn all this caps-sensitive stuff xD, Thank you for the answer, gonna test it now


  • 0

#12
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

Damn all this caps-sensitive stuff xD, Thank you for the answer, gonna test it now

All good now, it's casting the Q's just fine, there1s just a little issue, sometimes it issues random pings because of the mouse movement when laneclearing.

Is this an issue with ext or am I doing something too slow?


  • 0

#13
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

All good now, it's casting the Q's just fine, there1s just a little issue, sometimes it issues random pings because of the mouse movement when laneclearing.

Is this an issue with ext or am I doing something too slow?

(The laneclear key is on V)

I'll probably just tell along with the post for the users to just change the farm key so no pings are issued


  • 0

#14
MonkeyKid

MonkeyKid

    Advanced Member

  • Members
  • 112 posts
  • LocationBrazil

All good now, it's casting the Q's just fine, there1s just a little issue, sometimes it issues random pings because of the mouse movement when laneclearing.

Is this an issue with ext or am I doing something too slow?

That I could not answer, as I have not tested the API enough. I've been too freaking busy to write my own scripts (I'm open to a colaboration). It's last Highschool Year, and I'm several school years ahead of my age.


  • 0

#15
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

That I could not answer, as I have not tested the API enough. I've been too freaking busy to write my own scripts (I'm open to a colaboration). It's last Highschool Year, and I'm several school years ahead of my age.

All good, sir. Your help was very very appreciated


  • 0

#16
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

All good, sir. Your help was very very appreciated

Good luck with all the highschool business, keep it good as you are doig


  • 0

#17
Meeboo

Meeboo

    Advanced Member

  • Scripts Developer
  • 786 posts
  • LocationUnited States

All good now, it's casting the Q's just fine, there1s just a little issue, sometimes it issues random pings because of the mouse movement when laneclearing.

Is this an issue with ext or am I doing something too slow?

Change LOL hotkey


  • 1

#18
SwipeDan

SwipeDan

    Advanced Member

  • Contributor
  • 54 posts

Change LOL hotkey

Done, thanks sir


  • 1




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users