Ignore:
Timestamp:
2010-06-10 11:41:56 (13 years ago)
Author:
rikaroih
Message:
 
File:
1 edited

Legend:

Unmodified
Added
Removed
  • 2010/23/rikaroih/Autopeli1/Peli.cs

    r635 r658  
    88    public class Peli : TopDownPhysicsGame 
    99    { 
     10        SoundEffect taustamusiikki; 
     11         
    1012        Automobile auto; 
    1113        Automobile auto2; 
     
    3638            Level.BackgroundColor = Color.Black; 
    3739            Level.Background.Image = LoadImage("avaruus"); 
     40            taustamusiikki = LoadSoundEffect("taustamusiikki"); 
     41            taustamusiikki.Play(); 
     42 
    3843        } 
    3944 
     
    161166            if ( target.Equals(pallo) || target.Equals(pallo2) || target.Equals(pallo3) || target.Equals(pallo4)) 
    162167            { 
     168                Explosion rajahdys = new Explosion(200); 
     169                rajahdys.Position = auto.Position; 
     170                rajahdys.Force = 100; 
     171                Add(rajahdys); 
     172 
    163173                auto.Destroy(); 
    164174            } 
Note: See TracChangeset for help on using the changeset viewer.