This commit is contained in:
aozhiwei 2019-07-22 16:20:24 +08:00
parent 38a19d968b
commit 49084d0a1e

View File

@ -225,10 +225,11 @@ void Human::DirectShot(MetaData::Equip* bullet_meta, int skill_id)
if (sender) {
int skill_id = a8::Low32(param.param2.GetInt64());
int offset_idx = a8::High32(param.param2.GetInt64());
float attack_x = a8::Low32(param.param2.GetInt64()) / (float)kTEN_W;
float attack_y = a8::High32(param.param2.GetInt64()) / (float)kTEN_W;
float attack_x = a8::Low32(param.param3.GetInt64()) / (float)kTEN_W;
float attack_y = a8::High32(param.param3.GetInt64()) / (float)kTEN_W;
a8::Vec2 old_attack_dir = sender->attack_dir;
sender->attack_dir = a8::Vec2(attack_x, attack_y);
sender->attack_dir.Normalize();
sender->InternalShot(bullet_meta,
skill_id,
offset_idx);