Ignore:
Timestamp:
2013-07-26 12:24:17 (6 years ago)
Author:
totakahe
Message:

Talletus.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • 2013/30/TomiH/pong1/pong1/pong1/pong1.cs

    r4620 r4732  
    99public class pong1 : PhysicsGame 
    1010{ 
     11 
     12    private Animation miesa; 
    1113    Vector nopeusYlos = new Vector(0, 1000); 
    1214    Vector nopeusAlas = new Vector(0, -1000); 
    1315    Image tarja = LoadImage("tarja"); 
    1416    PhysicsObject pallo; 
    15  
     17    Image dog = LoadImage("blingbling1.0"); 
    1618     
    1719     
     
    2729    public override void Begin() 
    2830    { 
    29          
     31 
     32        miesa = LoadAnimation("blingbling"); 
    3033        LuoKentta(); 
    3134        AsetaOhjaimet(); 
     
    4144    { 
    4245        pallo = new PhysicsObject(100.0, 100.0); 
    43         pallo.Image = tarja; 
    44         pallo.Shape = Shape.FromImage(tarja); 
     46        // pallo.Image = tarja; 
     47        pallo.Shape = Shape.FromImage(dog); 
    4548        // pallo.Color = Color.Emerald; 
    4649        pallo.X = -100; 
    4750        pallo.Y = 100; 
    4851        pallo.Restitution = 100; 
     52        pallo.Animation = miesa; 
     53        pallo.Animation.Start(); 
     54        pallo.Animation.FPS = 3; 
    4955        Add(pallo); 
    5056 
     
    6874        alaReuna.IsVisible = true; 
    6975 
    70         Level.BackgroundColor = Color.Black; 
     76        Level.BackgroundColor = Color.Red; 
    7177        AddCollisionHandler(pallo, KasittelePallonTormays); 
    7278    } 
Note: See TracChangeset for help on using the changeset viewer.