[Coding] Cool Effects

08/25/2008 15:51 keving#16
YukiXian: That is so easy if you using you brain u get the solution :P

:)
08/25/2008 16:21 YukiXian#17
Well First at all, Were to place it ? :p

And...
Quote:
Originally Posted by keving View Post
YukiXian: That is so easy if you using you brain u get the solution :P

:)
Could you just tell me ? :D:p
08/25/2008 16:39 keving#18
Make an foreach for all Chars and simple send the effect for all to you :)
If you dont understand dont ask me pls :)
08/25/2008 18:58 YukiXian#19
Quote:
Originally Posted by keving View Post
Make an foreach for all Chars and simple send the effect for all to you :)
If you dont understand dont ask me pls :)

Ok, But were do I put the Action? In what .cs file?
08/25/2008 19:12 tao4229#20
Quote:
Originally Posted by keving View Post
Make an foreach for all Chars and simple send the effect for all to you :)
If you dont understand dont ask me pls :)
You'd probably want to do it just on the map or close by you, otherwise if you have a ton of people doing effects, it will lagg people who are tons of maps away, because it is sending the packets for the effects.. but they don't even need to see them.(Correct me If I'm wrong, I don't know much about the coding of Conquer D=<)

Edit: Here's the code ... I shortened it a bit ..

Code:
            if (Action == 230)//Cool Effect
            {
                string TheEquip = Equips[3];

                string[] Splitter = TheEquip.Split('-');
                uint ItemId = uint.Parse(Splitter[0]);

                int ClassType = (int)Job;
                string EfTy = "";

                if (Other.ItemQuality(ItemId) == 9)
                {
                    if (Job >= 10 && Job <= 15)
                    {
                        EfTy = "warrior-s";
                    }
                    if (Job >= 40 && Job <= 45)
                    {
                        EfTy = "archer-s";
                    }
                    if (Job >= 20 &&  Job <= 25)
                    {
                        EfTy = "figher-s";
                    }
                    if (Job >= 132 &&  Job <=145 || Job == 100 || Job == 101)
                    {
                        EfTy = "taoist-s";
                    }
                    foreach (DictionaryEntry DE in World.AllChars)
                    {
                        Character Charr = (Character)DE.Value;
                        if (Charr.LocMap == LocMap)
                        {
                            MyClient.SendPacket(General.MyPackets.String(UID, 10, EfTy));
                        }
                    }
                    Action = 100;
                }
            }
Probably something a tad bit wrong with that. Anyone can correct me.. Don't have a server to test on, and too lazy to set up one to test it out right now.
08/26/2008 07:11 kinshi88#21
Updated
08/26/2008 09:23 alexbigfoot#22
it works?
08/26/2008 09:27 alexbigfoot#23
Simple efects dont work.
08/26/2008 10:00 kinshi88#24
This isn't a release...
08/26/2008 13:25 Zanzibar#25
You mixed up the warrior effect with the trojan lol
08/26/2008 14:33 alexbigfoot#26
lolz...he/her (tell me if u read this topic) didnt mixed them :P just forgot to change //warrior effect and thats all
08/26/2008 14:34 alexbigfoot#27
and FullSuper() wont work fine...try this one:
Code:
        public void FullSuper()
        {
            if (Equips[1] != null && Equips[2] != null && Equips[3] != null && Equips[4] != null && Equips[8] != null && Equips[6] != null)
            {
                string TheEquip1 = Equips[1];
                string TheEquip2 = Equips[2];
                string TheEquip3 = Equips[3];
                string TheEquip4 = Equips[4];
                string TheEquip8 = Equips[8];
                string TheEquip6 = Equips[6];

                string[] Splitter1 = TheEquip1.Split('-');
                uint ItemId1 = uint.Parse(Splitter1[0]);

                string[] Splitter2 = TheEquip2.Split('-');
                uint ItemId2 = uint.Parse(Splitter2[0]);

                string[] Splitter3 = TheEquip3.Split('-');
                uint ItemId3 = uint.Parse(Splitter3[0]);

                string[] Splitter4 = TheEquip4.Split('-');
                uint ItemId4 = uint.Parse(Splitter4[0]);

                string[] Splitter8 = TheEquip8.Split('-');
                uint ItemId8 = uint.Parse(Splitter8[0]);

                string[] Splitter6 = TheEquip6.Split('-');
                uint ItemId6 = uint.Parse(Splitter6[0]);

                if (Other.ItemQuality(ItemId1) == 9 && Other.ItemQuality(ItemId2) == 9 && Other.ItemQuality(ItemId3) == 9 && Other.ItemQuality(ItemId4) == 9 && Other.ItemQuality(ItemId8) == 9 && Other.ItemQuality(ItemId6) == 9)
                {
                    AllSuper = true;
                }
            }
        }
08/26/2008 16:12 tao4229#28
Quote:
Originally Posted by alexbigfoot View Post
and FullSuper() wont work fine...try this one:
Code:
        public [U]bool[/U] FullSuper()
        {
            if (Equips[1] != null && Equips[2] != null && Equips[3] != null && Equips[4] != null && Equips[8] != null && Equips[6] != null)
            {
                string TheEquip1 = Equips[1];
                string TheEquip2 = Equips[2];
                string TheEquip3 = Equips[3];
                string TheEquip4 = Equips[4];
                string TheEquip8 = Equips[8];
                string TheEquip6 = Equips[6];

                string[] Splitter1 = TheEquip1.Split('-');
                uint ItemId1 = uint.Parse(Splitter1[0]);

                string[] Splitter2 = TheEquip2.Split('-');
                uint ItemId2 = uint.Parse(Splitter2[0]);

                string[] Splitter3 = TheEquip3.Split('-');
                uint ItemId3 = uint.Parse(Splitter3[0]);

                string[] Splitter4 = TheEquip4.Split('-');
                uint ItemId4 = uint.Parse(Splitter4[0]);

                string[] Splitter8 = TheEquip8.Split('-');
                uint ItemId8 = uint.Parse(Splitter8[0]);

                string[] Splitter6 = TheEquip6.Split('-');
                uint ItemId6 = uint.Parse(Splitter6[0]);

                if (Other.ItemQuality(ItemId1) == 9 && Other.ItemQuality(ItemId2) == 9 && Other.ItemQuality(ItemId3) == 9 && Other.ItemQuality(ItemId4) == 9 && Other.ItemQuality(ItemId8) == 9 && Other.ItemQuality(ItemId6) == 9)
                {
                    [U]return [/U] true;
                }
            }
        }
Why would you do it like that?... You make it like this.... (Editted up there) Then in your cool effect, you make a Bool FullSup = FullSuper(); and if you have full super it will return true and you can go from there.
08/26/2008 22:21 alexbigfoot#29
well...if u really wanna know without my add without full super nothing is going to happen
08/27/2008 00:11 tao4229#30
Quote:
Originally Posted by alexbigfoot View Post
well...if u really wanna know without my add without full super nothing is going to happen
Im just saying, the way I did it makes a lot more sense.. How would you use a void to check if they have supers..?