Ask a Question related to Macromedia Director Lingo, Design and Development.
-
tevadar webforumsuser@macromedia.com #1
old games play too fast
With the much faster CPUs of today, many of the older games we had developed several years ago are unplayable. Does anyone know how to control this? I took a class several years ago and vaguely remember a command in a moviescript. Something like cpuHogTicks.
What are you guys doing to control this?
Joe
tevadar webforumsuser@macromedia.com Guest
-
Shockwave installed, but cannot play games anywhere?
I tried the "see if your shockwave has successfully installed" page here in the adobe website, and it seems to be working perfectly. However, I am... -
XP restricted accounts cannot play Shockwave games
I have Windows XP SP2. My children have their own accounts in my PC. Their XP accounts are of type 'Restricted user'. My own XP account is... -
New Shockwave Version won't play Games
I get these errors when I try to run 3D Billiards at http://www.shockwave3d.com/: http://www.earthplanet.net/sw_error_1.jpg... -
I cant play shockwave games
When I play a shockwave game it says, Network Error. Please check your internet connection and try again. Also I have tried downloading the software... -
Help me play Shockwave games
When I play a shockwave game it says, connection lost please try again. Or check your internet connection. Also I have tried downloading the software... -
JB #2
Re: old games play too fast
Suitable coding techniques can make the play speed more consistant.
Where you have loops animating objects you might add delay times like
repeat with i = 1 to 20
waitEnd = the milliseconds
sprite(10).locH = i * 10
updateStage
-- avoids accumlated errors with running waitend
waitEnd = waitEnd + 50 -- 20 fps speed
repeat while the milliseconds > waitEnd
end repeat
end repeat
end
Throttling the score tempo setting back can help, in the old days some
people had the bad habit of cranking the tempo setting all the way up
to 60, althought the cpu rendering speed ended up effecting controling
the speed.
JB Guest
-
Dave Mennenoh #3
Re: old games play too fast
The way to control it is to base your movements on time instead of frame. If
you do that then the frame rate is irrelevent. As a quick example - say you
want to move something 500 units in 2 seconds.
This would be your setup:
millIncrement = 500 / 2000.0 --how much to move per timeslice
lastTime = the milliseconds
Then on every frame - such as in an enterFrame:
currentTime = the milliseconds
elapsedTime = currentTime - lastTime
amountToMove = elapsedTime * millIncrement
You would then move your sprite, or object, by amountToMove and then
finally:
lastTime = currentTime
to reset the timer... See?
You just get the amount of time that passes between updates and move your
sprite by that amount of time multiplied by the amount to move per
timeslice. Does that make sense? <shameless plug>It's how I did all of the
animation timing on my xyz*bert game - it doesn't matter if it runs at 20fps
or 80fps, things still take the same amount of time.
[url]http://www.blurredistinction.com/dev/xyzbert.htm[/url] </shameless plug>
PS - I gotta give props to Brian Robbins for his great explanation of this
to me in the first place, which _finally_ made it sink in...
--
Dave
[url]http://www.blurredistinction.com/director[/url]
Dave Mennenoh Guest
-
Andrew Morton #4
Re: old games play too fast
> repeat while the milliseconds > waitEnd
NNNNNOOOOOOOO!!!!!> end repeat
Blocking out everything else with a repeat loop is, in general, a BAD IDEA.
Using updateStage in such a fashion will also break other animations, especially
if they use on prepareFrame.
Andrew
Andrew Morton Guest
-
tevadar webforumsuser@macromedia.com #5
Re: old games play too fast
Thank you gentlemen,
I'll give these a try.
Now all I have to do is dust the cobwebs off of my lingo skills and get to work :)
Much appreciated,
Joe
tevadar webforumsuser@macromedia.com Guest
-
John Dowdell #6
Re: old games play too fast
The framerate in a Director or Flash file is the top limit... frames
will not play faster than what you specify.
If those older movies had a very high framerate, one that they could not
reach on older computers, then they might come closer to executing your
instructions on faster machines, true.
jd
--
John Dowdell, Macromedia Developer Support, San Francisco CA
Search technotes: [url]http://www.macromedia.com/support/search/[/url]
Soapbox column: [url]http://www.macromedia.com/desdev/jd_forum/[/url]
Daily technical diary: [url]http://www.macromedia.com/go/blog_jd[/url]
Offlist mail is trapped by spam-filters... best here, thanks!
John Dowdell Guest



Reply With Quote

