mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-19 11:59:26 +00:00
wtf
This commit is contained in:
1 parent
5795cc984b
commit
19cdf19a9b
3 files changed
+34
-1
No files matched your search
@@ -8,16 +8,32 @@ import noppes.npcs.constants.EnumScriptType;
|
||||
|
||||
public class DialogEvent extends PlayerEvent implements IDialogEvent {
|
||||
public final IDialog dialog;
|
||||
private final int optionId;
|
||||
|
||||
public DialogEvent(IPlayer player, IDialog dialog) {
|
||||
this(player, dialog, -1);
|
||||
}
|
||||
|
||||
public DialogEvent(IPlayer player, IDialog dialog, int optionId) {
|
||||
super(player);
|
||||
this.dialog = dialog;
|
||||
this.optionId = optionId;
|
||||
}
|
||||
|
||||
public IDialog getDialog() {
|
||||
return dialog;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getDialogId() {
|
||||
return dialog != null ? dialog.getId() : -1;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getOptionId() {
|
||||
return optionId;
|
||||
}
|
||||
|
||||
public String getHookName() {
|
||||
return EnumScriptType.DIALOG_EVENT.function;
|
||||
}
|
||||
@@ -39,6 +55,10 @@ public class DialogEvent extends PlayerEvent implements IDialogEvent {
|
||||
super(player, dialog);
|
||||
}
|
||||
|
||||
public DialogOption(IPlayer player, IDialog dialog, int optionId) {
|
||||
super(player, dialog, optionId);
|
||||
}
|
||||
|
||||
public String getHookName() {
|
||||
return EnumScriptType.DIALOG_OPTION.function;
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user