Results 1 to 2 of 2

Thread: Error line 12

  1. #1
    Normal User
    Join Date
    Feb 2012
    Posts
    32
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quoted
    0 Post(s)
    Reputation
    10
    Rep Power
    5

    Error line 12

    Why giving this error?



    Code:
    local msgs = getnewmessages("Local chat")
    local qtd = msgs.count-1
    local player = Tile.GetByPosition(posx-2, posy, posz):TopCreature():Name()
    for i=0,qtd
    do
        if msgs[i].text:find(player..'(.+): low') then
    Line 12 is: if msgs[i].text:find(player..'(.+): low') then

    Thanks.

  2. #2
    iBot User pink_panther's Avatar
    Join Date
    May 2012
    Location
    Australia
    Posts
    4,075
    Mentioned
    49 Post(s)
    Tagged
    1 Thread(s)
    Quoted
    178 Post(s)
    Reputation
    309
    Rep Power
    10
    The problem is this line:

    local player = Tile.GetByPosition(posx-2, posy, posz):TopCreature():Name()

    it's not returning anything.
    Last edited by pink_panther; 12-09-2013 at 11:41 PM.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •