Game Development Reference
In-Depth Information
}
}
}
}
Here, we listen to a collision before its reactions are calculated. If there is a collision
between the cue and white ball, we play a sound effect and we hide the cue.
Note
If you want to force your own logic to the collision reaction and override Box2D on this,
you should do so in the PreSolve method. In this game, however, we could have added
all this collision logic to the BeginContact method and it would work just as well.
Search WWH ::




Custom Search