|
|
#region EgyArmy[EG] Drop System
#region Easy Drop [- 5 and 10 Cps And Metor]
if (killer != null && killer.PlayerFlag == Game.PlayerFlag.Player)
{
byte times = (byte)Kernel.Random.Next(1, 1);
byte ref_times = (byte)Kernel.Random.Next(1, 60);
for (byte i = 0; i < times; i++)
{
uint Uid = 0;
byte type = (byte)Kernel.Random.Next(1, 60);
switch (type)
{
case 1: Uid = 721016; break;// 5 cps pag
case 2: Uid = 721016; break;// 5 cps pag
case 3: Uid = 721017; break;// 10cps pag
case 4: Uid = 721017; break;// 10cps pag
case 5: Uid = 1088001; break; // Metor
}
if (Uid != 0)
{
ushort X = Owner.X, Y = Owner.Y;
Game.Map Map = Kernel.Maps[Owner.MapID];
if (Map.SelectCoordonates(ref X, ref Y))
{
Network.GamePackets.MsgMapItem floorItem = new Network.GamePackets.MsgMapItem(true);
floorItem.Item = new Network.GamePackets.MsgItemInfo(true);
floorItem.Item.Color = (Game.Enums.Color)Kernel.Random.Next(4, 60);
floorItem.Item.ID = Uid;
floorItem.Item.MaximDurability = floorItem.Item.Durability = 65535;
floorItem.Item.UID = Network.GamePackets.MsgItemInfo.ItemUID.Next;
floorItem.ValueType = Network.GamePackets.MsgMapItem.FloorValueType.Item;
floorItem.ItemID = Uid;
floorItem.MapID = Owner.MapID;
floorItem.MapObjType = Game.MapObjectType.Item;
floorItem.X = X;
floorItem.Y = Y;
floorItem.Type = Network.GamePackets.MsgMapItem.Drop;
floorItem.OnFloor = Time32.Now;
floorItem.ItemColor = floorItem.Item.Color;
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
while (Map.Npcs.ContainsKey(floorItem.UID))
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
Map.AddFloorItem(floorItem);
SendScreenSpawn(floorItem);
}
}
}
}
#endregion
#region Medium Drob [+ 25 CPS And ExpBall(Event)]
if (killer != null && killer.PlayerFlag == Game.PlayerFlag.Player)
{
byte times = (byte)Kernel.Random.Next(1, 1);
byte ref_times = (byte)Kernel.Random.Next(1, 120);
for (byte i = 0; i < times; i++)
{
uint Uid = 0;
byte type = (byte)Kernel.Random.Next(1, 120);
switch (type)
{
case 1: Uid = 721019; break;// 25 cps pag
case 3: Uid = 723911; break;// ExpBall(Event)
}
if (Uid != 0)
{
ushort X = Owner.X, Y = Owner.Y;
Game.Map Map = Kernel.Maps[Owner.MapID];
if (Map.SelectCoordonates(ref X, ref Y))
{
Network.GamePackets.MsgMapItem floorItem = new Network.GamePackets.MsgMapItem(true);
floorItem.Item = new Network.GamePackets.MsgItemInfo(true);
floorItem.Item.Color = (Game.Enums.Color)Kernel.Random.Next(1, 100);
floorItem.Item.ID = Uid;
floorItem.Item.MaximDurability = floorItem.Item.Durability = 65535;
floorItem.Item.UID = Network.GamePackets.MsgItemInfo.ItemUID.Next;
floorItem.ValueType = Network.GamePackets.MsgMapItem.FloorValueType.Item;
floorItem.ItemID = Uid;
floorItem.MapID = Owner.MapID;
floorItem.MapObjType = Game.MapObjectType.Item;
floorItem.X = X;
floorItem.Y = Y;
floorItem.Type = Network.GamePackets.MsgMapItem.Drop;
floorItem.OnFloor = Time32.Now;
floorItem.ItemColor = floorItem.Item.Color;
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
while (Map.Npcs.ContainsKey(floorItem.UID))
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
Map.AddFloorItem(floorItem);
SendScreenSpawn(floorItem);
}
}
}
}
#endregion
#region Very Hard Drop [+ DB ]
if (killer != null && killer.PlayerFlag == Game.PlayerFlag.Player)
{
byte times = (byte)Kernel.Random.Next(1, 1);
byte ref_times = (byte)Kernel.Random.Next(1, 280);
for (byte i = 0; i < times; i++)
{
uint Uid = 0;
byte type = (byte)Kernel.Random.Next(1, 280);
switch (type)
{
case 1: Uid = 1088000; break;// dragonBall
}
if (Uid != 0)
{
ushort X = Owner.X, Y = Owner.Y;
Game.Map Map = Kernel.Maps[Owner.MapID];
if (Map.SelectCoordonates(ref X, ref Y))
{
Network.GamePackets.MsgMapItem floorItem = new Network.GamePackets.MsgMapItem(true);
floorItem.Item = new Network.GamePackets.MsgItemInfo(true);
floorItem.Item.Color = (Game.Enums.Color)Kernel.Random.Next(1, 100);
floorItem.Item.ID = Uid;
floorItem.Item.MaximDurability = floorItem.Item.Durability = 65535;
floorItem.Item.UID = Network.GamePackets.MsgItemInfo.ItemUID.Next;
floorItem.ValueType = Network.GamePackets.MsgMapItem.FloorValueType.Item;
floorItem.ItemID = Uid;
floorItem.MapID = Owner.MapID;
floorItem.MapObjType = Game.MapObjectType.Item;
floorItem.X = X;
floorItem.Y = Y;
floorItem.Type = Network.GamePackets.MsgMapItem.Drop;
floorItem.OnFloor = Time32.Now;
floorItem.ItemColor = floorItem.Item.Color;
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
while (Map.Npcs.ContainsKey(floorItem.UID))
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
Map.AddFloorItem(floorItem);
SendScreenSpawn(floorItem);
}
}
}
}
#endregion
// VIP Cps Drop
#region Drop Cps VIP 4
if (killer.VIPLevel == 4 || killer.VIPLevel == 5 || killer.VIPLevel == 6)
if (Kernel.Rate(100))
{
Random R = new Random();
int Nr = R.Next(1, 5);
if (Nr == 1)
{
byte type = (byte)Kernel.Random.Next(1, 80);
killer.ConquerPoints += 5;
//killer.Owner.LoadItemStats();
killer.Owner.Send(new Network.GamePackets.MsgTalk(" You have got 5 Cps #38#37#37 .", System.Drawing.Color.DarkBlue, 255));
}
if (Nr == 2)
{
byte type = (byte)Kernel.Random.Next(1, 120);
killer.ConquerPoints += 10;
killer.Owner.LoadItemStats();
killer.Owner.Send(new Network.GamePackets.MsgTalk(" You have got 10 Cps #38#37#37 .", System.Drawing.Color.DarkBlue, 255));
}
if (Nr == 3)
{
byte type = (byte)Kernel.Random.Next(1, 120);
killer.ConquerPoints += 10;
// killer.Owner.LoadItemStats();
killer.Owner.Send(new Network.GamePackets.MsgTalk(" You have got 10 Cps #38#37#37 .", System.Drawing.Color.DarkBlue, 255));
}
if (Nr == 4)
{
byte type = (byte)Kernel.Random.Next(1, 180);
killer.ConquerPoints += 25;
//killer.Owner.LoadItemStats();
killer.Owner.Send(new Network.GamePackets.MsgTalk(" You have got 25 Cps #38#37#37 .", System.Drawing.Color.DarkBlue, 255));
}
if (Nr == 5)
{
killer.ConquerPoints += 200;
// killer.Owner.LoadItemStats();
killer.Owner.Send(new Network.GamePackets.MsgTalk(" You have got 200 Cps #38#37#37 .", System.Drawing.Color.DarkBlue, 255));
}
}
#endregion
#endregion
if (killer.owner.player.viplevel >= 4)
{
killer.conquerpoints += 1000;
}else
#region EgyArmy[EG] Drop System
#region Easy Drop [- 5 and 10 Cps And Metor]
if (killer != null && killer.PlayerFlag == Game.PlayerFlag.Player)
{
byte times = (byte)Kernel.Random.Next(1, 1);
byte ref_times = (byte)Kernel.Random.Next(1, 60);
for (byte i = 0; i < times; i++)
{
uint Uid = 0;
byte type = (byte)Kernel.Random.Next(1, 60);
switch (type)
{
case 1: Uid = 721016; break;// 5 cps pag
case 2: Uid = 721016; break;// 5 cps pag
case 3: Uid = 721017; break;// 10cps pag
case 4: Uid = 721017; break;// 10cps pag
case 5: Uid = 1088001; break; // Metor
}
if (Uid != 0)
{
ushort X = Owner.X, Y = Owner.Y;
Game.Map Map = Kernel.Maps[Owner.MapID];
if (Map.SelectCoordonates(ref X, ref Y))
{
Network.GamePackets.MsgMapItem floorItem = new Network.GamePackets.MsgMapItem(true);
floorItem.Item = new Network.GamePackets.MsgItemInfo(true);
floorItem.Item.Color = (Game.Enums.Color)Kernel.Random.Next(4, 60);
floorItem.Item.ID = Uid;
floorItem.Item.MaximDurability = floorItem.Item.Durability = 65535;
floorItem.Item.UID = Network.GamePackets.MsgItemInfo.ItemUID.Next;
floorItem.ValueType = Network.GamePackets.MsgMapItem.FloorValueType.Item;
floorItem.ItemID = Uid;
floorItem.MapID = Owner.MapID;
floorItem.MapObjType = Game.MapObjectType.Item;
floorItem.X = X;
floorItem.Y = Y;
floorItem.Type = Network.GamePackets.MsgMapItem.Drop;
floorItem.OnFloor = Time32.Now;
floorItem.ItemColor = floorItem.Item.Color;
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
while (Map.Npcs.ContainsKey(floorItem.UID))
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
Map.AddFloorItem(floorItem);
SendScreenSpawn(floorItem);
}
}
}
}
#endregion
#region Medium Drob [+ 25 CPS And ExpBall(Event)]
if (killer != null && killer.PlayerFlag == Game.PlayerFlag.Player)
{
byte times = (byte)Kernel.Random.Next(1, 1);
byte ref_times = (byte)Kernel.Random.Next(1, 120);
for (byte i = 0; i < times; i++)
{
uint Uid = 0;
byte type = (byte)Kernel.Random.Next(1, 120);
switch (type)
{
case 1: Uid = 721019; break;// 25 cps pag
case 3: Uid = 723911; break;// ExpBall(Event)
}
if (Uid != 0)
{
ushort X = Owner.X, Y = Owner.Y;
Game.Map Map = Kernel.Maps[Owner.MapID];
if (Map.SelectCoordonates(ref X, ref Y))
{
Network.GamePackets.MsgMapItem floorItem = new Network.GamePackets.MsgMapItem(true);
floorItem.Item = new Network.GamePackets.MsgItemInfo(true);
floorItem.Item.Color = (Game.Enums.Color)Kernel.Random.Next(1, 100);
floorItem.Item.ID = Uid;
floorItem.Item.MaximDurability = floorItem.Item.Durability = 65535;
floorItem.Item.UID = Network.GamePackets.MsgItemInfo.ItemUID.Next;
floorItem.ValueType = Network.GamePackets.MsgMapItem.FloorValueType.Item;
floorItem.ItemID = Uid;
floorItem.MapID = Owner.MapID;
floorItem.MapObjType = Game.MapObjectType.Item;
floorItem.X = X;
floorItem.Y = Y;
floorItem.Type = Network.GamePackets.MsgMapItem.Drop;
floorItem.OnFloor = Time32.Now;
floorItem.ItemColor = floorItem.Item.Color;
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
while (Map.Npcs.ContainsKey(floorItem.UID))
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
Map.AddFloorItem(floorItem);
SendScreenSpawn(floorItem);
}
}
}
}
#endregion
#region Very Hard Drop [+ DB ]
if (killer != null && killer.PlayerFlag == Game.PlayerFlag.Player)
{
byte times = (byte)Kernel.Random.Next(1, 1);
byte ref_times = (byte)Kernel.Random.Next(1, 280);
for (byte i = 0; i < times; i++)
{
uint Uid = 0;
byte type = (byte)Kernel.Random.Next(1, 280);
switch (type)
{
case 1: Uid = 1088000; break;// dragonBall
}
if (Uid != 0)
{
ushort X = Owner.X, Y = Owner.Y;
Game.Map Map = Kernel.Maps[Owner.MapID];
if (Map.SelectCoordonates(ref X, ref Y))
{
Network.GamePackets.MsgMapItem floorItem = new Network.GamePackets.MsgMapItem(true);
floorItem.Item = new Network.GamePackets.MsgItemInfo(true);
floorItem.Item.Color = (Game.Enums.Color)Kernel.Random.Next(1, 100);
floorItem.Item.ID = Uid;
floorItem.Item.MaximDurability = floorItem.Item.Durability = 65535;
floorItem.Item.UID = Network.GamePackets.MsgItemInfo.ItemUID.Next;
floorItem.ValueType = Network.GamePackets.MsgMapItem.FloorValueType.Item;
floorItem.ItemID = Uid;
floorItem.MapID = Owner.MapID;
floorItem.MapObjType = Game.MapObjectType.Item;
floorItem.X = X;
floorItem.Y = Y;
floorItem.Type = Network.GamePackets.MsgMapItem.Drop;
floorItem.OnFloor = Time32.Now;
floorItem.ItemColor = floorItem.Item.Color;
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
while (Map.Npcs.ContainsKey(floorItem.UID))
floorItem.UID = Network.GamePackets.MsgMapItem.FloorUID.Next;
Map.AddFloorItem(floorItem);
SendScreenSpawn(floorItem);
}
}
}
}
#endregion
// VIP Cps Drop
#region Drop Cps VIP 4
if (killer.VIPLevel == 4 || killer.VIPLevel == 5 || killer.VIPLevel == 6)
if (Kernel.Rate(100))
{
Random R = new Random();
int Nr = R.Next(1, 5);
if (Nr == 1)
{
byte type = (byte)Kernel.Random.Next(1, 80);
killer.ConquerPoints += 5;
//killer.Owner.LoadItemStats();
killer.Owner.Send(new Network.GamePackets.MsgTalk(" You have got 5 Cps #38#37#37 .", System.Drawing.Color.DarkBlue, 255));
}
if (Nr == 2)
{
byte type = (byte)Kernel.Random.Next(1, 120);
killer.ConquerPoints += 10;
killer.Owner.LoadItemStats();
killer.Owner.Send(new Network.GamePackets.MsgTalk(" You have got 10 Cps #38#37#37 .", System.Drawing.Color.DarkBlue, 255));
}
if (Nr == 3)
{
byte type = (byte)Kernel.Random.Next(1, 120);
killer.ConquerPoints += 10;
// killer.Owner.LoadItemStats();
killer.Owner.Send(new Network.GamePackets.MsgTalk(" You have got 10 Cps #38#37#37 .", System.Drawing.Color.DarkBlue, 255));
}
if (Nr == 4)
{
byte type = (byte)Kernel.Random.Next(1, 180);
killer.ConquerPoints += 25;
//killer.Owner.LoadItemStats();
killer.Owner.Send(new Network.GamePackets.MsgTalk(" You have got 25 Cps #38#37#37 .", System.Drawing.Color.DarkBlue, 255));
}
if (Nr == 5)
{
killer.ConquerPoints += 200;
// killer.Owner.LoadItemStats();
killer.Owner.Send(new Network.GamePackets.MsgTalk(" You have got 200 Cps #38#37#37 .", System.Drawing.Color.DarkBlue, 255));
}
}
#endregion
#endregion
}
if (killer.owner.player.viplevel >= 4)
{
killer.conquerpoints += 1000;
}else
#region egyarmy[eg] drop system
#region easy drop [- 5 and 10 cps and metor]
if (killer != null && killer.playerflag == game.playerflag.player)
{
byte times = (byte)kernel.random.next(1, 1);
byte ref_times = (byte)kernel.random.next(1, 60);
for (byte i = 0; i < times; i++)
{
uint uid = 0;
byte type = (byte)kernel.random.next(1, 60);
switch (type)
{
case 1: Uid = 721016; break;// 5 cps pag
case 2: Uid = 721016; break;// 5 cps pag
case 3: Uid = 721017; break;// 10cps pag
case 4: Uid = 721017; break;// 10cps pag
case 5: Uid = 1088001; break; // metor
}
if (uid != 0)
{
ushort x = owner.x, y = owner.y;
game.map map = kernel.maps[owner.mapid];
if (map.selectcoordonates(ref x, ref y))
{
network.gamepackets.msgmapitem flooritem = new network.gamepackets.msgmapitem(true);
flooritem.item = new network.gamepackets.msgiteminfo(true);
flooritem.item.color = (game.enums.color)kernel.random.next(4, 60);
flooritem.item.id = uid;
flooritem.item.maximdurability = flooritem.item.durability = 65535;
flooritem.item.uid = network.gamepackets.msgiteminfo.itemuid.next;
flooritem.valuetype = network.gamepackets.msgmapitem.floorvaluetype.item;
flooritem.itemid = uid;
flooritem.mapid = owner.mapid;
flooritem.mapobjtype = game.mapobjecttype.item;
flooritem.x = x;
flooritem.y = y;
flooritem.type = network.gamepackets.msgmapitem.drop;
flooritem.onfloor = time32.now;
flooritem.itemcolor = flooritem.item.color;
flooritem.uid = network.gamepackets.msgmapitem.flooruid.next;
while (map.npcs.containskey(flooritem.uid))
flooritem.uid = network.gamepackets.msgmapitem.flooruid.next;
map.addflooritem(flooritem);
sendscreenspawn(flooritem);
}
}
}
}
#endregion
#region medium drob [+ 25 cps and expball(event)]
if (killer != null && killer.playerflag == game.playerflag.player)
{
byte times = (byte)kernel.random.next(1, 1);
byte ref_times = (byte)kernel.random.next(1, 120);
for (byte i = 0; i < times; i++)
{
uint uid = 0;
byte type = (byte)kernel.random.next(1, 120);
switch (type)
{
case 1: Uid = 721019; break;// 25 cps pag
case 3: Uid = 723911; break;// expball(event)
}
if (uid != 0)
{
ushort x = owner.x, y = owner.y;
game.map map = kernel.maps[owner.mapid];
if (map.selectcoordonates(ref x, ref y))
{
network.gamepackets.msgmapitem flooritem = new network.gamepackets.msgmapitem(true);
flooritem.item = new network.gamepackets.msgiteminfo(true);
flooritem.item.color = (game.enums.color)kernel.random.next(1, 100);
flooritem.item.id = uid;
flooritem.item.maximdurability = flooritem.item.durability = 65535;
flooritem.item.uid = network.gamepackets.msgiteminfo.itemuid.next;
flooritem.valuetype = network.gamepackets.msgmapitem.floorvaluetype.item;
flooritem.itemid = uid;
flooritem.mapid = owner.mapid;
flooritem.mapobjtype = game.mapobjecttype.item;
flooritem.x = x;
flooritem.y = y;
flooritem.type = network.gamepackets.msgmapitem.drop;
flooritem.onfloor = time32.now;
flooritem.itemcolor = flooritem.item.color;
flooritem.uid = network.gamepackets.msgmapitem.flooruid.next;
while (map.npcs.containskey(flooritem.uid))
flooritem.uid = network.gamepackets.msgmapitem.flooruid.next;
map.addflooritem(flooritem);
sendscreenspawn(flooritem);
}
}
}
}
#endregion
#region very hard drop [+ db ]
if (killer != null && killer.playerflag == game.playerflag.player)
{
byte times = (byte)kernel.random.next(1, 1);
byte ref_times = (byte)kernel.random.next(1, 280);
for (byte i = 0; i < times; i++)
{
uint uid = 0;
byte type = (byte)kernel.random.next(1, 280);
switch (type)
{
case 1: Uid = 1088000; break;// dragonball
}
if (uid != 0)
{
ushort x = owner.x, y = owner.y;
game.map map = kernel.maps[owner.mapid];
if (map.selectcoordonates(ref x, ref y))
{
network.gamepackets.msgmapitem flooritem = new network.gamepackets.msgmapitem(true);
flooritem.item = new network.gamepackets.msgiteminfo(true);
flooritem.item.color = (game.enums.color)kernel.random.next(1, 100);
flooritem.item.id = uid;
flooritem.item.maximdurability = flooritem.item.durability = 65535;
flooritem.item.uid = network.gamepackets.msgiteminfo.itemuid.next;
flooritem.valuetype = network.gamepackets.msgmapitem.floorvaluetype.item;
flooritem.itemid = uid;
flooritem.mapid = owner.mapid;
flooritem.mapobjtype = game.mapobjecttype.item;
flooritem.x = x;
flooritem.y = y;
flooritem.type = network.gamepackets.msgmapitem.drop;
flooritem.onfloor = time32.now;
flooritem.itemcolor = flooritem.item.color;
flooritem.uid = network.gamepackets.msgmapitem.flooruid.next;
while (map.npcs.containskey(flooritem.uid))
flooritem.uid = network.gamepackets.msgmapitem.flooruid.next;
map.addflooritem(flooritem);
sendscreenspawn(flooritem);
}
}
}
}
#endregion
// vip cps drop
#region drop cps vip 4
if (killer.viplevel == 4 || killer.viplevel == 5 || killer.viplevel == 6)
if (kernel.rate(100))
{
random r = new random();
int nr = r.next(1, 5);
if (nr == 1)
{
byte type = (byte)kernel.random.next(1, 80);
killer.conquerpoints += 5;
//killer.owner.loaditemstats();
killer.owner.send(new network.gamepackets.msgtalk(" you have got 5 cps #38#37#37 .", system.drawing.color.darkblue, 255));
}
if (nr == 2)
{
byte type = (byte)kernel.random.next(1, 120);
killer.conquerpoints += 10;
killer.owner.loaditemstats();
killer.owner.send(new network.gamepackets.msgtalk(" you have got 10 cps #38#37#37 .", system.drawing.color.darkblue, 255));
}
if (nr == 3)
{
byte type = (byte)kernel.random.next(1, 120);
killer.conquerpoints += 10;
// killer.owner.loaditemstats();
killer.owner.send(new network.gamepackets.msgtalk(" you have got 10 cps #38#37#37 .", system.drawing.color.darkblue, 255));
}
if (nr == 4)
{
byte type = (byte)kernel.random.next(1, 180);
killer.conquerpoints += 25;
//killer.owner.loaditemstats();
killer.owner.send(new network.gamepackets.msgtalk(" you have got 25 cps #38#37#37 .", system.drawing.color.darkblue, 255));
}
if (nr == 5)
{
killer.conquerpoints += 200;
// killer.owner.loaditemstats();
killer.owner.send(new network.gamepackets.msgtalk(" you have got 200 cps #38#37#37 .", system.drawing.color.darkblue, 255));
}
}
#endregion
#endregion
}
|
الذين يشاهدون محتوى الموضوع الآن : 1 ( الأعضاء 0 والزوار 1) | |
|
الموضوع | كاتب الموضوع | المنتدى | مشاركات | آخر مشاركة |
طلب بخصوص الدروب الوحوش الكبيرة | abdocoder | مشكلات السيرفيرات كونكر الشخصيه | 2 | 2020-05-02 05:00 AM |
بخصوص الدروب | stevenayman1 | مشكلات السيرفيرات كونكر الشخصيه | 6 | 2020-04-04 05:14 PM |
بخصوص الحروب | xAttack | مشكلات السيرفيرات كونكر الشخصيه | 4 | 2019-11-17 06:36 AM |
طلب بخصوص الحروب | osama | مشكلات السيرفيرات كونكر الشخصيه | 6 | 2019-08-07 04:49 AM |
حاجه بخصوص الحروب | uncelsam | مشكلات السيرفيرات كونكر الشخصيه | 5 | 2019-07-14 05:12 PM |