Skip to content
Permalink
master
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
#ifndef ITEM_H
#define ITEM_H
#include "weapon.h"
#include "position.h"
typedef enum { WEAPON_TYPE, POTION_TYPE} ItemType;
typedef struct Item
{
ItemType type;
Position * position;
union {
Weapon * weapon;
//potion - potion;
} item;
char string[256];
} Item;
//item factory
Item * createSword(int attack, int health);
#endif