Open GoogleCodeExporter opened 9 years ago
I dislike Approach #2 since it makes the code more complicated and harder to
understand/extend. Also due to steps the addition of many multiplication
operations will be necessary which will further reduce performance gains.
Approach #1 seems more sensible to me.
Of the problems listed I only consider the changed "feel" of motion/controls to
experienced players a real problem.
The other 2 problems listed (moving further into objects and different
explosion locations for fast gears) could be fixed or at least lessened into
insignificance I believe
(by adding adjustments and position restore to collision detection and by
creating an additional MakeExplosion routine specifically for moving gear that
will cause an explosion at a past position depending on dx/dy and negative
timer value offset)
Original comment by sheepyluva
on 30 Nov 2011 at 5:05
Well #1 will involve changing a lot of code, but it is a one-time cost. Later,
yes, new additions would just use the new rules.
Other things impacted by #1 are I guess anything that checks GameTicks - value
of GameTick is assumed to increment 1 at a time, so it would probably be
appropriate to keep doing that, just w/ 50 or 100ms granularity. So pretty
much anything that does a test on GameTicks should be considered as well.
Oh. Also, given the alterations to physics, probably 100ms would be safer. 50ms
might be too much.
One additional point w/ #1. Game just has the one sleep. So, while #2 keeps
sleeps as low as possible still, #1 would obviously change that. This impacts
max FPS. Probably another reason to stick w/ more conservative 100ms if
picking #1.
Original comment by kyberneticist@gmail.com
on 30 Nov 2011 at 5:15
Hm. WRT step thing. Dunno. People seem to have adapted ok w/ visual gears.
Also inlineable helper functions could be added (quadratic for velocity, or
maybe even iterative + function pointer).
Overall impact on maintainability for #2 might not be high, and the performance
gains more configurable.
But. Hey. Dunno. That's why I thought I'd get ideas. Heck. There might be
other options too.
Original comment by kyberneticist@gmail.com
on 30 Nov 2011 at 5:19
WRT math in #2, if we had fixed step intervals, we could possibly also use
approximations that are close enough, based on testing.
Constant values to avoid math. That would be similar to #1, but w/ a bit more
granularity/flexibility.
Original comment by kyberneticist@gmail.com
on 30 Nov 2011 at 7:16
Just a small remark about collisions: with despeckling there's no chance for
1-2 px width line, so collision checks could probably stay as they are. On the
other hand, object could get stuck in solid land penetrating it deeply.
Original comment by unC0Rr
on 21 Dec 2011 at 8:04
despeckling only cleans up damaged land, so thin lines on existing map surfaces
are preserved. also, current despeckling would preserve a 2px thick line of
damaged land, so long as sweeps did not examine end pixels. Damaged pixels in
the middle of the line would have 5 neighbours, over the 3 neighbour threshold.
An isolated block of 4 damaged pixels is of course cleaned up. Also
despeckling ignores "indestructible" terrain even if it was flagged damaged.
So, I think considering collision impact is still warranted.
Original comment by kyberneticist@gmail.com
on 27 Dec 2011 at 6:54
So, I think the rope was instructive.
The stickiness was, and probably still is, a bit problematic.
On the plus side, the rope was probably the worst of the bunch.
Original comment by kyberneticist@gmail.com
on 25 Aug 2012 at 2:46
Original issue reported on code.google.com by
kyberneticist@gmail.com
on 30 Nov 2011 at 4:27