Jewel Rush - quasi-Boulder Dash clone
Moderator: Admin
Thanks for the feedback! If by softscrolling you mean smooth scrolling, then yes, this is something I'm still trying to do, the currently implementation is... unstable. I'll tinker the offset before scrolling begins as well.CWS wrote:Your game is really nice! Only one thing: Could you please use softscrolling and only scroll the playfield as soon as the player is nearing a border? The scrolling you are using now is really hurting my eyes!
Thanks again!
Richard Moss
Jewel Rush - http://binaryrealms.co.uk/jewel-rush
How is your implementation of the scrolling? Are you using a timebased movement or delay values? A timebased movement is the better choice!
The implementation is not very complicated: Scrolling starts when the player gets close to the screen border and ends, when the player is "centered" again. The scrolling speed can always remain the same. But for the smooth scrolling issue, it shouldn't make any difference if the scrolling speed is constant or variable.
The implementation is not very complicated: Scrolling starts when the player gets close to the screen border and ends, when the player is "centered" again. The scrolling speed can always remain the same. But for the smooth scrolling issue, it shouldn't make any difference if the scrolling speed is constant or variable.
It's time based - back when I last wrote games in DOS I used to rely on machine speed and basically use delays but that wouldn't work with the variety of hardware available today (probably didn't back then, but it was OK on all the 286 machines I had access to!). Everything in my engine is time based so that in theory it should run the same on all machines. Unless their system clocks are dodgy I supposesubotai wrote:How is your implementation of the scrolling? Are you using a timebased movement or delay values? A timebased movement is the better choice!
The implementation is not very complicated: Scrolling starts when the player gets close to the screen border and ends, when the player is "centered" again. The scrolling speed can always remain the same. But for the smooth scrolling issue, it shouldn't make any difference if the scrolling speed is constant or variable.
I'm actually updating on one of the test projects I did for ensuring various aspects of my engine work to properly test scrolling without the game itself getting in my way. However, when checking how I implemented smooth scrolling tonight I've see that I did it in a very silly way, although in fairness I was missing a piece of the puzzle when I did that first draft and forgot to go back to it. Still, it's wrong. And games are supposed to be fun to play, not eye strain inducing!
The good news is that it should be quite simple to correct (I think it involves deleting a large swath of code and replacing it with one, maybe two lines ). Perhaps a little more complicated that that as I haven't implemented the way you describe (ie continuing to scroll until back in the center), but it can't be that complicated!
Thanks for the comments, helpful as always!
Jewel Rush - http://binaryrealms.co.uk/jewel-rush
Well, I'm just asking, because if you are using OpenGL in combination with timebased movement, smooth scrolling should be no problem. O.k., I'm using Dephi, but OpenGL remains OpenGL. Here is my implementation:rjm wrote:It's time based - back when I last wrote games in DOS I used to rely on machine speed and basically use delays but that wouldn't work with the variety of hardware available today (probably didn't back then, but it was OK on all the 286 machines I had access to!).
Code: Select all
IF QPC_Old=-1 then
QueryPerformanceCounter(QPC_Old) else
QPC_Old:=QPC_New;
...
//Scrolling:
CoordX:=CoordX+ScrollSpeed*TimeFactor //Scroll to the right
...
Render;
...
QueryPerformanceFrequency(QPC_Freq);
QueryPerformanceCounter(QPC_New);
TimeFactor := (QPC_New-QPC_Old) / QPC_Freq;
The scrolling routine was also much more complicated in my old implementation.rjm wrote:Perhaps a little more complicated that that as I haven't implemented the way you describe (ie continuing to scroll until back in the center), but it can't be that complicated!
You're welcome. I try my bestrjm wrote:Thanks for the comments, helpful as always!