[Date Prev][Date Next][Thread Prev][Thread Next]
- Subject: RE: Game entity scripting strategies?
- From: "Vincent Penquerc'h" <Vincent.Penquerch@...>
- Date: Tue, 12 Aug 2003 10:54:46 +0100
> And several entities use this script file, so I create a new
> copy of this table for each of them. I'll probably be
> generating names for these new tables based on entity ID or
> something like that, so now I have the following tables:
My solution is to have each scriptable entity create (from C) a table,
and call a Lua initialization routine with this new table as a parameter.
This function looks like:
-- and so on, you have a lot of predefined responses in global
-- functions which you then assign to various table.<foo>