diff options
| author | Xavier Del Campo Romero <xavi.dcr@tutanota.com> | 2024-01-27 14:14:37 +0100 |
|---|---|---|
| committer | Xavier Del Campo Romero <xavi.dcr@tutanota.com> | 2024-01-27 17:38:12 +0100 |
| commit | 27553f8ed1d062c4d8175e7376f5b16cf2c8f9ef (patch) | |
| tree | d46534843f12273ecb3cfc4923af6b600c385e08 /src/player | |
| parent | 0f21739551b2daf578ad9c5ed3367c8a8ed7b7c9 (diff) | |
| download | jancity-27553f8ed1d062c4d8175e7376f5b16cf2c8f9ef.tar.gz | |
Remove stale unit and building types
Diffstat (limited to 'src/player')
| -rw-r--r-- | src/player/src/player.c | 37 |
1 files changed, 0 insertions, 37 deletions
diff --git a/src/player/src/player.c b/src/player/src/player.c index e1932a5..5a69763 100644 --- a/src/player/src/player.c +++ b/src/player/src/player.c @@ -61,43 +61,6 @@ int player_create_building(const struct building_cfg *const cfg, struct player * int player_init(const struct player_cfg *const cfg, struct player *const pl) { - const unsigned long x = cfg->x, y = cfg->y; - - const struct building_cfg bcfg = - { - .type = BUILDING_TYPE_BARRACKS, - .x = x, - .y = y - }; - - const struct unit_cfg cfgs[] = - { - { - .type = UNIT_TYPE_PEASANT, - .x = x + 80, - .y = y - }, - - { - .type = UNIT_TYPE_PEASANT, - .x = x + 80, - .y = y + 40 - }, - - { - .type = UNIT_TYPE_PEASANT, - .x = x + 100, - .y = y + 20 - } - }; - - if (player_create_building(&bcfg, pl)) - return -1; - - for (size_t i = 0; i < sizeof cfgs / sizeof *cfgs; i++) - if (player_create_unit(&cfgs[i], pl)) - return -1; - pl->alive = true; pl->color = cfg->color; pl->team = cfg->team; |
