本文整理汇总了C#中RunescapeServer.player.Player.hasPaidAgilityArena方法的典型用法代码示例。如果您正苦于以下问题:C# Player.hasPaidAgilityArena方法的具体用法?C# Player.hasPaidAgilityArena怎么用?C# Player.hasPaidAgilityArena使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类RunescapeServer.player.Player
的用法示例。
在下文中一共展示了Player.hasPaidAgilityArena方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: enterArena
public static void enterArena(Player p, int objectX, int objectY) {
CoordinateEvent enterArenaCoordinateEvent = new CoordinateEvent(p, new Location(2809, 3193, 0));
enterArenaCoordinateEvent.setAction(() => {
if (!p.hasPaidAgilityArena()) {
p.getPackets().sendMessage("You must pay Cap'n Izzy the entrance fee before you can enter the Agility Arena.");
return;
}
p.setLastAnimation(new Animation(827));
Event teleportArenaEvent = new Event(1000);
teleportArenaEvent.setAction(() => {
p.setPaidAgilityArena(false);
p.teleport(new Location(2805, 9589, 3));
teleportArenaEvent.stop();
});
Server.registerEvent(teleportArenaEvent);
});
Server.registerCoordinateEvent(enterArenaCoordinateEvent);
}
示例2: doDialogue
//.........这里部分代码省略.........
p.getPackets().sendChatboxInterface2(242);
newStatus = 22;
break;
case 22:
p.getPackets().sendNPCHead(437, 241, 2);
p.getPackets().modifyText("Cap'n Izzy No-Beard", 241, 3);
p.getPackets().modifyText("Thanks me hearty!", 241, 4);
p.getPackets().animateInterface(9827, 241, 2);
p.getPackets().sendChatboxInterface2(241);
newStatus = 23;
break;
case 23:
p.getPackets().sendPlayerHead(64, 2);
p.getPackets().modifyText(p.getLoginDetails().getUsername(), 64, 3);
p.getPackets().modifyText("Thanks!", 64, 4);
p.getPackets().animateInterface(9827, 64, 2);
p.getPackets().sendChatboxInterface2(64);
newStatus = 6;
break;
case 24:
p.getPackets().sendPlayerHead(64, 2);
p.getPackets().modifyText(p.getLoginDetails().getUsername(), 64, 3);
p.getPackets().modifyText("I'd like to use the Agility Arena, please.", 64, 4);
p.getPackets().animateInterface(9827, 64, 2);
p.getPackets().sendChatboxInterface2(64);
newStatus = 25;
break;
case 25:
string message = "";
if (p.hasPaidAgilityArena()) {
message = "Ye've already paid, so down ye goes...";
} else {
message = "Aye, Entrance be " + AGILITY_ARENA_PRICE.ToString("#,##0") + " coins.";
newStatus = 26;
}
p.getPackets().sendNPCHead(437, 241, 2);
p.getPackets().modifyText("Cap'n Izzy No-Beard", 241, 3);
p.getPackets().modifyText(message, 241, 4);
p.getPackets().animateInterface(9827, 241, 2);
p.getPackets().sendChatboxInterface2(241);
break;
case 26:
p.getPackets().sendNPCHead(4535, 241, 1);
p.getPackets().modifyText("Parrot", 241, 3);
p.getPackets().modifyText("Pieces of eight!", 241, 4);
p.getPackets().animateInterface(9827, 241, 1);
p.getPackets().sendChatboxInterface2(241);
newStatus = 27;
break;
case 27:
p.getPackets().sendNPCHead(437, 242, 2);
p.getPackets().modifyText("Cap'n Izzy No-Beard", 242, 3);
p.getPackets().modifyText("A word of warning me hearty! There are dangerous", 242, 4);
p.getPackets().modifyText("traps down there!", 242, 5);
p.getPackets().animateInterface(9827, 242, 2);
p.getPackets().sendChatboxInterface2(242);
newStatus = 28;
break;
case 28: