• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!

Limit Magic Effect

nogenem45

~~ * Slicer * ~~
Joined
Oct 6, 2010
Messages
44
Reaction score
3
Hello guys... I'm trying to remove the limit of magic effects... from what I saw the 'problem' is in this part...
Code:
if(g_game.getFeature(Otc::GameMagicEffectU16))
   effectId = msg->getU16();
else
   effectId = msg->getU8();

Then i put this in the otc...
Code:
g_game.enableFeature(GameMagicEffectU16)

And now, when i use the command '/z' shows this error in the terminal...
Code:
ERROR: ProtocolGame parse message exception (1 bytes unread, last opcode is 131, prev opcode is -1): InputMessage eof reached

-is all right in the source of the serv...-

Really haven't a way to do that s**** works? ;x

ty.. ;p
 
Use dump << "lala"; or a breakpoint to check if that's really active.

if(g_game.getFeature(Otc::GameMagicEffectU16)) {
dump << "u16";
effectId = msg->getU16();
}
else {
dump << "u8";
effectId = msg->getU8();
}

There's a certain place to add:

g_game.enableFeature(GameMagicEffectU16)

As i remember, it's at 'onProtocolVersionChange' event, from g_game.
 
i had put it in the modules/game_things/things.lua because i already had put it...
Code:
g_game.enableFeature(GameBlueNpcNameColor)
there and it worked...

but, i will try what you said... ty
 
You have to make sure your server also sends U16..
 
EDIT:

Summ you know how to change that? ;x
 
Last edited:
Back
Top