Please Can someone help me on my project!!! =)
Author |
Message |
Xravens04
|
Posted: Tue Apr 08, 2008 5:39 pm Post subject: Please Can someone help me on my project!!! =) |
|
|
I have a final project and im stuck on how to make my soccer guy move and kick the soccer ball off the screen then anouther screen apears with a soccer net and the ball goes in the net.
Can someone help me on my project, it would be greatly appreciated
Description: |
|
![](http://compsci.ca/v3/pafiledb/images/icons/clip.gif) Download |
Filename: |
Animation Soccer Project 2.t |
Filesize: |
2.41 KB |
Downloaded: |
100 Time(s) |
|
|
|
|
|
![](images/spacer.gif) |
Sponsor Sponsor
![Sponsor Sponsor](templates/subSilver/images/ranks/stars_rank5.gif)
|
|
![](images/spacer.gif) |
BigBear
|
Posted: Tue Apr 08, 2008 5:42 pm Post subject: Re: Please Can someone help me on my project!!! =) |
|
|
Do you mean automatically by only using delay? or by input from the user?
|
|
|
|
|
![](images/spacer.gif) |
X2_star
|
Posted: Tue Apr 08, 2008 5:42 pm Post subject: RE:Please Can someone help me on my project!!! =) |
|
|
Lol trevor
|
|
|
|
|
![](images/spacer.gif) |
Xravens04
|
Posted: Tue Apr 08, 2008 5:57 pm Post subject: Re: Please Can someone help me on my project!!! =) |
|
|
TEll you the truth i dont really know, i need to make my guy move to kick the soccer ball, then make the soccer ball go off the screen then i need a new screen with a soccer net and the soccer ball appears in the net. =)
|
|
|
|
|
![](images/spacer.gif) |
riveryu
![](http://compsci.ca/v3/uploads/user_avatars/196991102647ae2debe0bf0.jpg)
|
Posted: Tue Apr 08, 2008 9:34 pm Post subject: Re: Please Can someone help me on my project!!! =) |
|
|
u need to learn to clear screen, loops and exit whens, use variables for your animation. You should already know this....
What does your teacher expect? Have you learned if and thens yet?
Turing: |
var x : int := 100
var y : int := 100
var x1 : int := 200
var y1 : int := 200
loop
exit when x >= maxx or y1 >= maxy or x1 >= maxx %this checks if the center of the oval is at a certain point, if it is at that point it will exit the loop
cls %this is clear screen, it makes the screen blank everytime it loops, try it when you dont have this
drawfilloval (x,y, 20, 20, black)
drawfilloval (x1,y1, 20, 20, red)
x: = x + 1 %x is increased by 1 every time it loops
x1: = x1 + 1
y1: = y1+ 1
delay(5) % this is delay, which means that there will be a 5 millisecond pause every time it loops
end loop
|
|
|
|
|
|
![](images/spacer.gif) |
jinjin
|
Posted: Wed Apr 09, 2008 12:17 am Post subject: Re: Please Can someone help me on my project!!! =) |
|
|
riveryu is correct. If you also want to remove flashing put
code: | setscreen ("offscreenonly") |
at the beginning of the program (before vars) and you would also need a turing procedure inside the loop that would "update the view."
|
|
|
|
|
![](images/spacer.gif) |
Xravens04
|
Posted: Wed Apr 09, 2008 6:52 am Post subject: RE:Please Can someone help me on my project!!! =) |
|
|
yah, my teacher, good one, no my teacher hasn't teached us nothing about how to move stuff lol
|
|
|
|
|
![](images/spacer.gif) |
|
|