منتدي اكواد

منتدي اكواد (https://code.vpscairo.com/index.php)
-   تطوير سيرفرات كونكر (https://code.vpscairo.com/forumdisplay.php?f=11)
-   -   FreezeWar بفكره جديده (https://code.vpscairo.com/showthread.php?t=3261)

midoazoz 2019-12-09 03:45 AM

FreezeWar بفكره جديده
 
السلام عليكم في البدايه حابب اشكر ريدار معرفش ليه بس بجد انا بتعلم منه جدا واخويا الكبير ومش انا بس الي بقول كده ربنا يجعله في ميزان حسناته
ثانيه
بمناسبه الموضوع ده
عفواً لايمكن عرض الروابط إلا بعد الرد على الموضوع

انا عملته وخلصته بنسبه 90% او اكتر

عموما هفاجاكم قريب

نخش ع الموضوع فريز وار

الي هي دي

عفواً لايمكن عرض الروابط إلا بعد الرد على الموضوع

نخش ع الاضافات ع طول

================================================== ==========================================

خش يباشا ع الان بي سي

كود PHP:

#region freeze war 
                    
case 2413124:
                    case 
2413123:
                        {
                            switch (
npcRequest.OptionID)
                            {
                                case 
0:
                                    {
                                        
dialog.Text(" Ahlan Wsahln " client.Player.Name " hda5lk elfreeze war bas lazm elwa2t yb2a xx:40 to xx:42");
                                        
dialog.Text("enta ma3ak FreezePoints = [ " client.Player.FreezePoints " ] ");
                                        
dialog.Option("yla da5lny"1);
                                        
dialog.Option("3awz tbadl el Freeze Points "2);
                                        
dialog.Send();
                                        break;
                                    }
                                case 
1:
                                    {
                                        if (
DateTime.Now.Minute >= 40 && DateTime.Now.Minute <= 42)
                                        {
                                            
client.Player.RemoveFlag((ulong)MsgUpdate.Flags.Ride);
                                            
client.Player.PKMode Game.Enums.PKMode.PK;
                                            
client.Send(new MsgAction(true) { UID client.Player.UIDID MsgAction.Mode.ChangePKModedwParam = (uint)client.Player.PKMode });
                                            
client.Player.Update(MsgName.Mode.Effect"zf2-e360"true);
                                            
Random R = new Random();
                                            
int Nr R.Next(110);
                                            if (
Nr == 1client.Player.Teleport(1505293300);
                                            if (
Nr == 2client.Player.Teleport(1505298284);
                                            if (
Nr == 3client.Player.Teleport(1505314284);
                                            if (
Nr == 4client.Player.Teleport(1505302272);
                                            if (
Nr == 5client.Player.Teleport(1505291267);
                                            if (
Nr == 6client.Player.Teleport(1505321273);
                                            if (
Nr == 7client.Player.Teleport(1505308256);
                                            if (
Nr == 8client.Player.Teleport(1505292258);
                                            if (
Nr == 9client.Player.Teleport(1505278294);
                                            if (
Nr == 10client.Player.Teleport(1505321260);
                                        }
                                        else
                                        {
                                            
dialog.Text("Yasta Bt5ta8l 3la xx:40 to xx:42 bs ");
                                            
dialog.Send();
                                        }
                                        break;
                                    }
                                case 
2:
                                    {
                                        
dialog.Text("ta2dar t8ayr El FreezePoints by ay 7aga mn dool , enta ma3ak " client.Player.FreezePoints " FreezePoints ");
                                        
dialog.Option("P6DragonSoul[Random][500 Points]"3);
                                        
dialog.Option("P7SoulPack[Random][1000Points]"4);
                                        
dialog.Option("P7WeaponSoulPack[YouWant][1500Points]"5);
                                        
dialog.Option("P7EquipmentSoulPack[YouWant][1500Points]"6);
                                        
dialog.Option("SplendidStarStone[300Points]"7);
                                        
dialog.Send();
                                        break;
                                    }
                                case 
3:
                                    {
                                        if (
client.Player.FreezePoints >= 500)
                                        {
                                            
client.Player.FreezePoints -= 500;
                                            
client.Inventory.Add(300338201);
                                        }
                                        else
                                        {
                                            
dialog.Text("Lazm yb2a ma3ak 500 Points");
                                            
dialog.Send();

                                        }
                                        break;
                                    }
                                case 
4:
                                    {
                                        if (
client.Player.FreezePoints >= 1000)
                                        {
                                            
client.Player.FreezePoints -= 1000;
                                            
client.Inventory.Add(300805501);
                                        }
                                        else
                                        {
                                            
dialog.Text("Lazm yb2a ma3ak 1000 Points");
                                            
dialog.Send();

                                        }
                                        break;
                                    }
                                case 
5:
                                    {
                                        if (
client.Player.FreezePoints >= 1500)
                                        {
                                            
client.Player.FreezePoints -= 1500;
                                            
client.Inventory.Add(300424701);
                                        }
                                        else
                                        {
                                            
dialog.Text("Lazm yb2a ma3ak 1500 Points");
                                            
dialog.Send();

                                        }
                                        break;
                                    }
                                case 
6:
                                    {
                                        if (
client.Player.FreezePoints >= 1500)
                                        {
                                            
client.Player.FreezePoints -= 1500;
                                            
client.Inventory.Add(300424801);
                                        }
                                        else
                                        {
                                            
dialog.Text("Lazm yb2a ma3ak 1500 Points");
                                            
dialog.Send();

                                        }
                                        break;
                                    }
                                case 
7:
                                    {
                                        if (
client.Player.FreezePoints >= 300)
                                        {
                                            
client.Player.FreezePoints -= 300;
                                            
client.Inventory.Add(300900301);
                                        }
                                        else
                                        {
                                            
dialog.Text("Lazm yb2a ma3ak 300 Points");
                                            
dialog.Send();

                                        }
                                        break;
                                    }      
                            }
                            break;
                        }
                    
#endregion 

بعدين في

كود PHP:

player.cs   او   Entity.cs 

هتبحث عن

كود PHP:

public void Die(Player killer

ضيف ده تحت القوس

كود PHP:

#region FreezeWar
            
if (killer.MapID == 1505)
            {
                
DateTime Now64 DateTime.Now;
                if (
Now64.Minute >= 42 && Now64.Minute 45)
                {
                    if (
DateTime.Now >= FrozenTime1.AddSeconds(15))
                    {
                        for (
uint x 1<= 1x++)
                        {
                            
X;
                            
Y;
                            
killer.FreezePoints += 10;
                            
Hitpoints MaxHitpoints;
                            
Stamina 100;
                            
string Mesage "";
                            
Mesage "Your FreezePoints .: " killer.FreezePoints "";
                            
MsgTalk msg = new MsgTalk(MesageSystem.Drawing.Color.Red== MsgTalk.FirstRightCorner MsgTalk.ContinueRightCorner);
                            
killer.Owner.Send(msg);
                            
RemoveFlag((ulong)MsgUpdate.Flags.Dead);
                            
RemoveFlag((ulong)MsgUpdate.Flags.Ghost);
                            
Teleport(1505XY);
                            
AddFlag((ulong)MsgUpdate.Flags.Freeze);
                            
FrozenTime 15;
                            
MsgRaceTrackStatus update = new MsgRaceTrackStatus(true);
                            
update.UID UID;
                            
update.Add(MsgRaceTrackStatus.Freeze015);
                            
Owner.SendScreen(updatetrue);
                            
TransformationID 0;
                            
Ressurect();
                            
FrozenTime1 DateTime.Now;
                            
FrozenStamp Time32.Now;
                        }

                    }
                    else
                    {
                        
TransformationID 0;
                        
Ressurect();
                        
Stamina 100;
                        
Hitpoints MaxHitpoints;
                        
RemoveFlag((ulong)MsgUpdate.Flags.Dead);
                        
RemoveFlag((ulong)MsgUpdate.Flags.Ghost);
                    }
                    return;
                }
            }
            
#endregion 

طبعا ايرورات سهله

ف اول الكلاس ضيف دول

كود PHP:

public DateTime FrozenTime1

كود PHP:

public uint FreezePoints

كود PHP:

public int FrozenTime

كود PHP:

public Time32 FrozenStamp

الي موجود منهم خلاص مش لازم تضيفه

نخش thread
كود PHP:

#region freeze war system 
            
if (Now64.Minute == 40 && Now64.Second == 10)
            {
                
Kernel.SendWorldMessage(new MsgTalk("7arb el Freeze war start ma3ak 2 min 34an tsagl feha !"Color.WhiteMsgTalk.Center), Kernel.GamePool.Values.ToArray());
                foreach (var 
clientX in Kernel.GamePool.Values)
                    
clientX.MessageBox("7arb el Freeze war start, yla sagl bsr3a? ?",
                  
=> {
                      
                          
p.Player.Teleport(1002309250);
                  }, 
null60);
            }
            if (
Now64.Minute == 42 && Now64.Second == 00)
            {
                foreach (var 
clientX in Kernel.GamePool.Values)
                {
                    if (
clientX.Player.MapID == 1505)
                    {
                        
Constants.PKForbiddenMaps.Remove(1505);
                        
Constants.PKFreeMaps.Add(1505);
                        
clientX.Player.AddFlag((ulong)MsgUpdate.Flags.Freeze);
                        
Kernel.SendWorldMessage(new MsgTalk("El7arb bdat ya rgala kol wa7d b 10 FreezePoints #33 !"Color.WhiteMsgTalk.Center), Kernel.GamePool.Values.ToArray());
                    }
                }
            }
            if (
Now64.Minute == 45 && Now64.Second == 00)
            {
                foreach (var 
clientX in Kernel.GamePool.Values)
                {
                    if (
clientX.Player.MapID == 1505)
                    {
                        
Constants.PKFreeMaps.Remove(1505);
                        
Constants.PKForbiddenMaps.Add(1505);
                            
clientX.Player.Teleport(1002309250);
                        
Kernel.SendWorldMessage(new MsgTalk("El7arb 5last ya rgala #33 !"Color.WhiteMsgTalk.Center), Kernel.GamePool.Values.ToArray());
                    }
                }
            }
            
#endregion 


هتبحث عن

كود PHP:

BuffersCallback 

ضيف فيها

كود PHP:

#region Freeze
                
if (client.Player.ContainsFlag((ulong)MsgUpdate.Flags.Freeze))
                {
                    if (
Now client.Player.FrozenStamp.AddSeconds(client.Player.FrozenTime))
                    {
                        
client.Player.FrozenTime 0;
                        
client.Player.RemoveFlag((ulong)MsgUpdate.Flags.Freeze);
                        
MsgRaceTrackStatus update = new MsgRaceTrackStatus(true);
                        
update.UID client.Player.UID;
                        
update.Remove(MsgRaceTrackStatus.Freeze);
                        
client.SendScreen(updatetrue);
                    }
                }
                
#endregion 

هتخش ع constants.cs
هتبحث ع
كود PHP:

PKForbiddenMaps 

ضيف فيها 1505
=================================================
كدا خلصت اضافتي انا في السورسات مسج

اضافه السورسات العاديه مقدمه من HassanEmprator
======================
الان بي سي
كود PHP:

#region freeze war
                
case 2413124:
                case 
2413123:
                    {
                        switch (
npcRequest.OptionID)
                        {
                            case 
0:
                                {
                                    
dialog.Text(" Ahlan Wsahln " client.Entity.Name " hda5lk elfreeze war bas lazm elwa2t yb2a xx:40 to xx:42");
                                    
dialog.Text("enta ma3ak FreezePoints = [ " client.Entity.FreezePoints " ] ");
                                    
dialog.Option("yla da5lny"1);
                                    
dialog.Option("3awz tbadl el Freeze Points "2);
                                    
dialog.Send();
                                    break;
                                }
                            case 
1:
                                {
                                    if (
DateTime.Now.Minute >= 40 && DateTime.Now.Minute <= 42)
                                    {
                                        
client.Entity.RemoveFlag(Update.Flags.Ride);
                                        
client.Entity.PKMode Game.Enums.PKMode.PK;
                                        
client.Send(new Data(true) { UID client.Entity.UIDID Data.ChangePKModedwParam = (uint)client.Entity.PKMode });
                                        
client.Entity.Update(_String.Effect"zf2-e360"true);
                                        
Random R = new Random();
                                        
int Nr R.Next(110);
                                        if (
Nr == 1client.Entity.Teleport(1505293300);
                                        if (
Nr == 2client.Entity.Teleport(1505298284);
                                        if (
Nr == 3client.Entity.Teleport(1505314284);
                                        if (
Nr == 4client.Entity.Teleport(1505302272);
                                        if (
Nr == 5client.Entity.Teleport(1505291267);
                                        if (
Nr == 6client.Entity.Teleport(1505321273);
                                        if (
Nr == 7client.Entity.Teleport(1505308256);
                                        if (
Nr == 8client.Entity.Teleport(1505292258);
                                        if (
Nr == 9client.Entity.Teleport(1505278294);
                                        if (
Nr == 10client.Entity.Teleport(1505321260);
                                    }
                                    else
                                    {
                                        
dialog.Text("Yasta Bt5ta8l 3la xx:40 to xx:42 bs ");
                                        
dialog.Send();
                                    }
                                    break;
                                }
                            case 
2:
                                {
                                    
dialog.Text("ta2dar t8ayr El FreezePoints by ay 7aga mn dool , enta ma3ak " client.Entity.FreezePoints " FreezePoints ");
                                    
dialog.Option("P6DragonSoul[Random][500 Points]"3);
                                    
dialog.Option("P7SoulPack[Random][1000Points]"4);
                                    
dialog.Option("P7WeaponSoulPack[YouWant][1500Points]"5);
                                    
dialog.Option("P7EquipmentSoulPack[YouWant][1500Points]"6);
                                    
dialog.Option("SplendidStarStone[300Points]"7);
                                    
dialog.Send();
                                    break;
                                }
                            case 
3:
                                {
                                    if (
client.Entity.FreezePoints >= 500)
                                    {
                                        
client.Entity.FreezePoints -= 500;
                                        
client.Inventory.Add(300338201);
                                    }
                                    else
                                    {
                                        
dialog.Text("Lazm yb2a ma3ak 500 Points");
                                        
dialog.Send();

                                    }
                                    break;
                                }
                            case 
4:
                                {
                                    if (
client.Entity.FreezePoints >= 1000)
                                    {
                                        
client.Entity.FreezePoints -= 1000;
                                        
client.Inventory.Add(300805501);
                                    }
                                    else
                                    {
                                        
dialog.Text("Lazm yb2a ma3ak 1000 Points");
                                        
dialog.Send();

                                    }
                                    break;
                                }
                            case 
5:
                                {
                                    if (
client.Entity.FreezePoints >= 1500)
                                    {
                                        
client.Entity.FreezePoints -= 1500;
                                        
client.Inventory.Add(300424701);
                                    }
                                    else
                                    {
                                        
dialog.Text("Lazm yb2a ma3ak 1500 Points");
                                        
dialog.Send();

                                    }
                                    break;
                                }
                            case 
6:
                                {
                                    if (
client.Entity.FreezePoints >= 1500)
                                    {
                                        
client.Entity.FreezePoints -= 1500;
                                        
client.Inventory.Add(300424801);
                                    }
                                    else
                                    {
                                        
dialog.Text("Lazm yb2a ma3ak 1500 Points");
                                        
dialog.Send();

                                    }
                                    break;
                                }
                            case 
7:
                                {
                                    if (
client.Entity.FreezePoints >= 300)
                                    {
                                        
client.Entity.FreezePoints -= 300;
                                        
client.Inventory.Add(300900301);
                                    }
                                    else
                                    {
                                        
dialog.Text("Lazm yb2a ma3ak 300 Points");
                                        
dialog.Send();

                                    }
                                    break;
                                }
                        }
                        break;
                    }
                
#endregion 

ال في entity

كود PHP:

#region FreezeWar
            
if (killer.MapID == 1505)
            {
                
DateTime Now64 DateTime.Now;
                if (
Now64.Minute >= 42 && Now64.Minute 45)
                {
                    if (
DateTime.Now >= FrozenTime1.AddSeconds(15))
                    {
                        for (
uint x 1<= 1x++)
                        {
                            
X;
                            
Y;
                            
killer.FreezePoints += 10;
                            
Hitpoints MaxHitpoints;
                            
Stamina 100;
                            
string Mesage "";
                            
Mesage "Your FreezePoints .: " killer.FreezePoints "";
                            
Message msg = new Message(MesageSystem.Drawing.Color.Red== Message.FirstRightCorner Message.ContinueRightCorner);
                            
killer.Owner.Send(msg);
                            
RemoveFlag(Network.GamePackets.Update.Flags.Dead);
                            
RemoveFlag(Network.GamePackets.Update.Flags.Ghost);
                            
Teleport(1505XY);
                            
AddFlag(Network.GamePackets.Update.Flags.Freeze);
                            
FrozenTime 15;
                            
GameCharacterUpdates update = new GameCharacterUpdates(true);
                            
update.UID UID;
                            
update.Add(GameCharacterUpdates.Freeze015);
                            
Owner.SendScreen(updatetrue);
                            
TransformationID 0;
                            
Ressurect();
                            
FrozenTime1 DateTime.Now;
                            
FrozenStamp Time32.Now;
                        }

                    }
                    else
                    {
                        
TransformationID 0;
                        
Ressurect();
                        
Stamina 100;
                        
Hitpoints MaxHitpoints;
                        
RemoveFlag(Network.GamePackets.Update.Flags.Dead);
                        
RemoveFlag(Network.GamePackets.Update.Flags.Ghost);
                    }
                    return;
                }
            }
            
#endregion 

الي في world
كود PHP:

#region Frozen
            
if (client.Entity.ContainsFlag(Update.Flags.Freeze))
            {
                if (
Now client.Entity.FrozenStamp.AddSeconds(client.Entity.FrozenTime))
                {
                    
client.Entity.FrozenD false;
                    
client.Entity.FrozenTime 0;
                    
client.Entity.RemoveFlag(Update.Flags.Freeze);

                    
GameCharacterUpdates update = new GameCharacterUpdates(true);
                    
update.UID client.Entity.UID;
                    
update.Remove(GameCharacterUpdates.Freeze);
                    
client.SendScreen(updatetrue);
                }
            }
            
#endregion 

و

كود PHP:

if (Now64.Minute == 40 && Now64.Second == 10)
            {
                
Kernel.SendWorldMessage(new Message("7arb el Freeze war start ma3ak 2 min 34an tsagl feha !"Color.WhiteMessage.Center), Kernel.GamePool.Values.ToArray());
                foreach (var 
clientX in Kernel.GamePool.Values)
                    
clientX.MessageBox("7arb el Freeze war start, yla sagl bsr3a? ?",
                  
=> {
                      
                          
p.Entity.Teleport(1002309250);
                  }, 
null60);
            }
            if (
Now64.Minute == 42 && Now64.Second == 00)
            {
                foreach (var 
clientX in Kernel.GamePool.Values)
                {
                    if (
clientX.Entity.MapID == 1505)
                    {
                        
Constants.PKForbiddenMaps.Remove(1505);
                        
Constants.PKFreeMaps.Add(1505);
                        
clientX.Entity.AddFlag((Update.Flags.Freeze));
                        
Kernel.SendWorldMessage(new Message("El7arb bdat ya rgala kol wa7d b 10 FreezePoints #33 !"Color.WhiteMessage.Center), Kernel.GamePool.Values.ToArray());
                    }
                }
            }
            if (
Now64.Minute == 45 && Now64.Second == 00)
            {
                foreach (var 
clientX in Kernel.GamePool.Values)
                {
                    if (
clientX.Entity.MapID == 1505)
                    {
                        
Constants.PKFreeMaps.Remove(1505);
                        
Constants.PKForbiddenMaps.Add(1505);
                            
clientX.Entity.Teleport(1002309250);
                        
Kernel.SendWorldMessage(new Message("El7arb 5last ya rgala #33 !"Color.WhiteMessage.Center), Kernel.GamePool.Values.ToArray());
                    }
                }
            } 

والباقي زي مهو عادي يعني من فوق
=========================================
كده خلصنا من السورس ^_^

نخش ع القاعده

عفواً لايمكن عرض الروابط إلا بعد الرد على الموضوع

عفواً لايمكن عرض الروابط إلا بعد الرد على الموضوع

اظن واضح من الصوره

عشان لو الرابط باظ
هتيجي ع entities وتعمل design
وتضيف ده

كود PHP:

FreezePoints    bigint    16    0    0    0    -1    0    0    0    0                    0    0 

بعدين

ضيف الان بي سي

كود PHP:

2413123    FreezeWar    2    15500    1002    309    245 

بعدين الماب

كود PHP:

1505    1002    7    0 

يارب تكون الاضافه عجبتكو والسلام عليكم

Hassan Emprator 2019-12-09 03:46 AM

رد: FreezeWar بفكره جديده
 
يارب تكون الكويستت عجبتكو

والسلام عليكم ورحمه الله وبركاته :)

abuhaneen 2019-12-09 09:32 AM

رد: FreezeWar بفكره جديده
 
تسلم ع مجهودك العظيم

Rihanna 2019-12-09 10:11 AM

رد: FreezeWar بفكره جديده
 
good

ahmedfathy 2019-12-09 11:56 AM

رد: FreezeWar بفكره جديده
 
لو اللي في دماغي صح يبقي الله ينور عليك يا ميدو طب انت عملت الصح

محمد ياسر 2019-12-09 02:10 PM

رد: FreezeWar بفكره جديده
 
عاش والله

midoazoz 2019-12-09 02:44 PM

رد: FreezeWar بفكره جديده
 
اقتباس:

المشاركة الأصلية كتبت بواسطة hazem (المشاركة 24600)
عاش والله

انا اعترض سيدي القاضي الواد حسن انا منزل الاضافه لسورس عادي عدلها وكتب ان هو الي منزلها 😂😂😂😂

Hassan Emprator 2019-12-09 02:51 PM

رد: FreezeWar بفكره جديده
 
اقتباس:

المشاركة الأصلية كتبت بواسطة midoazoz (المشاركة 24602)
انا اعترض سيدي القاضي الواد حسن انا منزل الاضافه لسورس عادي عدلها وكتب ان هو الي منزلها 😂😂😂😂

ههههههههههههههه لا اننني مظلوم هاو كان قايلي فيس يا حضرت القاضي !

AliNasser 2019-12-09 02:58 PM

رد: FreezeWar بفكره جديده
 
تشلم

bebo100 2019-12-09 04:53 PM

رد: FreezeWar بفكره جديده
 
تسلم


الساعة الآن 01:15 AM

مرحبا بكم في منتدي اكواد لتطوير الالعاب