Changeset 3721 for 2012/30


Ignore:
Timestamp:
2012-07-24 14:58:50 (11 years ago)
Author:
juiitamm
Message:

Talletus.

Location:
2012/30/JaniS/Virus Infection/Virus Infection/Virus Infection
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • 2012/30/JaniS/Virus Infection/Virus Infection/Virus Infection/Kentta.txt

    r3707 r3721  
    33 
    44 
    5  
    65########################## 
    7 #...o.####.....#####.M...# 
    8 #.....##...###....##.....# 
    9 #.######.#.....##.######.# 
    10 #........########.#......# 
    11 ##########.....##.#.#.#.## 
    12 #..........###....#......# 
    13 #.#.######.....#########.# 
     6#.................##.....# 
     7#.###..##########.##.M...# 
     8#o.....#........#.##.....# 
     9#.###..#..x.....#.######.# 
     10#...........x...#.#......# 
     11###############.#.#.#.#.## 
     12#.................#......# 
     13#.#.####################.# 
    1414#...####################.# 
    1515#...#....#......#....#...# 
    16 #.#..x......xx......x..#.# 
     16#.#..x.....x........x..#.# 
    1717#...#....#......#....#...# 
    1818########################## 
  • 2012/30/JaniS/Virus Infection/Virus Infection/Virus Infection/Peli.cs

    r3707 r3721  
    1414    Image rajahdysKuva = LoadImage("valo"); 
    1515    Image virustenRajaytys = LoadImage("valo2"); 
    16  
     16    Timer aikaLaskuri; 
    1717    List<PhysicsObject> virukset = new List<PhysicsObject>(); 
    1818 
     
    108108        Ohjaus(); 
    109109        Keyboard.Listen(Key.Enter, ButtonState.Down, AloitaSurAlusta, "Restart"); 
    110          
    111     } 
    112  
    113  
    114         void AloitaPeli() 
     110        LuoAikaLaskuri(); 
     111    } 
     112 
     113    void AloitaPeli() 
    115114        { 
    116115            ClearAll(); 
     
    118117            Ohjaus(); 
    119118            Keyboard.Listen(Key.Enter, ButtonState.Down, AloitaAlusta, "Restart"); 
    120          
    121         } 
    122  
    123         void Lopeta() 
     119            Camera.ZoomToLevel(); 
     120        } 
     121 
     122    void Lopeta() 
    124123        { 
    125124            Exit(); 
     
    144143        Level.BackgroundColor = Color.Black; 
    145144        LuoAikaLaskuri(); 
    146         //Mouse.IsCursorVisible = false; 
    147     } 
     145        Mouse.IsCursorVisible = false; 
     146    } 
     147 
    148148 
    149149    void LuoSurPelaaja(Vector paikka, double leveys, double korkeus) 
     
    169169        Add(palikka); 
    170170    } 
     171 
    171172    void LuoPelaaja(Vector paikka, double leveys, double korkeus) 
    172173    { 
     
    180181 
    181182    } 
     183 
    182184    void LuoVirukset(Vector paikka, double leveys, double korkeus) 
    183185    { 
     
    203205    void LuoMaali(Vector paikka, double leveys, double korkeus) 
    204206    { 
    205         PhysicsObject maali = new PhysicsObject(30, 30); 
     207        PhysicsObject maali = new PhysicsObject(140, 170); 
    206208        maali.Position = paikka; 
    207209        maali.IgnoresCollisionResponse = true; 
    208         maali.Shape = Shape.Circle; 
    209         maali.Color = Color.GreenYellow; 
     210        maali.Shape = Shape.Rectangle; 
     211        maali.Color = Color.ForestGreen; 
    210212        AddCollisionHandler(maali, Maali); 
    211213         
     
    213215 
    214216    } 
    215  
    216217 
    217218 
     
    239240        Keyboard.Listen(Key.Down, ButtonState.Released, PysaytaPelaaja, null, new Vector(0, 0)); 
    240241    } 
     242 
    241243    void PysaytaPelaaja(Vector Zero) 
    242244    { 
     
    244246    } 
    245247 
    246         void Maali(PhysicsObject pelaaja, PhysicsObject maali) 
     248    void Maali(PhysicsObject pelaaja, PhysicsObject maali) 
    247249    { 
    248250        MessageDisplay.Add("Stage Cleared, You Won!"); 
    249251        MessageDisplay.TextColor = Color.Yellow; 
    250252        rajaytaVirukset(); 
    251          
     253        aikaLaskuri.Stop(); 
    252254    } 
    253255     
     
    269271 
    270272            pelaaja.Destroy(); 
     273             
    271274        } 
    272275    } 
     
    274277    void LuoAikaLaskuri() 
    275278    { 
    276         Timer aikaLaskuri = new Timer(); 
     279        aikaLaskuri = new Timer(); 
    277280        aikaLaskuri.Interval = 1; 
    278281        aikaLaskuri.Start(); 
    279282        //aikaLaskuri.Trigger += AikaLoppui; 
    280  
     283         
     284         
    281285        Label aikaNaytto = new Label(); 
    282         aikaNaytto.TextColor = Color.White; 
    283         aikaNaytto.DecimalPlaces = 1; 
     286        aikaNaytto.TextColor = Color.Yellow; 
     287        aikaNaytto.DecimalPlaces = 2; 
    284288        aikaNaytto.BindTo(aikaLaskuri.SecondCounter); 
    285289        aikaNaytto.Y = Level.Top - 100; 
     
    329333 
    330334} 
    331  
  • 2012/30/JaniS/Virus Infection/Virus Infection/Virus Infection/SurvivalMode.txt

    r3707 r3721  
    22 
    33       #################### 
    4    ######................###### 
     4   ######..............x.###### 
    55#######...x................####### 
    6 #####...............x........##### 
    7 ####.x.........x..........x...#### 
    8 ###.......x....................### 
    9 ###...............x............### 
    10 ###x.....................x.....### 
    11 ###..........x.................### 
    12 ###.....x.............x........### 
    13 ###............................### 
    14 ###.............O..............### 
    15 ###......x.................x...### 
    16 ###x.................x.........### 
    17 ###............................### 
    18 ###..........x.................### 
    19 ###.....x..............x.......### 
    20 ###............................### 
    21 ####...............x..........#### 
    22 #####......x.................##### 
    23 #######..........x.........####### 
    24    ######................###### 
     6#####..............x.........##### 
     7####.........x............x...#### 
     8###.....x......................### 
     9###.............x..............### 
     10###.....................x......### 
     11###.....x......................### 
     12###.................x.........x### 
     13###.x..........................### 
     14###.............O.........x....### 
     15###....x............x..........### 
     16###..........x............x....### 
     17###.................x..........### 
     18###..x.........................### 
     19###..........x............x....### 
     20###.....x............x.........### 
     21####.......x..................#### 
     22#####.......x................##### 
     23#######.........x.....x....####### 
     24   ######......x.........###### 
    2525       #################### 
Note: See TracChangeset for help on using the changeset viewer.