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

Username:   Password: 
 RegisterRegister   
 need some help with garage opening and...
Index -> Programming, Turing -> Turing Help
View previous topic Printable versionDownload TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
dani190




PostPosted: Sat Dec 17, 2005 1:41 pm   Post subject: need some help with garage opening and...

code:


setscreen ("graphics:max,max,offscreenonly")



colorback (black)
cls





var v : int
var u : int
var c : int
var count : int
var g : int
var k : int
var countx, county : int
var x1, y1 : int
var a, b : int
var x2, y2 : int
a := 420
b := 50
c := black
countx := 10
county := 7
x2 := 1300
y2 := 600



loop
    var h : array 1 .. 4 of int := init (150, 400, 270, 10) %Roof
    var d : array 1 .. 4 of int := init (250, 250, 400, 10) %Roof


    g := 1300
    k := 400

    Draw.FillBox (150, 50, 400, 250, brightred)     %house box
    Draw.FillBox (401, 50, 620, 160, brightgreen)   %Garage
    Draw.FillBox (420, 50, 601, 140, brightblue)    %Garage Door

    Draw.FillBox (350, 140, 300, 170, grey)         %house window Right side
    Draw.FillBox (200, 140, 250, 170, grey)         %house window Left side
    Draw.FillBox (1800, 1, 1, 50, green)            %Grass in front
    Draw.FillBox (250, 110, 200, 50, grey)          %Door
    drawfillbox (205, 250, 250, 400, red)           %Chiminy

    Draw.FillBox (a, b, 601, 50, black) %Garage part2
    Draw.FillPolygon (h, d, 3, 1) %Roof of house
    a := a
    b := b + 5

    exit when b > 140
    View.Update
    delay (150)

    cls
    colorback (c)
    drawfilloval (g, k, 20, 20, yellow)





end loop

loop
    var h : array 1 .. 4 of int := init (150, 400, 270, 10) %Roof
    var d : array 1 .. 4 of int := init (250, 250, 400, 10) %Roof
    Draw.FillBox (150, 50, 400, 250, brightred)      %house box
    Draw.FillBox (401, 50, 620, 160, brightgreen)   %Garage
    Draw.FillBox (420, 50, 601, 140, brightblue)    %Garage Door

    Draw.FillBox (350, 140, 300, 170, grey)         %house window Right side
    Draw.FillBox (200, 140, 250, 170, grey)         %house window Left side
    Draw.FillBox (1800, 1, 1, 50, green)            %Grass in front
    Draw.FillBox (250, 110, 200, 50, grey)          %Door
    drawfillbox (205, 250, 250, 400, red)           %Chiminy

    Draw.FillBox (a, b, 601, 50, black)             %Garage part2
    Draw.FillPolygon (h, d, 3, 1)                   %Roof of house

    View.Update
    delay (10)       %Controls how fast sun moves!
    colorback (c)

    cls


    drawfilloval (x2, y2, 20, 20, white)
    exit when x2 = 0
    x2 := x2 - countx
    y2 := y2 - county
    if y2 > 500 then
        county := 0
        if x2 < 300 then
            county := +10


            if x2 > 1 then
                colourback (brightblue)
            else
                colourback (black)
         


            end if
        end if
    end if
end loop



ok so this is my code...
i need some help on how to get that garage door to close again
then i need help on getting that whole scean to play again after the first 1 is done but with a blue background (so day time)
Hope you can help
Thanks
Sponsor
Sponsor
Sponsor
sponsor
Cervantes




PostPosted: Sat Dec 17, 2005 3:30 pm   Post subject: (No subject)

This looks to be very similar to this thread. You still have not incorporated for loops. You said you would stop spamming; now, instead of posting "plz help" in your thread, you just start a new, essentially the same, thread. You've made seven threads about this in the past few days. You had better have a compelling reason for doing this. "My project is due on Monday" is not a compelling reason, just so you know.
dani190




PostPosted: Sat Dec 17, 2005 3:32 pm   Post subject: (No subject)

you know what i wanted some help and nobody ever helpd with it iv tried the codes and stuff you guys have been giving me and they dont help, so i dont even care any more like seriously
you guys are too strict i suddgest cool it, but w.e not like i want any more help i probably wont even get any
Cervantes




PostPosted: Sat Dec 17, 2005 3:40 pm   Post subject: (No subject)

Who's to say you haven't got help? You've got plenty of help, you just won't take it. So you create more threads hoping to get other people to help you, hoping that they will throw working code at you. Too bad you've ticked people off by trying this too many times.
dani190




PostPosted: Sat Dec 17, 2005 3:57 pm   Post subject: (No subject)

well will you stop being so f***ing mean i just got it. for your info iv been working since last night till about 4 pm now so over 6 hours so dont say i want code dont dare say that Exclamation
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  [ 5 Posts ]
Jump to:   


Style:  
Search: