Changeset 2706 for 2012/JAO


Ignore:
Timestamp:
2012-04-17 09:39:28 (8 years ago)
Author:
anonymous
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • 2012/JAO/Tero/Pong/Pong/Pong/Pong.cs

    r2700 r2706  
    1111    Vector nopeusYlos = new Vector(0, 200); 
    1212    Vector nopeusAlas = new Vector(0, -200); 
     13 
     14    Vector impulssi = new Vector(500.0, 0.0); 
    1315 
    1416    PhysicsObject pallo; 
     
    9597        pallo.Restitution = 1.0; 
    9698        pallo.KineticFriction = 0.0; 
    97         pallo.MomentOfInertia = Double.PositiveInfinity; 
    9899        Add( pallo ); 
    99100        AddCollisionHandler(pallo, KasittelePallonTormays); 
     
    131132            pelaajan1Pisteet.Value += 1; 
    132133            Timer.SingleShot(0.5, AloitaPeli); 
     134            impulssi = new Vector(500.0, 0.0); 
    133135        } 
    134136        else if (kohde == vasenReuna) 
     
    136138            pelaajan2Pisteet.Value += 1; 
    137139            Timer.SingleShot(0.5, AloitaPeli); 
     140            impulssi = new Vector(-500.0, 0.0); 
    138141        } 
    139142    } 
     
    144147        pallo.Y = 0.0; 
    145148        pallo.Stop(); 
    146         Vector impulssi = new Vector( 500.0, 0.0 ); 
     149 
    147150        pallo.Hit( impulssi ); 
    148151     
Note: See TracChangeset for help on using the changeset viewer.