本文整理汇总了C#中Zepheus.Zone.Game.ZoneCharacter.DropMessage方法的典型用法代码示例。如果您正苦于以下问题:C# ZoneCharacter.DropMessage方法的具体用法?C# ZoneCharacter.DropMessage怎么用?C# ZoneCharacter.DropMessage使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Zepheus.Zone.Game.ZoneCharacter
的用法示例。
在下文中一共展示了ZoneCharacter.DropMessage方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SpawnMobT
private void SpawnMobT(ZoneCharacter character, params string[] param)
{
ushort id = ushort.Parse(param[1]);
int count = 1;
if (param.Length >= 3)
{
count = int.Parse(param[2]);
}
if (DataProvider.Instance.MobsByID.ContainsKey(id))
{
for (int i = 0; i < count; i++)
{
Mob mob = new Mob(id, new Vector2(character.Position));
character.Map.FullAddObject(mob);
}
}
else character.DropMessage("Monster ID not found.");
}
示例2: Test
private void Test(ZoneCharacter character, params string[] param)
{
ushort skillid = ushort.Parse(param[1]);
if (!DataProvider.Instance.ActiveSkillsByID.ContainsKey(skillid))
{
character.DropMessage("Unknown skill.");
}
else if (character.SkillsActive.ContainsKey(skillid))
{
character.DropMessage("You already have that skill");
}
else
{
character.SkillsActive.Add(skillid, new Skill(character, skillid));
Handler18.SendSkillLearnt(character, skillid);
}
}
示例3: Pos
private void Pos(ZoneCharacter character, params string[] param)
{
character.DropMessage("Map= {0} ({1}); Pos= {2}:{3};",
character.Map.MapID,
character.Map.MapInfo.FullName,
character.Position.X,
character.Position.Y);
}
示例4: SpawnMob
private void SpawnMob(ZoneCharacter character, params string[] param)
{
ushort id = ushort.Parse(param[1]);
if (DataProvider.Instance.MobsByID.ContainsKey(id))
{
Mob mob = new Mob((ushort)(param.Length == 2 ? id : 1045), new Vector2(character.Position));
character.Map.FullAddObject(mob);
}
else character.DropMessage("Monster ID not found.");
}
示例5: List
private void List(ZoneCharacter character, params string[] param)
{
character.DropMessage("Your l33t commands:");
foreach (var kvp in commands)
{
if (kvp.Value.GmLevel <= character.Client.Admin)
{
character.DropMessage("{0} {1}", kvp.Key, string.Join(" ", kvp.Value.Parameters));
}
}
}
示例6: Performance
private void Performance(ZoneCharacter character, params string[] param)
{
character.DropMessage("Ticks per second on this zone: {0}", Worker.Instance.TicksPerSecond);
}
示例7: IsGay
private void IsGay(ZoneCharacter character, params string[] param)
{
ZoneClient otherclient = ClientManager.Instance.GetClientByName(param[1]);
if (otherclient == null || otherclient.Character == null)
{
character.DropMessage("Character not found.");
}
ZoneCharacter other = otherclient.Character;
Question question = new Question("Are you gay?", new QuestionCallback(AnswerGay), character);
question.Add("Yes", "No", "Boobs!");
other.Question = question;
question.Send(other);
}
示例8: ItemCommand
private void ItemCommand(ZoneCharacter character, params string[] param)
{
ushort id = ushort.Parse(param[1]);
byte amount = 1;
if (param.Length > 2)
{
amount = byte.Parse(param[2]);
}
switch (character.GiveItem(id, amount))
{
case FiestaLib.InventoryStatus.FULL:
Handler12.InventoryFull(character);
return;
case FiestaLib.InventoryStatus.NOT_FOUND:
character.DropMessage("Item not found.");
return;
}
}
示例9: CommandParam
private void CommandParam(ZoneCharacter character, params string[] param)
{
string input = param[1];
string request;
if (!input.StartsWith("&"))
{
request = "&" + input;
}
else request = input;
CommandInfo info;
if (commands.TryGetValue(request, out info))
{
string output = request + ": ";
if (info.Parameters.Length > 0)
{
foreach (var par in info.Parameters)
{
output += "[" + par + "] ";
}
}
else output += "None";
character.DropMessage(output);
}
else character.DropMessage("Command not found.");
}
示例10: ChangeMap
private void ChangeMap(ZoneCharacter character, params string[] param)
{
ushort mapid = 0;
if (!ushort.TryParse(param[1], out mapid))
{
param[1] = param[1].ToLower();
var map = DataProvider.Instance.MapsByID.Values.ToList().Find(m => m.ShortName.ToLower() == param[1]);
if (map != null)
{
mapid = map.ID;
}
else
{
character.DropMessage("Map not found");
return;
}
}
else
{
if (!DataProvider.Instance.MapsByID.ContainsKey(mapid))
{
character.DropMessage("Map not found");
return;
}
}
if (param.Length > 2)
{
int x = int.Parse(param[2]);
int y = int.Parse(param[3]);
character.ChangeMap(mapid, x, y);
}
character.ChangeMap(mapid);
}
示例11: AdminLevel
private void AdminLevel(ZoneCharacter character, params string[] param)
{
Log.WriteLine(LogLevel.Debug, "GM {0} authenticated ingame.", character.Name);
character.DropMessage("Admin level is {0}", character.Client.Admin);
InterHandler.SendWorldMessage(FiestaLib.WorldMessageTypes.Level20, "Fun!");
}
示例12: SpawnMobT
private void SpawnMobT(ZoneCharacter character, params string[] param)
{
string mobName = param[1];
int count = 1;
if (param.Length >= 3)
{
count = int.Parse(param[2]);
}
if (DataProvider.Instance.MobsByName.ContainsKey(mobName))
{
ushort mobID = DataProvider.Instance.MobsByName[mobName].ID;
for (int i = 0; i < count; i++)
{
Mob mob = new Mob(mobID, new Vector2(character.Position));
character.Map.FullAddObject(mob);
}
}
else character.DropMessage("Monster Name not found.");
}
示例13: AdminLevel
private void AdminLevel(ZoneCharacter character, params string[] param)
{
Log.WriteLine(LogLevel.Debug, "GM {0} authenticated ingame.", character.Name);
character.DropMessage("Admin level is {0}", character.Client.Admin);
}