inventory system

Hi., Everyone.can i ask some question's about c programming, who can explain this question.
What Inventory System ?, How to use inventory system?, and what module of inventory system...please help me to answer my question.
closed account (18hRX9L8)
Is this what you mean? Are you trying to make it for a game? http://www.dailyfreecode.com/Code/inventory-management-system-1034.aspx
Last edited on
I mean..the explanation about the program...
What program do you talking about?
closed account (18hRX9L8)
halal wrote:
I mean..the explanation about the program...

If you read the link I gave to you, you would know that an inventory system can be a class or struct that keeps records of the quantity of something, it's characteristics, etc... It must also include functions that read / write to the system to keep it updated. For example, if you were making a racing game, you would need to keep track of the car objects. Example:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
typedef struct Car {
	char *Name;
	char *Make;
	unsigned long Year;
	unsigned int BodyColor;
	unsigned int BumperColor;
	unsigned int HoodColor;
	unsigned int Rims;
	unsigned int Horsepower;
	unsigned int CrashesUntilTotaled;
	unsigned long long DefaultValue;
	unsigned long long SellingValue;
	//...
	
	void UpdateBodyColor(unsigned int);
	void UpdateBumperColor(unsigned int);
	void UpdateHoodColor(unsigned int);
	void UpdateRims(unsigned int);
	void ChangeHorsePower(unsigned int);
	//...
} Car;

typedef struct CarInventory {
	Car *Cars;
	
	void BuyCar(Car NewCar);
	void SellCar(Car OldCar);
	void MaxOutCar(int CarNum);
        //....
} CarInventory;
Last edited on
Topic archived. No new replies allowed.