Converting my project to use the v15.0 BETA. Some problems.
Posted: Fri Feb 18, 2011 2:39 pm
I've been upgrading all my projects from XNA 3.1 to XNA 4.0 today and I thought it would be good to update to the latest BETA too.
I've stumbled across a couple of problems and would be grateful for some advice.
1) entity.Tag is now 'string' instead of 'object', why is this? I can no longer store classes in the Tag property
2) How do I get the entities from 'INarrowPhasePair'?
I would like to assign material properties to a pair when they are created:
3) How do I find a list of entities that intersect with a shape?
Using:
gives me a list of collision entries but I would like a list of entities instead, if possible.
Thank you.
I've stumbled across a couple of problems and would be grateful for some advice.
1) entity.Tag is now 'string' instead of 'object', why is this? I can no longer store classes in the Tag property

2) How do I get the entities from 'INarrowPhasePair'?
I would like to assign material properties to a pair when they are created:
Code: Select all
private void Events_CreatingPair(EntityCollisionInformation info, CollisionEntry entry, INarrowPhasePair pair)
3) How do I find a list of entities that intersect with a shape?
Using:
Code: Select all
IList<CollisionEntry> entities = Resources.GetCollisionEntryList();
game.Space.BroadPhase.QueryAccelerator.GetEntries(sphereOfInfluence, entities);
Thank you.