1
This commit is contained in:
parent
1ad1db690c
commit
a1e19a9985
@ -1,3 +1,8 @@
|
||||
#include "precompile.h"
|
||||
|
||||
#include "bag.h"
|
||||
|
||||
void Bag::Parse(const std::list<int>& items)
|
||||
{
|
||||
|
||||
}
|
||||
|
@ -1,11 +1,13 @@
|
||||
#pragma once
|
||||
|
||||
class Creature;
|
||||
class Bag
|
||||
{
|
||||
public:
|
||||
|
||||
Bag(Creature* owner) { owner_ = owner; };
|
||||
void UseItem(int equip_id);
|
||||
void PushBagInfo();
|
||||
void Parse(const std::list<int>& items);
|
||||
|
||||
private:
|
||||
Creature* owner_ = nullptr;
|
||||
|
@ -97,7 +97,7 @@ Human::Human():Creature()
|
||||
AddInventory(IS_ICE, FIGHTING_MODE_BULLET_NUM);
|
||||
}
|
||||
stats = std::make_shared<PlayerStats>();
|
||||
bag_ = std::make_shared<Bag>();
|
||||
bag_ = std::make_shared<Bag>(this);
|
||||
}
|
||||
|
||||
Human::~Human()
|
||||
|
@ -185,6 +185,7 @@ static Player* InternalCreatePlayer(std::shared_ptr<CustomBattle> p,
|
||||
hum->side
|
||||
});
|
||||
#endif
|
||||
hum->GetBag()->Parse(hum->GetNetData()->GetItems());
|
||||
return hum;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user