llamavani
Trinitium Rubidia Style!
Hello, today I was patching my server with some C++ codes and I found a Loot channel code(http://otland.net/f35/loot-channel-22638/)but) then I tried to compile but it marked an error.
To FIX the error just follow my step:
talkactions.cpp change:
for:
and well... that's it
If I helped you Pls Rep++
To FIX the error just follow my step:
talkactions.cpp change:
Code:
bool TalkAction::showLoot(Player* player, const std::string& cmd, const std::string& param)
{
player->switchGetLoot();
char buffer[90];
sprintf(buffer, "You have %s the loot channel.", (player->getLoot() ? "enabled" : "disabled"));
player->sendTextMessage(MSG_INFO_DESCR, buffer);
char channel[90];
sprintf(channel, "The loot channel has been %s.", (player->getLoot () ? "activated" : "deactivated"));
player->sendChannelMessage("", channel, SPEAK_CHANNEL_R1, CHANNEL_LOOT);
return true;
}
for:
Code:
bool TalkAction::showLoot(Creature* creature, const std::string& cmd, const std::string& param)
{
Player* player = creature->getPlayer();
player->switchGetLoot();
char buffer[90];
sprintf(buffer, "You have %s the loot channel.", (player->getLoot() ? "enabled" : "disabled"));
player->sendTextMessage(MSG_INFO_DESCR, buffer);
char channel[90];
sprintf(channel, "The loot channel has been %s.", (player->getLoot () ? "activated" : "deactivated"));
player->sendChannelMessage("", channel, SPEAK_CHANNEL_R1, CHANNEL_LOOT);
return true;
}
and well... that's it
If I helped you Pls Rep++