source: 2015/27/EemilI/infected/infected/infected/infected.cs @ 6577

Revision 6577, 892 bytes checked in by misakana, 8 years ago (diff)

infectediä aloitettu

Line 
1using System;
2using System.Collections.Generic;
3using Jypeli;
4using Jypeli.Assets;
5using Jypeli.Controls;
6using Jypeli.Effects;
7using Jypeli.Widgets;
8
9public class infected : PhysicsGame
10{
11    PhysicsObject mies;
12    Image mieskuva = LoadImage("hahmon kuva");
13
14    public override void Begin()
15    {
16       
17
18       
19       
20
21
22       
23        Keyboard.Listen(Key.Escape, ButtonState.Pressed, ConfirmExit, "Lopeta peli");
24    }
25    void LuoHahmo(Vector paikka, double leveys, double korkeus)
26    {
27        mies = new PhysicsObject(mieskuva);
28        mies.Size = new Vector(100, 100);
29        mies.Position = paikka;
30        Add(mies);
31    }
32    void LuoKentta() 
33    {
34        ColorTileMap mappi = ColorTileMap.FromLevelAsset("mappi");
35
36        mappi.SetTileMethod(Color.Rose, LuoHahmo);
37        mappi.Execute();
38
39           
40    }
41    void 
42}
Note: See TracBrowser for help on using the repository browser.