From: Chad A. <ae...@ae...> - 2002-01-11 15:58:12
|
> well i guess i'd rather have a more lightweight system. however, i don't > particularly think it's worth our time writing bindings for various > languages. however ... if you think we can do it with some fancy template > meta-programming or reuse existing code out there that does binding to > various languages, then i say go for it. Eh? I'm confused by your statement "I don't think it's worth our time writing bindings". How else will we get scriptability? > now, i'm not familiar with doing scripting, but i would probably want to > use the scripting engine along the following lines (ignoring error > condidions): > > ScriptEngineFactory* factory = ScriptEngineFactory::getInstance(); > IScriptEngine* se = factory->create( "python" ); > se->execute( "myPythonFunction()" ); > > my point above is that i wouldn't necesarily want to have to define my > functions before i can call them. i would hope that the scripting engine > would be smart enough to be able to call the correct python function > without me having to define it first. perhaps it would be up to the > particular scripting engine to define the functions. How do you call a function if it isn't defined? If you have native functions that you want to reflect into a particular scripting language, you have to tell it that those functions exist. > or better yet, maybe we could dynamically load "plugins" that define > functions in an arbitrary language. when loaded, they would register the > funtions/classes they provide with the apropriate scripting engine. then > when i use the scripting engine using code similar to above. This requires features of a full component system, afaik. For example, being able to understand interfaces at run-time. > please, check in your ideas and UML diagrams ... i'd love to take a look > at them and comment on them! I'll do that. isugamedev/lib/scribe |