mirror of
https://github.com/ProjectSWGCore/Holocore.git
synced 2026-07-30 00:15:50 -04:00
groupMakerLeader.js - serves as the command hook for the make leader command GroupService.java - now handles the GROUP_MAKE_LEADER intent - added handleMakeLeader to take care of switching the leader to another character - refactored sending invites out to sendInvite, one that allows the passage of the current groupID, and one that sets it to -1 for group creation - handleGroupLeave also filled in
9 lines
358 B
JavaScript
9 lines
358 B
JavaScript
function executeCommand(galacticManager, player, target, args) {
|
|
var GroupEventIntent = Java.type("intents.GroupEventIntent");
|
|
var GroupEventType = Java.type("intents.GroupEventIntent.GroupEventType");
|
|
|
|
if (target != null && (args == null || args.length == 0)) {
|
|
new GroupEventIntent(GroupEventType.GROUP_MAKE_LEADER, player, target).broadcast();
|
|
}
|
|
}
|