Skip to content
Toggle navigation
P
Projects
G
Groups
S
Snippets
Help
krkane
/
Rüütli Vaev
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
1
Pipelines
Wiki
Snippets
Members
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit
96912b00
authored
Mar 20, 2024
by
krkane
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add new file
parent
ab0b2d1e
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
43 additions
and
0 deletions
Source/Header.h
Source/Header.h
0 → 100644
View file @
96912b00
#ifndef GAME_HEADER_H
#define GAME_HEADER_H
#include <stdio.h>
#include <stdlib.h>
#include <time.h>
#include <string.h>
#define NUM_HENCHMEN 5
typedef
struct
{
int
health
;
int
attack
;
int
potionCount
;
}
Player
;
typedef
struct
{
int
health
;
int
attack
;
char
type
[
20
];
}
Enemy
;
typedef
struct
{
int
health
;
int
attack
;
char
type
[
20
];
}
FinalBoss
;
void
PrintWelcomeMessage
(
void
);
void
DisplayGameRules
(
void
);
Player
CreatePlayer
();
int
Move
(
int
defeated_enemies
);
int
fight
(
Player
*
p
,
Enemy
*
e
);
int
bossFight
(
Player
*
p
,
Enemy
*
boss
);
void
usePotion
(
Player
*
p
,
int
initialHealth
,
int
currentHealth
);
void
levelUp
(
Player
*
p
);
Enemy
CreateEnemy
(
int
defeated_enemies
);
FinalBoss
CreateFinalBoss
(
int
defeated_enemies
);
#endif //GAME_HEADER_H
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment