Page 2 of 2

Re: Lua and C++

Posted: Sat May 09, 2009 12:06 pm
by hellknight
M_D_K wrote:
hellknight wrote:ohhh damn....i was thinking to it throwing something....my bad.......
(me->remeberCstyleCoding()....ok now i m good :P.)
just saw something very strange...(P.S. i m new to lua...so help me out plz :P)

if the source lua file is ok,only then it gets executed.(and i thought interpreters work one line at a time....nvr md me)
......so how does that api actually work?.......does the lua file get converted to a compiled code first or it is just interpreted on fly? and if it happens on the fly,then how can it know that the source lua file is "bad"? is it possible to modify the lua source file during run time?

(just saw the video where falco created that lua debug window..and was wondering how he did it........my guess was to create a lua file (empty if possible). make it call every frame during the "heart beat" (as falco says).then use a saprate thread to modify its content (yeah i know syncronisation problem :P),but will it work?

(P.S i have this annoying problem of putting "....." during chating ,forums etc.....dont mind me)
dude its called luaL_dostring. Sorry Falco you've no longer got the edge :lol:
..lol....i was wayyyy off.... XD