Changeset 5140 for 2014/26/UunoT/Pong


Ignore:
Timestamp:
2014-06-27 10:56:43 (7 years ago)
Author:
uutapper
Message:
 
Location:
2014/26/UunoT/Pong
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • 2014/26/UunoT/Pong/Pong/Pong/Pong.cs

    r5073 r5140  
    99public class Pong : PhysicsGame 
    1010{ 
    11     Vector nopeusYlos = new Vector(0, 200); 
    12     Vector nopeusAlas = new Vector (0, -200); 
     11    Vector nopeusYlos = new Vector(0, 600); 
     12    Vector nopeusAlas = new Vector (0, -600); 
    1313    PhysicsObject pallo; 
    1414    PhysicsObject maila1; 
     
    103103        PhoneBackButton.Listen(ConfirmExit, "Lopeta peli"); 
    104104        Keyboard.Listen(Key.Escape, ButtonState.Pressed, ConfirmExit, "Lopeta peli"); 
    105         Keyboard.Listen(Key.Space, ButtonState.Pressed, PALLOJA, ""); 
     105        Keyboard.Listen(Key.Space, ButtonState.Down, PALLOJA, ""); 
    106106    } 
    107107    void AsetaNopeus(PhysicsObject maila, Vector nopeus) 
     
    171171     void PALLOJA() 
    172172     { 
    173          pallo = new PhysicsObject(40.0, 40.0); 
     173         pallo = new PhysicsObject(0.1, 0.1); 
    174174         Add(pallo); 
    175175         pallo.Shape = RandomGen.SelectOne(Shape.Hexagon, Shape.Star, Shape.Heart); 
    176176         pallo.Color = RandomGen.NextColor(); 
    177          pallo.X = -200.0; 
     177         pallo.X = 0.0; 
    178178         pallo.Y = 0.0; 
    179179         pallo.Hit (RandomGen.NextVector(50,100)); 
     180          
    180181       
    181182          
Note: See TracChangeset for help on using the changeset viewer.