PDA

View Full Version : [TrinityCore] World Chat with ICON



Wise
10-04-15, 10:56 AM
GMLevel 0 = Player
GMLevel 1 = VIP
GMLevel 2 = Trial GM
GMLevel 3 = GM
GMLevel 4 = Admin
GMLevel 5 = Developer
GMLevel 6 = Co-Owner
GMLevel 7 = Owner



Download (http://pastebin.com/up6X7Ta7)



How to add custom scripts? (http://www.ac-web.org/forums/showthread.php?145843-Trinity-How-to-add-a-c-script-to-your-core)



Rbac.h edit -
Add to rbac.h around line 683:


RBAC_PERM_COMMAND_WORLD_CHAT = 1009,
Common.h edit -


enum AccountTypes
{
SEC_PLAYER = 0,
SEC_VIP = 1,
SEC_GAMEMASTER = 2,
SEC_EVENTM = 3,
SEC_HEADGM = 4,
SEC_DEVELOPER = 5,
SEC_ADMINISTRATOR = 6,
SEC_OWNER = 7,
SEC_CONSOLE = 8 // must be always last in list, accounts must have less security level always also
};
SQL query to add command to players and ranks above:


INSERT INTO `rbac_permissions` (`id`, `name`) VALUES
(1009, 'Command: world chat');

INSERT INTO `rbac_linked_permissions` (`id`,`linkedId`) VALUES
(195, 1009);

INSERT INTO `rbac_permissions` (`id`, `name`) VALUES (180, 'Role: VIP');

INSERT INTO `rbac_default_permissions` (`secId`, `permissionId`) VALUES (0, 195);
INSERT INTO `rbac_default_permissions` (`secId`, `permissionId`) VALUES (1, 180);
INSERT INTO `rbac_default_permissions` (`secId`, `permissionId`) VALUES (2, 194);
INSERT INTO `rbac_default_permissions` (`secId`, `permissionId`) VALUES (3, 194);
INSERT INTO `rbac_default_permissions` (`secId`, `permissionId`) VALUES (4, 194);
INSERT INTO `rbac_default_permissions` (`secId`, `permissionId`) VALUES (5, 193);
INSERT INTO `rbac_default_permissions` (`secId`, `permissionId`) VALUES (6, 193);
INSERT INTO `rbac_default_permissions` (`secId`, `permissionId`) VALUES (7, 192);


Credits


CastleDEV.