I think it would be handy to have a collision flag for entities.
something like..
g_Entity[e]['collision'] = 0
g_Entity[e]['collision'] = 1
g_PlayerCollision = 0
g_PlayerCollision = 1
Say if an entity collides with another entity, then both would report back 1.
I'm working on a pickup and carry script and it would be good to have feedback to know when two or more entities have collided so you can script to drop the object instead of the entity going through walls, etc.
The collision flag would work from the entities collision boxes around it. So if two or more collision boxes hit each other, then it reports.
It would also be good to use it as an event flag, say if a car hits a wall or another car, you could trigger a sound effect or animation, etc.
I think you would want it to report 1 for a collision even if the entities have their collision turned off.
Ill keep with the car theme, picture a finish line beam / ribbon across a track and when the car passes through the ribbon (which would have its collision turned off) it would report back 1 once the car passed through it, and so would the car.
There are lots of different ways you could use a flag like this.
It should even work with the player collision box, and maybe a collision flag for the player as well, like g_PlayerCollision.
But you wouldn't want it to report collision with the terrain.
Cheers
Desktop: Intel(R) Core(TM) i7-4790 CPU @ 3.60GHz (8 CPUs), ~3.6GHz, Windows 8.1 64-bit, 16 GB Ram, NVIDIA GeForce GTX 750 Ti, Display Memory: 4018 MB. Resolution 1360x768, Passmark 3528.
Laptop: Pavilion dv6 Notebook, Intel(R) Core(TM) i5-2410M CPU @ 2.30 GHz, Win 7 64 bit, 16 GB Ram, Radeon (TM) HD 6490M, 2336 MB Memory. Resolution 1366x768, Intel(R) HD Graphics 3000. (WEI 5.8)