1
This commit is contained in:
parent
40968f3ae8
commit
58c10c6eb4
@ -15,6 +15,8 @@
|
|||||||
#include "mt/Text.h"
|
#include "mt/Text.h"
|
||||||
#include "mt/Hero.h"
|
#include "mt/Hero.h"
|
||||||
#include "mt/Item.h"
|
#include "mt/Item.h"
|
||||||
|
#include "mt/Map.h"
|
||||||
|
#include "mt/BattleBasicAttribute.h"
|
||||||
|
|
||||||
Android::Android():Human()
|
Android::Android():Human()
|
||||||
{
|
{
|
||||||
@ -72,6 +74,11 @@ void Android::Initialize()
|
|||||||
AddSkill(skill_id);
|
AddSkill(skill_id);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (GetHeroMeta()->GetBasicMeta()) {
|
||||||
|
SetHeroLevel(1, 0, GetHeroMeta()->GetBasicMeta()->GetGrowMeta(room->GetMapMeta()->map_id()));
|
||||||
|
} else {
|
||||||
|
SetHeroLevel(1, 0, nullptr);
|
||||||
|
}
|
||||||
agent_->SetOwner(this);
|
agent_->SetOwner(this);
|
||||||
f8::BtMgr::Instance()->BtLoad(agent_, "hero/standard");
|
f8::BtMgr::Instance()->BtLoad(agent_, "hero/standard");
|
||||||
f8::BtMgr::Instance()->BtSetCurrent(agent_, "hero/standard");
|
f8::BtMgr::Instance()->BtSetCurrent(agent_, "hero/standard");
|
||||||
|
@ -29,6 +29,8 @@
|
|||||||
#include "mt/Equip.h"
|
#include "mt/Equip.h"
|
||||||
#include "mt/Buff.h"
|
#include "mt/Buff.h"
|
||||||
#include "mt/MapThing.h"
|
#include "mt/MapThing.h"
|
||||||
|
#include "mt/Map.h"
|
||||||
|
#include "mt/BattleBasicAttribute.h"
|
||||||
|
|
||||||
Car::Car():Creature()
|
Car::Car():Creature()
|
||||||
{
|
{
|
||||||
@ -88,6 +90,11 @@ void Car::Initialize()
|
|||||||
AddSkill(skill_id);
|
AddSkill(skill_id);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (GetHeroMeta()->GetBasicMeta()) {
|
||||||
|
SetHeroLevel(1, 0, GetHeroMeta()->GetBasicMeta()->GetGrowMeta(room->GetMapMeta()->map_id()));
|
||||||
|
} else {
|
||||||
|
SetHeroLevel(1, 0, nullptr);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Human* Car::GetPassengerBySeat(int seat)
|
Human* Car::GetPassengerBySeat(int seat)
|
||||||
|
@ -110,11 +110,6 @@ void Human::Initialize()
|
|||||||
observers_.insert(this);
|
observers_.insert(this);
|
||||||
SetCurrWeapon(&weapons[0]);
|
SetCurrWeapon(&weapons[0]);
|
||||||
SetOxygen(mt::Param::s().dive_oxygen_total);
|
SetOxygen(mt::Param::s().dive_oxygen_total);
|
||||||
if (GetHeroMeta()->GetBasicMeta()) {
|
|
||||||
SetHeroLevel(1, 0, GetHeroMeta()->GetBasicMeta()->GetGrowMeta(room->GetMapMeta()->map_id()));
|
|
||||||
} else {
|
|
||||||
SetHeroLevel(1, 0, nullptr);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
float Human::GetSpeed()
|
float Human::GetSpeed()
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
#include "precompile.h"
|
#include "precompile.h"
|
||||||
|
|
||||||
#include "mt/BattleBasicAttribute.h"
|
#include "mt/BattleBasicAttribute.h"
|
||||||
|
#include "mt/BattleHeroGrow.h"
|
||||||
|
|
||||||
IMPL_TABLE(mt::BattleBasicAttribute)
|
IMPL_TABLE(mt::BattleBasicAttribute)
|
||||||
|
|
||||||
@ -19,7 +20,7 @@ namespace mt
|
|||||||
|
|
||||||
const BattleHeroGrow* BattleBasicAttribute::GetGrowMeta(int map_id) const
|
const BattleHeroGrow* BattleBasicAttribute::GetGrowMeta(int map_id) const
|
||||||
{
|
{
|
||||||
return nullptr;
|
return mt::BattleHeroGrow::GetByHeroIdLevel(id(), 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -24,11 +24,11 @@ namespace mt
|
|||||||
for (auto& str : strings) {
|
for (auto& str : strings) {
|
||||||
std::vector<std::string> strings2;
|
std::vector<std::string> strings2;
|
||||||
a8::Split(str, strings2, ':');
|
a8::Split(str, strings2, ':');
|
||||||
if (strings.size() != 2) {
|
if (strings2.size() != 2) {
|
||||||
abort();
|
abort();
|
||||||
}
|
}
|
||||||
int attr_id = a8::XValue(strings.at(0));
|
int attr_id = a8::XValue(strings2.at(0));
|
||||||
float attr_val = a8::XValue(strings.at(1)).GetDouble();
|
float attr_val = a8::XValue(strings2.at(1)).GetDouble();
|
||||||
if (!IsValidHumanAttr(attr_id) &&
|
if (!IsValidHumanAttr(attr_id) &&
|
||||||
!IsValidHumanVirtualAttr(attr_id)) {
|
!IsValidHumanVirtualAttr(attr_id)) {
|
||||||
abort();
|
abort();
|
||||||
|
@ -44,6 +44,7 @@
|
|||||||
#include "mt/Text.h"
|
#include "mt/Text.h"
|
||||||
#include "mt/Map.h"
|
#include "mt/Map.h"
|
||||||
#include "mt/PveGemini.h"
|
#include "mt/PveGemini.h"
|
||||||
|
#include "mt/BattleBasicAttribute.h"
|
||||||
|
|
||||||
const int kREVIVE_BUFF_ID = 1005;
|
const int kREVIVE_BUFF_ID = 1005;
|
||||||
|
|
||||||
@ -133,6 +134,11 @@ void Player::Initialize()
|
|||||||
},
|
},
|
||||||
&xtimer_attacher);
|
&xtimer_attacher);
|
||||||
}
|
}
|
||||||
|
if (GetHeroMeta()->GetBasicMeta()) {
|
||||||
|
SetHeroLevel(1, 0, GetHeroMeta()->GetBasicMeta()->GetGrowMeta(room->GetMapMeta()->map_id()));
|
||||||
|
} else {
|
||||||
|
SetHeroLevel(1, 0, nullptr);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void Player::Update(int delta_time)
|
void Player::Update(int delta_time)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user