• Announcements

    • khawk

      Download the Game Design and Indie Game Marketing Freebook   07/19/17

      GameDev.net and CRC Press have teamed up to bring a free ebook of content curated from top titles published by CRC Press. The freebook, Practices of Game Design & Indie Game Marketing, includes chapters from The Art of Game Design: A Book of Lenses, A Practical Guide to Indie Game Marketing, and An Architectural Approach to Level Design. The GameDev.net FreeBook is relevant to game designers, developers, and those interested in learning more about the challenges in game development. We know game development can be a tough discipline and business, so we picked several chapters from CRC Press titles that we thought would be of interest to you, the GameDev.net audience, in your journey to design, develop, and market your next game. The free ebook is available through CRC Press by clicking here. The Curated Books The Art of Game Design: A Book of Lenses, Second Edition, by Jesse Schell Presents 100+ sets of questions, or different lenses, for viewing a game’s design, encompassing diverse fields such as psychology, architecture, music, film, software engineering, theme park design, mathematics, anthropology, and more. Written by one of the world's top game designers, this book describes the deepest and most fundamental principles of game design, demonstrating how tactics used in board, card, and athletic games also work in video games. It provides practical instruction on creating world-class games that will be played again and again. View it here. A Practical Guide to Indie Game Marketing, by Joel Dreskin Marketing is an essential but too frequently overlooked or minimized component of the release plan for indie games. A Practical Guide to Indie Game Marketing provides you with the tools needed to build visibility and sell your indie games. With special focus on those developers with small budgets and limited staff and resources, this book is packed with tangible recommendations and techniques that you can put to use immediately. As a seasoned professional of the indie game arena, author Joel Dreskin gives you insight into practical, real-world experiences of marketing numerous successful games and also provides stories of the failures. View it here. An Architectural Approach to Level Design This is one of the first books to integrate architectural and spatial design theory with the field of level design. The book presents architectural techniques and theories for level designers to use in their own work. It connects architecture and level design in different ways that address the practical elements of how designers construct space and the experiential elements of how and why humans interact with this space. Throughout the text, readers learn skills for spatial layout, evoking emotion through gamespaces, and creating better levels through architectural theory. View it here. Learn more and download the ebook by clicking here. Did you know? GameDev.net and CRC Press also recently teamed up to bring GDNet+ Members up to a 20% discount on all CRC Press books. Learn more about this and other benefits here.

BClarenbach

Members
  • Content count

    11
  • Joined

  • Last visited

Community Reputation

130 Neutral

About BClarenbach

  • Rank
    Member
  1. * CScriptBuilder::AddSectionFromMemory() now requires a name and an optional length for the buffer in case it is not null terminated (Thanks Paril101)   was a dangerous change because it swaps the order of parameters but because of the new default parameter, its not obvious when you update. :)
  2. Thanks, NOCOUNT did what I wanted. I know the lifetime of both objects and scripts, so there is no danger of dangling references
  3. Hi, I have a couple of objects that I currently introduce as single reference types into the scripting environment. This is because they are in-place allocated in a special memory manager. They obviously do not have any ref counting behaviours, either. Now the management class only handles base pointers to the class hierarchy. I would like to create casting behaviours in AS now so that I can safely cast the types up and down the hierarchy. I am not able to register the type casting like it is documented in the Class Hierarchies chapter of the manual. Returning by value is obviously wrong, returning by @ is equally wrong since there is no ref counting. Returning by & returns an error when I try to register the type cast. Any ideas or hints on what I could also do? Thanks!
  4. Never mind, forgot to switch the type registration from value back to scoped. .. .
  5. Hi, I tried to implement your wrapper idea but it seems that the type registration does not allow @ modifiers when using scoped types. [source lang="bash"]Object handle is not supported for this type Failed in call to function 'RegisterObjectMethod' with 'vector' and 'vector @opAdd(const vector &in) const' (Code: -10)[/source] Any ideas? The signature of the wrapper is like you mentioned in your post. Thanks for the help!
  6. With modern SIMD architectures, we're looking mostly at 4 and 16 byte alignments. If AS would provide those two, my guesstimate is that almost everyone is happy. If your class needs 8 bytes alignment, you are probably happy with 16 byte alignments, too. If your class needs alignments over 16 bytes, you are most likely ok to allocate the memory in a different location and wrap the access. (e.g. 4k pages etc.) If an align16 object flag is reasonably easy to implement, that would be fabulous. Right now, I had to switch to unaligned reads for my simd types which makes the bridge between native and scripted code somewhat cumbersome. No, I am not going to do performance relevant math operations in scripts but passing values in and out of registered functions that use an equivalent math class like we have in the native code makes it easier to read and maintain.
  7. The problem appears to be amazingly similar to http://www.gamedev.net/topic/507813-operator-addsubmultiplydivide-with-scoped-types/
  8. I've run into a problem with the scoped reference type. I have the following registration call: [source lang="cpp"] r = _engine->RegisterObjectMethod("vector", "vector &opAdd(const vector &in) const", asMETHODPR(Vector, operator+, (const Vector &) const, Vector), asCALL_THISCALL); [/source] and this binds to a class method of class Vector that is declared like this: [source lang="cpp"] Vector operator+( const Vector& _rhs ) const; [/source] There seems to be no way to declare the method in a working fashion. If I leave the reference out in the angelscript type, I cannot register the method. If I remove the reference on the c++ side, I hit a road block because it is 16 bytes aligned and value parameters do not work with alignment restrictions. If I use both the way they are, I get a 0-pointer on the _rhs parameter. Any ideas on how to work around this? Thanks! ps.: I dug up the old post so you knew the troubles I had with declaring vector a scoped reference and why I did it.
  9. I turned it into a scoped reference type for now. Seems to work ok so far.
  10. Hi, I need a 16 byte alignment on certain value types to accurately mirror value classes we pass into our interface. I've tried overloading the memory allocator but that does not seem to work, I still get unaligned addresses for value types created by AngelScript. I noticed there is an 8 byte alignment flag, but that does not seem to do anything at all. Could you point me to where I can modify this and turn the 8byte into a functional 16 byte alignment flag? Thanks!
  11. Hi, I have a usage scenario for AngelScript and would like to ask if that is possible at all and what the best way to do it is: I believe I have the easy steps figured out (but am open to suggestions): - I register a set of interfaces with the scripting engine so the scripts can interact with my systems - The scripts are going to be script classes that implement a set of event methods set by a specific interface (like onUpdate or onSetup) - Although many different instances of those script classes exist, only one of the event methods run at a time. - The system loads presets that reference script code. I would ideally have this script code in binary form when I load it. The hard part would be: - During developement of the presets, I would ideally be able to unload the script class definition for one preset and reload it with the updated code. The main problem is that there will most likely be 300-400 of those presets active at one time, and only a hand full share the same script class so only those would need reloading. I traced AddScriptSection for a bit and found that although it uses a string table and index for the naming, the index itself is not really used and sections with the same name would be added more than once. I also found no way to unload a section, either. Thanks for helping!