Gegner splodieren.
[hackover2013-badge-firmware.git] / badge / jumpnrun / player.c
1 #include "player.h"
2 #include "jumpnrun.h"
3 #include <stdlib.h>
4
5 void jumpnrun_player_respawn(jumpnrun_player *self, vec2d spawn_pos) {
6 memset(&self->base, 0, sizeof(self->base));
7 self->base.hitbox = rectangle_new(spawn_pos, jumpnrun_player_extents());
8 }
9
10 void jumpnrun_player_spawn (jumpnrun_player *self, vec2d spawn_pos, uint8_t lives) {
11 memset(self, 0, sizeof(*self));
12 jumpnrun_player_respawn(self, spawn_pos);
13 self->lives = lives;
14 }
This page took 0.045034 seconds and 5 git commands to generate.