In before version its work:
Code:
local HUDText = HUD.CreateTextDisplay(100, 100, "", 255, 120, 120)
local HUDItem = HUD.CreateItemDisplay(100, 120, 1781, 48, 100)
local countFile = assert(io.open("C:\\Users\\ht\\Desktop\\stones.txt", "r"))
while (true) do
if(countFile ~= Self.ItemCount(1781)) then
local file = io.open("C:\\Users\\ht\\Desktop\\stones.txt", "w")
file:write(Self.ItemCount(1781))
file:flush()
file:close()
end
HUDText:SetText("Stones: " .. Self.ItemCount(1781) .. " left ")
wait(1000)
end
On v3.0 i see this error msg:
15:56 XenoScript Error:
Script: stones.lua
Line #: 1
Chunk: ...\Documents\XenoBot\Scripts\stones.lua
Error: attempt to call field 'CreateTextDisplay' (a nil value)
This is an error with user-input and should not be reported as a bug with XenoBot.