fix particle removal, static messages colors
This commit is contained in:
parent
f7dd35f0dd
commit
ded2133e7c
|
@ -83,25 +83,28 @@ void StaticText::compose()
|
|||
if(m_type == Otc::SpeakSay) {
|
||||
m_text += m_name;
|
||||
m_text += " says:\n";
|
||||
m_color = Fw::yellow;
|
||||
m_color = Color(239, 239, 0);
|
||||
}
|
||||
else if(m_type == Otc::SpeakWhisper) {
|
||||
m_text += m_name;
|
||||
m_text += " whispers:\n";
|
||||
m_color = Fw::yellow;
|
||||
m_color = Color(239, 239, 0);
|
||||
}
|
||||
else if(m_type == Otc::SpeakYell) {
|
||||
m_text += m_name;
|
||||
m_text += " yells:\n";
|
||||
m_color = Fw::yellow;
|
||||
m_color = Color(239, 239, 0);
|
||||
}
|
||||
else if(m_type == Otc::SpeakMonsterSay || m_type == Otc::SpeakMonsterYell) {
|
||||
m_color = Fw::orange;
|
||||
m_color = Color(254, 101, 0);
|
||||
}
|
||||
else if(m_type == Otc::SpeakPrivateNpcToPlayer) {
|
||||
m_text += m_name;
|
||||
m_text += " says:\n";
|
||||
m_color = Fw::blue;
|
||||
m_color = Color(95, 247, 247);
|
||||
}
|
||||
else {
|
||||
logWarning("unknown message type: ", m_type);
|
||||
}
|
||||
|
||||
// Todo: add break lines
|
||||
|
|
|
@ -533,15 +533,11 @@ void ProtocolGame::parseMagicEffect(InputMessage& msg)
|
|||
Position pos = parsePosition(msg);
|
||||
int effectId = msg.getU8();
|
||||
|
||||
if(effectId != 37) {
|
||||
EffectPtr effect = EffectPtr(new Effect());
|
||||
effect->setId(effectId);
|
||||
effect->setPosition(pos);
|
||||
EffectPtr effect = EffectPtr(new Effect());
|
||||
effect->setId(effectId);
|
||||
effect->setPosition(pos);
|
||||
|
||||
g_map.addThing(effect, pos);
|
||||
}
|
||||
else
|
||||
g_particleManager.load("particle.otpa");
|
||||
g_map.addThing(effect, pos);
|
||||
}
|
||||
|
||||
void ProtocolGame::parseAnimatedText(InputMessage& msg)
|
||||
|
@ -564,12 +560,10 @@ void ProtocolGame::parseDistanceMissile(InputMessage& msg)
|
|||
Position toPos = parsePosition(msg);
|
||||
int shotId = msg.getU8();
|
||||
|
||||
if(shotId != 4) {
|
||||
MissilePtr shot = MissilePtr(new Missile());
|
||||
shot->setId(shotId);
|
||||
shot->setPath(fromPos, toPos);
|
||||
g_map.addThing(shot, fromPos);
|
||||
}
|
||||
MissilePtr shot = MissilePtr(new Missile());
|
||||
shot->setId(shotId);
|
||||
shot->setPath(fromPos, toPos);
|
||||
g_map.addThing(shot, fromPos);
|
||||
}
|
||||
|
||||
void ProtocolGame::parseCreatureSquare(InputMessage& msg)
|
||||
|
|
Loading…
Reference in New Issue