new 990aace9276b9b070a7fbae82fa73469c6d99ec2
[tagua/yd.git] / src / variants / chess5x5 / chess5x5.cs
bloba7f5977a56ed42fdeb0a715a1a7391fadd1bcb11
1 using Tagua.Component;
2 using Tagua.Repository;
3 using Tagua.Point;
4 using Tagua.IVariantLoader;
6 public class Chess5x5 {
7 public static Repository initrepo(IVariantLoader loader) {
8 Repository repo = new Repository();
9 Repository chess = loader.getRepository("chess");
10 if (chess == null) return null;
12 repo.setProxy(chess);
14 Component chess_state_factory = chess.getComponent("state_factory");
15 Component state_factory = chess_state_factory.invoke(
16 "createFactory", new Point(5, 5));
18 repo.addComponent("state_factory", state_factory);
20 return repo;