AngelScript 2.21.2 released
A new version is ready for download.
I've changed how the script engine works with return values in order to reduce the amount of dynamic memory allocations. A value type that is returned by value is now allocated on the script stack, rather than on the dynamic memory heap.
In my own game engine, this change has reduced the number of memory allocations that are done from the script engine on a frame by frame basis to zero. New allocations are only done when a new game object is spawned. Hopefully others should see similar improvements in their own projects.
Another significant improvement is to the support for native calling conventions on 64bit Linux and Mac OS X. The ABI on these platforms is very complex as structures can be passed around in different registers based on the type of each member. One particular problem was POD structures that didn't implement the copy constructor or destructor, e.g. 3D vector types, which is a very common type. I've solved it by allowing the application to inform whether the structure should be treated as if all members are integers or floats/doubles, with the flags asOBJ_APP_CLASS_ALLINTS and asOBJ_APP_CLASS_ALLFLOATS. This obviously doesn't cover all possible combinations, but should cover the most common ones.
In this release I also implemented a sample game that gives a more complex example of how AngelScript can be integrated in a game engine. The same game shows how I do it in my own game engine, but it is just one way of doing it. Perhaps in a future release I'll implement some other ways too. And finally I'd like to thank Thomas Grip for the contribution of support for metadata on class members in the CScriptBuilder add-on.
Regards,
Andreas
AngelCode.com - game development and more - Reference DB - game developer references
AngelScript - free scripting library - BMFont - free bitmap font generator - Tower - free puzzle game
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement
Recommended Tutorials
Advertisement