mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2024-11-22 13:37:22 +00:00
Fix incorrect SwitchMultiple handling
This commit is contained in:
parent
54d8c45b52
commit
b8251c06b8
@ -22,13 +22,9 @@ void SwitchMultipleBehavior::Handle(BehaviorContext* context, RakNet::BitStream*
|
|||||||
for (unsigned int i = 0; i < this->m_behaviors.size(); i++) {
|
for (unsigned int i = 0; i < this->m_behaviors.size(); i++) {
|
||||||
|
|
||||||
const double data = this->m_behaviors.at(i).first;
|
const double data = this->m_behaviors.at(i).first;
|
||||||
|
|
||||||
if (value <= data) {
|
|
||||||
|
|
||||||
trigger = i;
|
trigger = i;
|
||||||
|
|
||||||
break;
|
if (value <= data) break;
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
auto* behavior = this->m_behaviors.at(trigger).second;
|
auto* behavior = this->m_behaviors.at(trigger).second;
|
||||||
|
Loading…
Reference in New Issue
Block a user