source: 2012/27/DenisZ/TheDungeonGame/TheDungeonGame/TheDungeonGame/TheDungeonGame.cs @ 3466

Revision 3466, 892 bytes checked in by dezhidki, 8 years ago (diff)

Talletus.

Line 
1using System;
2using System.Collections.Generic;
3using Jypeli;
4using Jypeli.Assets;
5using Jypeli.Controls;
6using Jypeli.Effects;
7using Jypeli.Widgets;
8using MathHelper;
9using Entity;
10using Rooms;
11
12public class TheDungeonGame : PhysicsGame
13{
14    private Player player;
15
16    public override void Begin()
17    {
18        IsMouseVisible = true;
19        SetWindowSize(800, 600);
20       
21        Level.CreateBorders();
22        Camera.ZoomToLevel();
23
24        TestRoom testroom = new TestRoom(this,new Vector(Level.Left, Level.Top), new Vector(200, 100), 20);
25        testroom.buildLevel();
26
27        player = new Player(Vector.Zero);
28        Add(player);
29
30        Keyboard.Listen(Key.Escape, ButtonState.Pressed, Exit, "Lopeta peli");   
31    }
32
33    protected override void Update(Time time)
34    {
35        player.Update(time);
36        base.Update(time);
37    }
38}
Note: See TracBrowser for help on using the repository browser.