Jump to content
  • Advertisement

Paradigm Shifter

  • Content Count

  • Joined

  • Last visited

Community Reputation

5832 Excellent

About Paradigm Shifter

  • Rank
  1.   Reflect it in the plane which is normal to the cone axis first then proceed as before. If you are already on that plane add some scaled amount of the cone direction to it.
  2. And if you need to clamp it you can just subtract a vector in direction from the end of the the orientation to the end of the cone axis until the cosine is equal, then renormalise, I believe.
  3. Use an axis and an angle, then check whether the proposed orientation dot axis is within the angle, it's a cone check, if both axes are normalised the dot product will be > cos(angle) if it is within the cone   EDIT: > not <
  4. Paradigm Shifter

    How many of you write self-documenting code?

      And incorrect ;) 0 is not a negative number
  5. Paradigm Shifter

    c++ friend classes

    You would use porsche.Steer(); in the member function PorscheSteer. But Steer is public anyway, so there's no need for it to be a friend to call that function...
  6. Paradigm Shifter

    Barycentric Coordinate Calculation gives divide by zero

    You should remove degenerate triangles from your triangle collision data when you export the data. If you need collision against lines have a separate container for them and do line vs. collision object tests as different functions.
  7. Either only initialise w in the t4dpoint class (base class is then default constructed) or call the base class constructor directly   t4dpoint<_cType>(_cType a, _cType b, _cType c, _cType d) : t3dpoint<_cType>(a, b, c), w(d) {}   should work...   EDIT: Which is what Brother Bob said as well. I'm not sure if my template argument is needed for base class constructor, I have it, Brother Bob does not. One or both of us is correct ;)
  8.   I gave up on Shenmue 2 when I had to do a cut scene every time I walked across a plank to climb a building many times in a row... And I never did get to find out where sailors hang out at night.
  9. Paradigm Shifter

    Health bar graphics instead of text

    It should be width * currentHealth / maxHealth anyway? So if your max is 100 and current is 25 it will be 25/100 = 25% full...
  10. Paradigm Shifter

    A little brain teaser

    Can you do a left shift by using a negative value as right shift amount?
  11. Paradigm Shifter

    Score voting system.

    Upvoting increases your rating by 1 as well, there's a limit of 5 a day of that though?   Maybe you shouldn't get a rating boost for upvoting someone's post at all? (And a rating hit for downvoting?).   EDIT: Well maybe you should still get a rating hit for downvoting to discourage downvote sprees. But as mentioned before people then uprate to cancel that out anyway.   And while the number in itself might not have much value, being one of the top-rated posters might be.
  12. Yes you can use sprites and render them in screen space look for a point sprite or point particle demo to see how to do that.
  13. Paradigm Shifter

    RPG style leveling up in puzzle game

    Heroes of might and magic: clash of heroes was like that. There were different levels against slightly different armies/generals but it was basically same thing over and over. I liked it got it for free with games with gold on Xbox 360 played it to the end.
  14. Paradigm Shifter

    point & Octahedron relationship

    In 2d, shoot a ray out in any direction. If it crosses the lines of the shape an even number of times (0 is even here), you are outside. If it crosses odd number of times you are inside.
  15. Paradigm Shifter

    Maclaurin series for reciprocal function

    The interval of convergence is too small.   Are you using floating point or fixed point, I don't understand what you mean by this: of floating range from 24 bit to like 16 bit.   Using 1/x is going to be a lot more accurate than a (poor) approximation which is what the Taylor Series expansion about 1 will give you. Some functions aren't approximated very well at all by Taylor Series (of which McLaurin series is just a special case), e.g. sqrt(x).   Or you could use the Laurent Series, f(x) = x-1 
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!