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

Inspired.lua - Library for Scripters


Best Answer SxcS , 30 July 2016 - 06:15

Is the download link broken, I only see a blank page? Am i doing something wrong? 

its inbuilt in gos, no need to download

Go to the full post »


  • This topic is locked This topic is locked
283 replies to this topic

#41
Vampiere

Vampiere

    Advanced Member

  • Members
  • 79 posts

http://prntscr.com/86ip78 got that pressing v with morgana


  • 1

#42
Darkness

Darkness

    GoSDB's manager

  • Banned
  • PipPipPip
  • 1,137 posts

http://prntscr.com/86ip78 got that pressing v with morgana

me 2, just redownload it and everything will be K


  • 0

#43
BaeSuzy

BaeSuzy

    Advanced Member

  • Members
  • 388 posts
  • LocationBae Suzy

please update your script to add item name titanic Hydra ID item is 3748 in line of #366
jJsxb.png


  • 1

#44
Tiritto

Tiritto

    Script Developer

  • Members
  • 377 posts
  • LocationPoland

It seems that you replaced content of wrong topic and now we're out of your library documentation :(


  • 0

#45
funbox

funbox

    Member

  • Members
  • 16 posts

Updated.

pls add this to validtarget function - latest API change (check Vladimir W, Kog Maw Passive, etc. ):

 

function ValidTarget(unit, range)

range = range or 25000
if unit == nil or GetOrigin(unit) == nil or IsImmune(unit,GetMyHero()) or IsDead(unit) or not IsTargetable(unit) or not IsVisible(unit) or GetTeam(unit) == GetTeam(GetMyHero()) or not IsInDistance(unit, range) then return false end
return true
end


  • 0

#46
artenian

artenian

    Newbie

  • Members
  • 2 posts

I get an error when i press f6 x2, when i press shift i get the menu but it only says config menu. help me please!


  • 0

#47
Inspired

Inspired

    Took the red pill.

  • Ex-Core Dev
  • PipPipPip
  • 723 posts
  • LocationWonderland

It seems that you replaced content of wrong topic and now we're out of your library documentation :(

Well.. ****.
 
 

pls add this to validtarget function - latest API change (check Vladimir W, Kog Maw Passive, etc. ):
 
function ValidTarget(unit, range)
range = range or 25000
if unit == nil or GetOrigin(unit) == nil or IsImmune(unit,GetMyHero()) or IsDead(unit) or not IsTargetable(unit) or not IsVisible(unit) or GetTeam(unit) == GetTeam(GetMyHero()) or not IsInDistance(unit, range) then return false end
return true
end

Added..
  • 0

#48
ilovesona

ilovesona

    Sona's wife

  • Contributor
  • 1,096 posts

any idea about circle?

 

because dlib has circle too....


  • 0

#49
juanrenanlol

juanrenanlol

    Member

  • Members
  • 24 posts

error all champs  8bhGG1.png

 

edit: working inspired


  • 0

#50
Maxxxel

Maxxxel

    The One

  • Scripts Developer
  • 1,087 posts
  • LocationGuess the right City to win 10$
Can u add a validtarget check to your GetDistance function. Whenever i use 
local target= GetCurrentTarget()
If target~=nil and GetDistance(target)<range then ... end
 
I get error p1 is a nil value at inspired:303 when i do ValidTarget check before GetDistance it is working but sometimes i forgot it so to be on safe side add it pls.

  • 0

#51
ilovesona

ilovesona

    Sona's wife

  • Contributor
  • 1,096 posts

 

Can u add a validtarget check to your GetDistance function. Whenever i use 
local target= GetCurrentTarget()
If target~=nil and GetDistance(target)<range then ... end
 
I get error p1 is a nil value at inspired:303 when i do ValidTarget check before GetDistance it is working but sometimes i forgot it so to be on safe side add it pls.

 

it's not good idea, sometimes we don't need that validTarget...I mean it check too much thing


  • 0

#52
Tiritto

Tiritto

    Script Developer

  • Members
  • 377 posts
  • LocationPoland

 

Can u add a validtarget check to your GetDistance function. Whenever i use 
local target= GetCurrentTarget()
If target~=nil and GetDistance(target)<range then ... end
 
I get error p1 is a nil value at inspired:303 when i do ValidTarget check before GetDistance it is working but sometimes i forgot it so to be on safe side add it pls.

 

