We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b1b29d1 commit 417e0ddCopy full SHA for 417e0dd
src/legacy/api/PlayerAPI.cpp
@@ -3659,8 +3659,8 @@ Local<Value> PlayerClass::addEffect(const Arguments& args) {
3659
if (!player) {
3660
return Boolean::newBoolean(false);
3661
}
3662
- unsigned int id = args[0].asNumber().toInt32();
3663
- int tick = args[1].asNumber().toInt32();
+ unsigned int id = args[0].asNumber().toInt32();
+ EffectDuration duration{args[1].asNumber().toInt32()};
3664
int level = args[2].asNumber().toInt32();
3665
bool showParticles = args[3].asBoolean().value();
3666
MobEffectInstance effect(id);
0 commit comments