当前位置: 首页>>代码示例>>C#>>正文


C# Player.hasPaidAgilityArena方法代码示例

本文整理汇总了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);
	    }
开发者ID:slapglif,项目名称:runescape-server-csharp,代码行数:18,代码来源:AgilityArena.cs

示例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:
开发者ID:slapglif,项目名称:runescape-server-csharp,代码行数:67,代码来源:AgilityArena.cs


注:本文中的RunescapeServer.player.Player.hasPaidAgilityArena方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。