2,034 reputation
1223
bio website
location
age
visits member for 3 years, 9 months
seen 12 hours ago

Mar
28
awarded  Good Answer
Mar
19
reviewed Approve suggested edit on Android AndEngine creating a body behind the sprite exactly
Jan
13
awarded  Custodian
Jan
13
reviewed Reject suggested edit on Bezier Curves for visual programming node connectors
Jan
13
reviewed Reject suggested edit on Bezier Curves for visual programming node connectors
Jul
14
awarded  Yearling
Jun
18
awarded  Caucus
Jun
18
awarded  Constituent
Apr
12
awarded  Informed
Dec
28
comment Why does this collision detection & resolution code only work for one side?
Your parentheses are unbalanced, and you incorporated the height into the bottom check, not the top check. Additionally the comparison operators are reversed on your top and bottom checks. Also, I was only assuming that your "position" origin is the top-left of the entity; it's up to you to verify that is the case. I strongly recommend sitting down with a piece of graph paper and a pencil and stepping through your code in your head.
Dec
25
comment Why does this collision detection & resolution code only work for one side?
@Fiona It would be a good idea to use e.g. a const variable to give a name to your magic width and height numbers, especially since you will need to use them in more than one place to fix this problem: you have the right idea for the response, but the detection test also needs to be edited similarly. Hint: "if ((x + 5) > tileBounds.Left)" ...
Dec
25
revised Why does this collision detection & resolution code only work for one side?
deleted 247 characters in body
Dec
25
answered Why does this collision detection & resolution code only work for one side?
Dec
19
awarded  Good Answer
Oct
11
comment Best C++ Portable time library for game development
I agree that timing is of critical importance, but I think it's disingenuous to conflate timing with the game loop. He's not asking for a game loop, which is what the article you linked is really about. It's perfectly reasonable to want to defer to a tested timing implementation, given how extremely thorny the issues can be in practice (see my answer for details).
Oct
11
answered Best C++ Portable time library for game development
Sep
24
awarded  Good Answer
Jul
23
revised What are some good resources for learning HLSL?
grammar'd!!
Jul
14
awarded  Yearling
Jun
19
comment Unity: Spin wheels to move vehicle
If you're sure you want to keep going with simple cylinders, try using a hinge joint to attach the wheels to the chassis: unity3d.com/support/documentation/ScriptReference/…