Big nope. GetDistance() is used not only to measure the distance between units but also between blank spots on the map so ValidTarget() would just break those measurements since there's no target. If you're using this kind of "if statement" often in your code then just consider creating function.

function IsTargetInRange(unit)

  -- Check if >unit< value is given
  if unit == nil then
    local target = GetCurrentTarget()
  else
    local target = unit;
  end;

  -- Check if target exists
  if target == nil then
    return false;
  end;

  -- Check if enemy is in hero range
  target = GetOrigin(target);
  local hero = GetOrigin(myHero);
  if GetDistance(target,hero) < range then
    return true;
  end;

  -- If function wasn't successful at this point, it'll never be so return false.
  return false;
end;

Then just use the following syntax:

if IsTargetInRange() then process(); end; -- With GetCurrentTarget().
if IsTargetInRange(GetCurrentTarget()) then process(); end; -- Same as above.
if IsTargetInRange(enemy) then process(); end; -- This time using specific enemy unit.

  • 0

#53
ilovesona

ilovesona

    Sona's wife

  • Contributor
  • 1,096 posts

 

Big nope. GetDistance() is used not only to measure the distance between units but also between blank spots on the map so ValidTarget() would just break those measurements since there's no target. If you're using this kind of "if statement" often in your code then just consider creating function.

function IsTargetInRange(unit)

  -- Check if >unit< value is given
  if unit == nil then
    local target = GetCurrentTarget()
  else
    local target = unit;
  end;

  -- Check if target exists
  if target == nil then
    return false;
  end;

  -- Check if enemy is in hero range
  target = GetOrigin(target);
  local hero = GetOrigin(myHero);
  if GetDistance(target,hero) < range then
    return true;
  end;

  -- If function wasn't successful at this point, it'll never be so return false.
  return false;
end;

Then just use the following syntax:

if IsTargetInRange() then process(); end; -- With GetCurrentTarget().
if IsTargetInRange(GetCurrentTarget()) then process(); end; -- Same as above.
if IsTargetInRange(enemy) then process(); end; -- This time using specific enemy unit.

it doesn't work...you still not check target, target~=nil is not enough


  • 0

#54
Maxxxel

Maxxxel

    The One

  • Scripts Developer
  • 1,087 posts
  • LocationGuess the right City to win 10$

Well he could also add a check in GetDistanceSqr where the error appears for a nil easily then cuz the error only appears with 303: p1.x is a nil value




function GetDistanceSqr(p1,p2)
  p2 = p2 or GetMyHeroPos()
  p1= p1 or nil
  If (p1 and p2)~=nil then 
    local dx = p1.x - p2.x
    local dz = (p1.z or p1.y) - (p2.z or p2.y)
    return dx*dx + dz*dz
  end
edd

  • 0

#55
ilovesona

ilovesona

    Sona's wife

  • Contributor
  • 1,096 posts

 

Well he could also add a check in GetDistance for a nil easily then..

function GetDistance(p1,p2)
  If (p1 and p2)~=nil then
    p1 = GetOrigin(p1) or p1
    p2 = GetOrigin(p2) or p2
    return math.sqrt(GetDistanceSqr(p1,p2))
  end
end

ya, and the error will show it happen in your script instead inspired one, seems legit Kappa


  • 0

#56
arsoitee

arsoitee

    Member

  • Members
  • 20 posts

it error every champion , I don't know why cause it work normally until 2 hr. ago

 

 

0error.jpg


  • 0

#57
arsoitee

arsoitee

    Member

  • Members
  • 20 posts

error all champs  8bhGG1.png

 

edit: working inspired

 Can you tell me how to solve problem ?

Thank you


  • 0

#58
8tpank

8tpank

    Newbie

  • Members
  • 9 posts

Sorry, but too much minion missing 


  • 0

#59
oscarwyt

oscarwyt

    Advanced Member

  • Members
  • 61 posts

 Can you tell me how to solve problem ?

Thank you

same problem here for the IAC


  • 0

#60
juanrenanlol

juanrenanlol

    Member

  • Members
  • 24 posts

 Can you tell me how to solve problem ?

Thank you

I delete deftsu scripts, and updated the inspired and IAC , I am using only the scripts zyppy

deftsu scripts gave errors in my gos , I do not know to use them


  • 0




2 user(s) are reading this topic

0 members, 2 guests, 0 anonymous users