Log in

View Full Version : Error message in .lua script. Please help!



eriksson1994
07-18-2012, 12:19 PM
I have recivede this error message:

13:53 XenoScript Error:
Script: MistrockGround_StusseDezzie.lua
Line #: 29
Chunk: ...ents?XenoBot?Scripts?MistrockGround_StusseDezzi e.lua
Error: 'luaGetWeaponSlotData' called with invalid number of arguments [1 supplied, 0 required]!
This is an error with user-input and should not be reported as a bug with XenoBot.

I've tried to understand what's wrong but haven't figured it out. It's the .lua script that bugs and makes it unable to bot. So if anyone could just check it out for me I would be very pleased. The script is this one: http://forums.xenobot.net/showthread.php?2288-_____Stusse-amp-Dezzie-%A9-Script-Thread-_____&p=28308&viewfull=1#post28308

Kind Regards
Yours Eriksson

DarkstaR
07-18-2012, 12:35 PM
An argument is being passed when you need to have an empty parameter list. Please paste line 29 of the code for more help.

eriksson1994
07-18-2012, 12:38 PM
28. elseif (labelName == "check2") then
29. if (Self:Weapon().count < SpearsToHunt) then
30. gotoLabel("forgott")

Here you go, and thanks in advance!

Kind Regards
Yours Eriksson

DarkstaR
07-18-2012, 12:47 PM
Self.Weapon().count
not Self:Weapon().count

eriksson1994
07-18-2012, 12:54 PM
Okey I'll fix that immediate, thank you!

Kind Regards
Yours Eriksson