|
Post by Adam Schmelzle on Apr 15, 2007 20:41:49 GMT -5
I finally got my arbitrarily-scrolling-in-2D-using-1-backBuffer system finished. I probably would have had it done a few days ago, but I hadn't had the time to work on it much over the last little while. Just in case the technically minded would like to know: My system does NOT require tiles. I mean to say, that If I want a scrolling background, I don't need it to be made of tiles; it can be generated in real time pixel-by-pixel if needed. Of course it would run quicker using a reasonable tile size. I just did some tests, and was able to scroll a real-time generated image of 1x1 rectangles at a minimum of 26fps on my phone. Just go ahead and try scrolling a tiled background in full unrestricted 2d movement with 1x1 tiles and see what kind of performance you can get. That was the worst thing I could throw at it. Nobody will ever REALLY want to have a tile size of 1x1. The best part is that the slower you scroll, the faster the framerate, so if I actually scroll that background slowly, I can maintain a hefty framerate with no trouble at all. So basically I now get almost FREE background / map scrolling with almost no hit to the game performance. You guys have no idea how good it feels to get this working. ;D ;D ;D
|
|
|
Post by damo666 on Apr 16, 2007 11:08:45 GMT -5
Bravo 26fps is ridiculously fast, do you have a test jar so we can see what you have done?
|
|
|
Post by Adam Schmelzle on Apr 16, 2007 14:37:02 GMT -5
I suppose I could post one. The performance will of course vary greatly from phone to phone. Also, I have moved on to using it in my "baox" game, so if I spit out a test, the scrolling speeds will be different from my previous testing.
|
|
|
Post by Adam Schmelzle on Apr 16, 2007 16:14:38 GMT -5
3-IN-1 gradient test... JAD : attackgames.game-host.org/3IN1/3IN1.jadJAR : attackgames.game-host.org/3IN1/3IN1.jarAlternatively, you can point your phone at: attackgames.game-host.org/3IN1 to download directly to your phone. I have it trying to go at a very fast scrolling speed. This WILL slow down if you hold the direction key for a while. It accellerates as you hold a direction. You can see the cursor that it is moving to center on. If you tap the cursor over, you see that the framerate stays reasonable. This all depends on your phone's processing/drawing power. If you have a big-screen with low-power graphics, it'll likely be really slow. Framerate is in the bottom-left corner. It only shows the framerate when it changes, so if you sit still for a while it'll likely go away.
|
|
|
Post by gnasher1001 on Apr 17, 2007 11:31:13 GMT -5
Whatever all that means, it sounds good, so well done! I got 90+fps stationary, 33fps straight motion, and 18fps diagonal. it was all very smooth, I presume that was the point?
|
|
|
Post by Adam Schmelzle on Apr 17, 2007 12:06:30 GMT -5
Yup, that's the point. Keeping it smooth shouldn't be a problem at all in a real game. This is more of a benchmark for the worst-case scenario.
|
|
|
Post by gnasher1001 on Apr 17, 2007 13:02:57 GMT -5
So would this engine/algorithm mean a scrollable map if you were making AC2 now rather than earlier?
|
|
|
Post by Adam Schmelzle on Apr 17, 2007 14:09:50 GMT -5
Yes indeed. This would make the map scroll faster than the game plays.
|
|
|
Post by Adam Schmelzle on Apr 18, 2007 10:18:57 GMT -5
I have now started to prepare for adding the multiplayer portion of the game.
I was originally planning on only making it compatible with newer phones, but am wavering on that decision now. These games don't really need any kind of real-time communication, so I might just make it compatible with older phones anyway.
This will cause a bit of an annoyance on my more modern phone. My Samsung SPH-A920 is rather stupid. It ALWAYS asks permission when you make a network connection, even when you tell it to "Always Allow". I don't know how many other people have this kind of problem, but it's the main thing I wanted to avoid.
If I go the "new-phones" route, I can create a single connection and keep it open for the whole game. That way it only asks once for the buggy phones that ignore your "Always Allow" choice.
To support older phones, I'll need to use http connections, which have to be re-established every time I want to send/retrieve data. Which is also the same thing I do for the online scoring.
If I get REALLY ambitious, I'll implement both. Though, I don't see that happening. If I do implement it both ways, maybe I'll add bluetooth as well.
I won't have much time to work on this stuff today, gotta run around town. Maybe I'll do it the old and ugly way, then decide if it's worth the effort adding special support for newer phones.
|
|
|
Post by Adam Schmelzle on Apr 18, 2007 12:48:46 GMT -5
Yak!
I just tried playing cullufun's chess game online using my Samsung SPH-A920. That was ULTRA painful. Their system works just fine, but the stupid "Allow / dissalow" message EVERY single time it wanted to send/recieve data was wayyyyy too annoying to even get 2 moves into the chess game.
I guess I'll have to implement the socket based multiplayer if I'm gonna test with this stupid phone. I can't believe how annoying that was.
|
|
|
Post by Adam Schmelzle on Apr 18, 2007 13:06:58 GMT -5
That's kinda cool. I can resume the game whenever I want to. I got an e-mail from cellufun's system telling me that I have 24 hours to make my next move in the chess game. Unfortunately there is no way to send a message to the other person. I just wanted to appologize, since I won't be continuing that game.
Hmm. Is this a feature that you guys would want? Not the e-mail thing, but being able to continue the game whenever. Do we want an auto-loss for disconnections?
I think they have that feature, 'cause chess is much more of a 'thinker' than the ones I'm gonna do. Chess can take hours, but I can't see the 'box-game' taking more than 10 minutes. Same goes for 'SOS', and 'connect-4'
Would people want to have a bunch of in-progress games going that they could switch between during play? Maybe have 3 or 4 games going at a time, so that if you are taking some time thinking about a move, you won't be stopping your opponent from playing other people. I think this could be a cool feature. If you have 4 games going, then all you'd need is an on-screen indicator that "game 2 has made their move!", and / or a small "1,2,3,4" with the numbers colored representing who's turn it is... I love this idea! You could be playing 10 games at once, and NOBODY will complain about you taking too long! You don't even have to play all the same game. You could have 3 'box-game's 2 'SOS' and 5 'connect-4's going all at once.
Even it it's a slow day, you'd likely always have somebody to play agains, 'cause everyone could play against 5 other people!
I think that would be AWSOME. Anyone else?
|
|
|
Post by Adam Schmelzle on Apr 18, 2007 14:48:49 GMT -5
I have been thinking about the ranks a little. How about if you get disconnected, and you are losing by a large margin, you get an automatic loss. If it's close (+/-25%), the person still playing will have the option of 'forgiving' the opponent for being disconnected. If forgiven, the disconnected player will NOT recieve a loss on his/her record.
|
|
|
Post by gnasher1001 on Apr 19, 2007 16:00:44 GMT -5
Disconnects - maybe not a 24hr limit, maybe a real short time to reconnect? 10mins or so? Multiple games would be cool I bet all your ideas will be good, you seem to have a talent for noticing annoying aspects of other games and ridding them from yours The forgiving thing sounds an excellent idea, Xbox live counts disconnects as a loss and I HATE that!
|
|
|
Post by Adam Schmelzle on Apr 19, 2007 16:20:31 GMT -5
Maybe only 5 minutes. I think with something like connect 4 or the box game, if you don't get back to the game within 5 minutes, you are not likely coming back. This will allow people going through tunnels, and elevators a chance to keep playing, without the opponent waiting too long.
Yeah, I never liked getting a loss because of an accidental disconnect. I just hope that my server keeps up.
|
|