lua-users home
lua-l archive

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


Can you provide a short example script that shows what you want to be
able to?

It doesn't have to be proper lua, just something that shows what you are
trying to achieve.

> Thanks for you help, I really appreciate it, my only question 
> now is I need to call a function everyframe to update a dudes 
> position or state (every frame or every 5 or whatever).  Not 
> sure how I would do this with this example below.  How would 
> it tie in with my player class etc.  I don't want to really 
> expose a whole players class (from lua), nothing if I can 
> help it. I want the scripts to be really high level, so 
> anyone could write scripts for it.  I don't want to write the 
> scripts myself, I want to set them up, and hand them off to 
> some else who doesn't have much knowledge of programming (if 
> need be).  So I don't really want it to look like c++, or c 
> (lua does resemble it), just they way one would think 
> enemyclose(), runforcover(), seekhealth(), findescort(), etc 
> etc, and I expose those functions to lua.  If I load this 
> main.lua it will parse the whole thing, and stall my app, I 
> call it from my initfunction of my game, where is before, I 
> called a function to update a guy from c++, everyframe, and 
> returned true when it finished the function .. his goals.
> 
> 
> Thanks,
>