Skip to content
Snippets Groups Projects

Compare revisions

Changes are shown as if the source revision was being merged into the target revision. Learn more about comparing revisions.

Source

Select target project
No results found

Target

Select target project
No results found
Show changes
Showing
with 108 additions and 1 deletion
......@@ -47,7 +47,9 @@
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="view\Controls\MapView.Designer.cs" />
<Compile Include="controller\Game.cs" />
<Compile Include="model\Improvement.cs" />
<Compile Include="model\Player.cs" />
<Compile Include="view\FormFin.cs">
<SubType>Form</SubType>
</Compile>
......
File moved
using System.Collections.Generic;
using System.Drawing;
using Wanderer.model;
namespace Wanderer.controller
{
public class Game
{
public List<Player> Players { get; set; }
public int currentPlayerIndex { get; set; }
public static Game Instance { get; set; }
public Game()
{
Players = new List<Player>(2);
Players.Add(new Player(Color.Brown));
Players.Add(new Player(Color.RoyalBlue));
}
}
}
\ No newline at end of file
namespace Wanderer.model
{
public enum Improvement
{
Refuge,
Path,
Club,
TrainStation,
Factory
}
}
\ No newline at end of file
using Wanderer.model;
namespace Wanderer
namespace Wanderer.model
{
public class Map
{
private Tile[,] _tiles;
public Map(int dx, int dy)
public Map(int x, int y)
{
_tiles = new Tile[dx, dy];
_tiles = new Tile[x, y];
for (int i = 0; i < x; ++i)
for (int j = 0; j < y; ++j)
_tiles[i, j] = new Tile();
}
public Tile[,] Tiles
......
using System.Drawing;
namespace Wanderer.model
{
public class Player
{
public Color Color { get; set; }
public int bonusCh = 0;//bonus Chemin
public int bonusCl = 0; //bonus Club
public int marks = 50;
public int randonneurs = 0;
public int tailleTerritoire;
public int gain = 0;
public Player(Color color)
{
Color = color;
}
}
}
\ No newline at end of file
namespace Wanderer
namespace Wanderer.model
{
public enum Terrain
{
Plains,
Hills,
Mountains
Mountains,
Forest,
Lake,
River,
Urban
}
}
\ No newline at end of file
namespace Wanderer.model
{
public class Tile
{
private Improvement _improvement;
public Terrain Terrain { get; set; }
public Player Owner { get; set; }
public bool HasChanged { get; set; }
public Improvement Improvement
{
get => _improvement;
set
{
_improvement = _improvement == 0 ? value : _improvement;
HasChanged = true;
}
}
}
}
\ No newline at end of file
src/ressources/Reliefkarte_Massif_des_Vosges.JPG

3.81 MiB

src/ressources/Reliefkarte_Massif_des_Vosgess.JPG

2.79 MiB

File moved
src/ressources/coins.png

1.12 KiB

File moved
File moved
File moved