Night Effects Slow down game.

Non-platform specific questions.

Night Effects Slow down game.

Postby Rux » Wed Jun 04, 2008 1:22 am

In my game it will read your clock, and depending on what time it is a black transparent block makes it night time. But it always slows down the game a lot! No matter what. Is there away to simulate night effects without the slowdown?
I'm not good at coming up with signatures...
User avatar
Rux
 
Posts: 645
Joined: Sun Apr 29, 2007 9:26 pm
Location: Sitting on your moniter invisable.
Score: 35 Give a positive score

Re: Night Effects Slow down game.

Postby DST » Wed Jun 04, 2008 2:32 am

Any fullscreen transparency will kill your fps, for the most part. It does slightly depend on how much of a hue/brightness change occurs, (white wispy clouds aren't too bad) but black...that's a 100% shift from the current values. The best way is to dim the rgb of some components, and have a different animation for background.
Taking the background out of the transparency equation will help a LOT.

I'd down the red and green by maybe 50 or 80 pts, and the blue by only half that, since moonlight often appears blue (even though its not). Your main character and powerups don't really need dimmed.

Sometimes you can get away with transparency, i dunno....what res are you using? In my 640x480 game, a red overlay flashes when you get hit, then fades out in about 1/3 of a second. When this happens, my cpu goes from its idle or active speeds of 12-50% up to 94%. This isn't optimal, but it didn't max the cpu, so i can handle it. Run your task manager in the background, with the game in a window so you can see the cpu. If your game idles at more than 20%, and is active at more than 60%, then transparency isn't your biggest issue.....
It's easier to be clever than it is to be kind.
http://www.lostsynapse.com
http://www.dstgames.com
User avatar
DST
 
Posts: 1117
Joined: Sun Apr 15, 2007 5:36 pm
Location: 20 minutes into the future
Score: 151 Give a positive score

Re: Night Effects Slow down game.

Postby Rux » Wed Jun 04, 2008 3:50 pm

ok.... wow that a lot of animation changes..... :? I'll try
I'm not good at coming up with signatures...
User avatar
Rux
 
Posts: 645
Joined: Sun Apr 29, 2007 9:26 pm
Location: Sitting on your moniter invisable.
Score: 35 Give a positive score

Re: Night Effects Slow down game.

Postby DST » Wed Jun 04, 2008 9:05 pm

well see if you can use rgb first, that would be much easier...
It's easier to be clever than it is to be kind.
http://www.lostsynapse.com
http://www.dstgames.com
User avatar
DST
 
Posts: 1117
Joined: Sun Apr 15, 2007 5:36 pm
Location: 20 minutes into the future
Score: 151 Give a positive score

Re: Night Effects Slow down game.

Postby Zivouhr » Sat Aug 02, 2014 9:44 pm

DST wrote:Any fullscreen transparency will kill your fps, for the most part. It does slightly depend on how much of a hue/brightness change occurs, (white wispy clouds aren't too bad) but black...that's a 100% shift from the current values. The best way is to dim the rgb of some components, and have a different animation for background.
Taking the background out of the transparency equation will help a LOT.

I'd down the red and green by maybe 50 or 80 pts, and the blue by only half that, since moonlight often appears blue (even though its not). Your main character and powerups don't really need dimmed.

Sometimes you can get away with transparency, i dunno....what res are you using? In my 640x480 game, a red overlay flashes when you get hit, then fades out in about 1/3 of a second. When this happens, my cpu goes from its idle or active speeds of 12-50% up to 94%. This isn't optimal, but it didn't max the cpu, so i can handle it. Run your task manager in the background, with the game in a window so you can see the cpu. If your game idles at more than 20%, and is active at more than 60%, then transparency isn't your biggest issue.....


Interesting. Thanks.
I'll have to check the CPU monitor while playing my game as it included a day/night cycle, though I'll see if that affects the speed, as so far I think it's likely the fact the game is 100 MB that would affect the top speed. The game speed is where I want it, though it's adjusted to compensate for the giant game.
City of Rott Game created on Game Editor http://cityofrott.wordpress.com/
User avatar
Zivouhr
 
Posts: 549
Joined: Sat May 17, 2014 2:12 pm
Score: 59 Give a positive score


Return to General

Who is online

Users browsing this forum: No registered users and 1 guest

cron