[BugFix | Feature] EndObject change, first frame fix for collision groups & PyAPI

Hi everyone,

tristan73 just submitted a patch (pending commit) to add the following features / fixes

  • EndObject will now activate objects that were sleeping and colliding with the removed object. This means that, unlike now, if a rigid body starts sleeping on top of another object, when the latter is removed the rigid body will activate and fall, rather than float midair as before.
  • Collision groups that do not intersect used to collide on the first frame. Now this has been fixed so that they collide appropriately.
  • A Python API for the collision group / mask has been added (KX_GameObject.collisionGroup & KX_GameObject.collisionMask)
  • The maximum number of collision groups and masked has been increased from eight to sixteen. This means that the max value of collisionGroup/Mask is (2 ** 16) - 1

Thanks to tristan73 for his work!

I’ve been looking at the recent BGE development that has been going on, and the regularity is making me more confident that the group that was put together a few months ago can actually pull off the major task of bringing the BGE out of the doldrums and make it a good quality FOSS solution for game development again.

I didn’t think this type of revival for the BGE was even possible considering the bad situation that the engine was in, I guess it’s actually happening. :eek:

Nice! work Tristan!

off topic
I had a few ideas for exploiting currently implimented code.

the collision contact point system… can it be made to select the closeset contact point?
this data is then sent to the sensor data instead of a callback?

this would allow collision, radar and near sensors to return a hitpoint right?

I have been waiting for the api for the collisions group/mask from some time, good to see It has been committed!

And, other two commits from today:
BGE: New Draw debug shadow box for sun lamp [FEATURE]
BGE: Fix T43536 logic.getCurrentScene() returning wrong scene in pre_draw and… [FIX]

Actually, I made a mistake, it’s now been committed! The patch that you refer to is the scene draw callbacks :slight_smile:

I tested debug box for shadows and it’s a very nice feature. Thanks Panzergame (Tristan)! I would like to test the last patch but I have some errors during compilation with VS 2013…edit: sorry it was my fault. (I forgot to make a git bisect reset). And thanks agoose77 for the news!

(Panzergame made a complete particle system for the BGE few month ago but without GUI… I hope this feature will be added in the future when it will have an interface…!) :slight_smile: