- Joined
- Apr 5, 2008
- Messages
- 152
- Reaction score
- 65
Hello everyone,
I thought i would release my map only GM commands. (So i don't feel like I'm leaching as much)
In Players.cpp add: (i hope you know where)
And for this part i couldn't find the creator (if you are him just say so and i will credit you)
Add in PlayersPacket.h:
Below:
At the bottom of PlayersPacket.cpp add:
And i think that covers it
I thought i would release my map only GM commands. (So i don't feel like I'm leaching as much)
In Players.cpp add: (i hope you know where)
Code:
// Code made by ZeusMS
else if(strcmp(command, "mnotice") == 0){ // Blue notice Map Only
for(unsigned int j=0; j<Maps::info[player->getMap()].Players.size(); j++)
PlayersPacket::showNoticeOneChar(next_token, 0, Maps::info[player->getMap()].Players[j]);
}
else if(strcmp(command, "mnotice1") == 0){ // Box Notice Map Only
for(unsigned int j=0; j<Maps::info[player->getMap()].Players.size(); j++)
PlayersPacket::showNoticeOneChar(next_token, 1, Maps::info[player->getMap()].Players[j]);
}
else if(strcmp(command, "mnotice2") == 0){ // Red Notice Map Only
for(unsigned int j=0; j<Maps::info[player->getMap()].Players.size(); j++)
PlayersPacket::showNoticeOneChar(next_token, 5, Maps::info[player->getMap()].Players[j]);
}
// End code made by ZeusMS
And for this part i couldn't find the creator (if you are him just say so and i will credit you)
Add in PlayersPacket.h:
Code:
static void showNoticeOneChar(char* msg, char type, Player* player);
Below:
Code:
static void showInfo(Player* player, Player* getinfo);
At the bottom of PlayersPacket.cpp add:
Code:
void PlayersPacket::showNoticeOneChar(char* msg, char type, Player* player){
Packet packet = Packet();
packet.addHeader(0x2d);
packet.addByte(type);
packet.addShort(strlen(msg));
packet.addString(msg, strlen(msg));
packet.packetSend(player);
}
And i think that covers it