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

Username:   Password: 
 RegisterRegister   
 planet thingy
Index -> Programming, Turing -> Turing Submissions
View previous topic Printable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
MihaiG




PostPosted: Mon Jun 20, 2005 5:20 pm   Post subject: planet thingy

no reaql gravity just orbity "some" help from cerv.... Twisted Evil

code:

setscreen ("graphics:max;max")
View.Set ("offscreenonly")
var x0, y0 : int := 500
var x1, x2, x3, y1, y2, y3 : int := 100
var r1 : int := 300
var r2 : int := 100
var r3 : int := 60
loop
    for i : 1 .. 360
        cls
        y1 := round (y0 + r1 * sind (i))
        x1 := round (x0 + r1 * cosd (i))
        y2 := round (y1 + r2 * sind (i * sqrt (r2)))
        x2 := round (x1 + r2 * cosd (i * sqrt (r2)))
        y3 := round (y2 + r3 * sind (i * sqrt (r3 * 5)))
        x3 := round (x2 + r3 * cosd (i * sqrt (r3 * 5)))
        Draw.FillOval (x0, y0, 100, 100, yellow)
        Draw.FillOval (x1, y1, 25, 25, blue)
        Draw.FillOval (x2, y2, 10, 10, darkgrey)
        Draw.FillOval (x3, y3, 5, 5, grey)
        View.Update
        delay (10)
    end for
end loop


i shall now rule the world! Arrow Question
Sponsor
Sponsor
Sponsor
sponsor
Display posts from previous:   
   Index -> Programming, Turing -> Turing Submissions
View previous topic Tell A FriendPrintable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic

Page 1 of 1  [ 1 Posts ]
Jump to:   


Style:  
Search: