IPB

Welcome Guest ( Log In | Register )


> Production Anim Slowdown Bug
Bittah Commander
post Aug 8 2009, 05:20 PM
Post #1


Forum Administrator
Group Icon

Group: Administrators
Posts: 1,340
Joined: 1-October 06
From: The Netherlands
Member No.: 5
Alliance: GDI
Favorite game: Tiberian Sun



For many players the production animation (gclock2.shp) causes the game to slow down when you build something cheap (apparently for some people this even slows the game down to an unbearable frame rate). I just ran a quick test and gave the clock animation fewer frames (17 instead of 55); as I expected it now doesn't slow the game at all anymore while playing on the 'Faster' gamespeed (gamespeed 5) and when playing with the fastest gamespeed, it only slowed the game down to about the rate of gamespeed 5 for a very short time (meaning this wouldn't be noticeable online).

While this could be a "sort-of fix", it'll obvoiusly look a bit odd when building more expensive things... So I was wondering whether it'd either be possible to find a way to keep the normal gclock2.shp anim from lagging the game or make it somehow drop frames when building cheaper buildings.


--------------------
Go to the top of the page
 
: | +Quote Post
 
Start new topic
Replies
SeekSomethingNew
post Aug 11 2009, 11:52 AM
Post #2

Stealth Tank
Group Icon

Group: Members
Posts: 1,025
Joined: 31-October 06
Member No.: 208
Alliance: GDI
Favorite game: Tiberian Sun



QUOTE (Lin Kuei Ominae @ Aug 11 2009, 10:29 AM) *
My assumption is, that for every tick the gclock2.shp is drawn on the built building, the darken.shp is drawn on every other building. Since TS has by default no hardware acceleration and transparent anims (like gasclouds) can cause lags ingame too, i assume that drawing in a short time 55 times a transparent layer on all cameos is too much for the engine.

And your tests have shown, that minimizing the transparent drawing work for the engine, reduces the lag what supports this assumption.

That's why i think the only way to fix this would be a code optimization, but i'm not sure if Hyper can go that deep in the code.
e.g.
-draw darken.shp only once on all visible cameos in the sidemenu when the construction has started
-update cameos with the darken.shp which appear in the sidemenu after scrolling upwards/downwards (and only those new cameos)
-when construction is finished, update all cameos to show the non-darked cameo again.
-adjust the number of shown frames from gclock2.shp concerning the cost and buildspeed of the current building
(100 Credits building shows only 4 frames
1000 Credits building shows half the frames
2000 Credits building shows all frames)

Im gonna just hit on one line you said, "That's why i think the only way to fix this would be a code optimization, but i'm not sure if Hyper can go that deep in the code." Correctomondo, this is something you modders are gonna have to fix until i fully undersand how SHP drawing actualy works.

Though people have said that the "RA2" DDRAW.DLL seems to stop this...


--------------------
Go to the top of the page
 
: | +Quote Post

Posts in this topic
- Bittah Commander   Production Anim Slowdown Bug   Aug 8 2009, 05:20 PM
- - CCHyper   This is a strange little bug that no one has yet b...   Aug 10 2009, 12:50 PM
|- - ^Rampastein   QUOTE (CCHyper @ Aug 10 2009, 03:50 PM) T...   Aug 10 2009, 05:03 PM
- - CCHyper   QUOTE (^Rampastein @ Aug 10 2009, 06:03 P...   Aug 10 2009, 05:57 PM
- - Tore   This is the bug that has prevented me from playing...   Aug 10 2009, 07:39 PM
- - Bittah Commander   Seems VK is right... Darken.shp really is the main...   Aug 10 2009, 07:52 PM
|- - ^Rampastein   Thanks Bittah.. fixed the problem entirely for me ...   Aug 11 2009, 07:39 AM
|- - Lin Kuei Ominae   My assumption is, that for every tick the gclock2....   Aug 11 2009, 09:29 AM
|- - ^Rampastein   QUOTE (CCHyper @ Aug 11 2009, 02:52 PM) T...   Aug 11 2009, 02:39 PM
- - Tore   I still experience slowdowns, the ddraw.dll gives ...   Aug 11 2009, 08:52 PM
- - Bittah Commander   Well, tbh the slowdown you experience seems to be ...   Aug 12 2009, 01:32 AM
- - CCHyper   So this is still something i have to take note of?   Aug 24 2009, 10:51 PM
- - Kakashi   I too have lag problems but not only when i constr...   Nov 30 2009, 11:48 AM
- - Styx221   Yup, like all build lag fixes ive tried it fixes i...   Apr 27 2010, 03:55 PM
|- - ^Rampastein   QUOTE (Styx221 @ Apr 27 2010, 06:55 PM) -...   Apr 27 2010, 04:27 PM
|- - Lin Kuei Ominae   @Styx221 Thanks for the detailed info. Seems like ...   Apr 28 2010, 10:32 AM
- - Devastator   I only had slowdowns when I had the ole' Ultim...   Apr 28 2010, 09:19 PM


Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 

Lo-Fi Version Time is now: 2nd July 2025 - 10:30 PM


XGhozt.com