Geyser.Label:setClickCallback send a table when the second arg is not given

Post Reply
ecloud
Posts: 15
Joined: Sat May 02, 2020 11:46 am

Geyser.Label:setClickCallback send a table when the second arg is not given

Post by ecloud »

My function is like: bot.start(name, botloop)
I call it from a Geyser.Label like: JB1:setClickCallback(UI.jobbar.c[1], UI.jobbar.arg[1])
So that means the name is UI.jobbar.arg[1], while the botloop should be nil because it's not given.
But there is a table sent to the function bot.start as the second arg:

Code: Select all

{
  y = 17,
  x = 12,
  globalX = 1302,
  buttons = {
    "LeftButton"
  },
  button = "LeftButton",
  globalY = 447
}

User avatar
demonnic
Posts: 884
Joined: Sat Dec 05, 2009 3:19 pm

Re: Geyser.Label:setClickCallback send a table when the second arg is not given

Post by demonnic »

Yes, that is sent with every click callback. https://wiki.mudlet.org/w/Manual:Lua_Fu ... ckCallback has more information

Post Reply