PtokaX forum

Development Section => LUA & PtokaX-Scripting-Interface => Topic started by: bluebear on 15 October, 2005, 22:40:27

Title: Lua Extension: Console Debug window for Ptokax
Post by: bluebear on 15 October, 2005, 22:40:27
hey again peeps...

I coded a console window for ptokax.
So you can output string data to the console,
this is very usefull when debuging scripts.

Screenshot + download + info here: http://www.thewildplace.dk/lua/pxdbgc/ (http://www.thewildplace.dk/lua/pxdbgc/)

Enjoy,
bluebear
Title:
Post by: Markitos on 16 October, 2005, 09:18:44
I didn't understand this part
print("Counting from 0 to 90000...\n")
    i = 0
    while i <= 90000 do
        print("\b\b\b\b\b", i)
        i = i + 1
    end
    print("\n")

Why does it have to count to 90000 and in this time the hub says connection refused by target machine?


Respectfully
Title:
Post by: bluebear on 16 October, 2005, 11:35:26
QuoteOriginally posted by Markitos
I didn't understand this part
print("Counting from 0 to 90000...\n")
    i = 0
    while i <= 90000 do
        print("\b\b\b\b\b", i)
        i = i + 1
    end
    print("\n")

Why does it have to count to 90000 and in this time the hub says connection refused by target machine?


Respectfully

Ahh, it has no purpose at all, other then showing how
do a count in console.

debugconsole.lua is only a test script that shows how to use the PxDbgC.dll.

If you'r a scripter, and need debug output when writeing you'r scripts. You can use the debugconsole.lua too see how you can implement it into a debug phase of your script.

//Bluebear
Title:
Post by: bluebear on 16 October, 2005, 11:37:17
btw. PxDbgC.dll should only be used for developing. And should not be used in released scripts.
Title:
Post by: bastya_elvtars on 16 October, 2005, 12:51:35
This should be compiled into PxLUA.dll. ;)
Title:
Post by: plop on 16 October, 2005, 16:17:09
the way it should be used.
if tSql._Debug then
libinit = loadlib("libs\\PxDbgC.dll", "_libinit")
libinit()
end

plop
Title:
Post by: Markitos on 16 October, 2005, 19:11:41
QuoteOriginally posted by bluebear
QuoteOriginally posted by Markitos
I didn't understand this part
print("Counting from 0 to 90000...\n")
    i = 0
    while i <= 90000 do
        print("\b\b\b\b\b", i)
        i = i + 1
    end
    print("\n")

Why does it have to count to 90000 and in this time the hub says connection refused by target machine?


Respectfully

Ahh, it has no purpose at all, other then showing how
do a count in console.

debugconsole.lua is only a test script that shows how to use the PxDbgC.dll.

If you'r a scripter, and need debug output when writeing you'r scripts. You can use the debugconsole.lua too see how you can implement it into a debug phase of your script.

//Bluebear
Oh now i understand it...
Title:
Post by: bluebear on 16 October, 2005, 19:26:10
Next version is ready.

Added:
Option to make console always on top.
Output to both console and a file.
messagebox.
some extra print*()

Download/screenshot/info: http://www.thewildplace.dk/lua/pxdbgc/ (http://www.thewildplace.dk/lua/pxdbgc/)

Enjoy,
bluebear