Programming C, C++, Java, PHP, Ruby, Turing, VB
Computer Science Canada 
Programming C, C++, Java, PHP, Ruby, Turing, VB  

Username:   Password: 
 RegisterRegister   
 Hey guys whats up? I really need some help
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
Jacx




PostPosted: Thu Jan 06, 2005 10:23 pm   Post subject: Hey guys whats up? I really need some help

Im making a game where you basically move a circle to a box (Its more complex then that, with obsticles and pictures insteaod of a circle EXC but thats the basic)
In the game, the circle starts in a square area, and you have to move it to the box with keys.
Now the problem im having, is i want it so after you lets say beat level 1.
Level 2 will start, same erything, different area for the obscticle (Which i think I got) But i want to make it so it runs faster, as in your guy moves faster and the timer moves faster, so after every level it gets faster and faster EXC.

How can I do this? I tried a few things but i cant seem to jack the overall speed of the program up after every level, can someone help me out here please?

Also i am a faily experianced flash artist, if anyone who can help me needs any help with their flash ANIMATING skills, then i may be able to help out.


And i dont want plain answers, just like methods of what exactly do you do to speed programs up? Like do you use strings arrays exc
Sponsor
Sponsor
Sponsor
sponsor
Paul




PostPosted: Thu Jan 06, 2005 10:29 pm   Post subject: (No subject)

Well, make your level one in a way with delays and make it efficiently, so it would go a normal/slow speed. To speed the program up, lessen the delays, or increase the increments that each keypress adds to the position of the circle. Plus, if you could post you're code, then we could give you more specific answers. Even maybe how you did it.
w00t




PostPosted: Thu Jan 06, 2005 10:31 pm   Post subject: (No subject)

Hmm..

Heres a thought ..

If you "circle" has a delay.. ie "delay (10)"

code:
drawfillarc (x, y, 20, 20, dir + mouth, dir - mouth, 14)
    if dir = 0 then
        drawfilloval (x + 4, y + 11, 3, 3, 7)
    elsif dir = 90 then
        drawfilloval (x - 11, y + 4, 3, 3, 7)
    elsif dir = 180 then
        drawfilloval (x - 4, y + 11, 3, 3, 7)
    elsif dir = 270 then
        drawfilloval (x + 11, y - 4, 3, 3, 7)
    end if


    >>>>>delay (7) <<<<<<<<<< this is the speed of my guy <

    drawfillarc (x, y, 20, 20, dir + mouth, dir - mouth, 7)


the lowerthe delay the faster the movement,, so very clow is like 15 and super fast is like 2 or 3,

I don't know if this helps much but its an attempt to help yea..

w00t

-[edit]- someone just posted before me so , forgive my repost
Jacx




PostPosted: Thu Jan 06, 2005 10:33 pm   Post subject: (No subject)

Thanks that does help, but is there any way to basically make it so it just gets faster and faster untill you cant do it?

Like i need the timer to speed up with the delays, or should i just decrease the time.

Ill post my coad tommorow, its extremly buggy and not complete right now
w00t




PostPosted: Thu Jan 06, 2005 10:41 pm   Post subject: (No subject)

Hmmm... just a thought but wouldn't this work, if not well it was worth a try..


code:
if "you enter level 2 " then
for decreasing a : 9 .. 7 %% drops delay to 7
delay (10 + a )
end for
end if


** throw this into the program i submitted above

this should work, i dont have turing at the moment so i wouldn't know.. but give it a try and see what happens...

w00t
Tony




PostPosted: Fri Jan 07, 2005 8:46 pm   Post subject: (No subject)

Jacx: you got two options..

ether decrease the delay time (which I recommend) and/or move by more pixels per frame (which you could do if your delay has decreased to 0 but you still want to speed up)
Jacx




PostPosted: Fri Jan 07, 2005 9:30 pm   Post subject: (No subject)

Is there a way to increase the speed of the timer?

Because thats my main prblem right now, should i just make it less time or is there a way to make the countdown timer go down faster?
Tuxedo




PostPosted: Sat Jan 08, 2005 4:04 pm   Post subject: (No subject)

All those would work but if you are using whatdotcolor to see if you have entered the end box to go to the next level and increased the amount of pixels each move would it not be alot harder and even impossible at soem point to get the point specified to touch?

It really matters your code and the size of everything but at somepoint it would jump of the exit and out of the screen...if you have a border...
Sponsor
Sponsor
Sponsor
sponsor
Display posts from previous:   
   Index -> Programming, Turing -> Turing Help
View previous topic Tell A FriendPrintable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 8 Posts ]
Jump to:   


Style:  
Search: