christianclavet wrote:How angelscript is binded? Can we create for example a function and expose it to angelscript so we can create a script that would do something with a specific entity? (example a trigger object).
You might have noticed that nearly each class implementation is followed by the implementation of a function called bind<class name>. These functions are responsible for binding the respective class to AngelScript. The functions self are called when the ScriptManager class is initialised. So, if you would want to bind custom classes, you could use a similar pattern.
Binding global functions shouldn't be a problem either. That can be done through AngelScript's API:
Code: Select all
r = engine->RegisterGlobalFunction("void foo()", asFUNCTION(foo), asCALL_CDECL); assert( r >= 0 );
I should add that it's currently only possible to create event functions natively. The reason for this is that AngelScript doesn't support function pointers (yet). There is a work around for this problem, though. The solution didn't make it into v0.1.0 as I wasn't sure if anyone would use it. If you need it, though, feel free to ask.
christianclavet wrote:Is there a MSVC++ port of this or is it Linux only at the moment?
No, Sirrf is absolutely not Linux only. FuzzYspo0N actually already compiled it with MSVC. So, if you need pre-configured MSVC project files, you could ask him.
Alternatively you could use CMake to generate the appropriate MSVC project files:
Code: Select all
cmake -G"Visual Studio 9 2008" -D CMAKE_BUILD_TYPE=Debug ../../src
or
cmake -G"Visual Studio 9 2008" -D CMAKE_BUILD_TYPE=Release ../../src
More information about project file generators can be found in the
CMake documentation.
christianclavet wrote:Also another question, is there anything needed in the download or we must download other component so the compilation work.
You'll need to download Irrlicht SVN, AngelScript 2.16.2 and SFML-1.5. Refer to
this page for more information regarding dependencies. Again, if you need help, feel free to ask.
christianclavet wrote:The more I look on this, the more i'm interested to use it. Good job!
I'm glad to hear that.
![Smile :)](./images/smilies/icon_smile.gif)