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

Username:   Password: 
 RegisterRegister   
 Kinda like Hit Detection
Index -> Programming, Turing -> Turing Submissions
View previous topic Printable versionDownload TopicRate TopicSubscribe to this topicPrivate MessagesRefresh page View next topic
Author Message
upthescale




PostPosted: Sat Mar 25, 2006 10:37 pm   Post subject: Kinda like Hit Detection

click on the circle and place it in the box


code:

var x, y, button, x2, y2, button2 : int
loop
    drawbox (300, 400, 536, 56, 7)
    drawfilloval (140, 312, 12, 12, 34)
    %drawfillbox (128, 300, 152, 325, 7)
    mousewhere (x, y, button)
    if x > 128 and x < 152 and y > 300 and y < 325 and button = 1 then
        cls
        exit
    end if
end loop
loop
    drawbox (300, 400, 536, 56, 7)
    mousewhere (x2, y2, button2)
    drawfilloval (x2, y2, 12, 12, 34)
    delay (30)
    drawfilloval (x2, y2, 12, 12, 0)
    if buttonmoved ("up") then
        exit
    end if
end loop
drawfilloval (x2, y2, 12, 12, 34)
if x2 >= 300 and x2 <= 536 and y2 > 56 and y2 < 400 then
 put "good"
end if
Sponsor
Sponsor
Sponsor
sponsor
person




PostPosted: Sat Mar 25, 2006 10:41 pm   Post subject: (No subject)

No offense, but what is this tutorial supposed to teach?
Next time, please explain your tutorial.
Delos




PostPosted: Sun Mar 26, 2006 10:13 am   Post subject: (No subject)

Moved to [Turing Source]. No relevance to [Turing Tutorials].
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  [ 3 Posts ]
Jump to:   


Style:  
Search: