[Coding] Cool Effects

08/24/2008 12:30 kinshi88#1
Completed.
08/24/2008 12:34 keving#2
haha only you can see the Effect.
On my Server everybody can see it :P
08/24/2008 12:37 adz06676#3
Quote:
Originally Posted by keving View Post
haha only you can see the Effect.
On my Server everybody can see it :P
thats a very simple adjustment, anyone can do it.
08/24/2008 12:41 keving#4
Sure its simple but not anybody knows how to code :)
08/24/2008 13:14 kinshi88#5
@keving
I know how to make so everyone can see it, I know how to completely finish it.
What I posted is just the basic, so that people can help me with what I need; to make it so the effect only happens once.

If you have done it, then can you help me with my simple request?
08/24/2008 13:15 alexbigfoot#6
Quote:
Originally Posted by kinshi88 View Post
I've been working on the cool effects and, for the most part, I got them working.

I just can't figure out how to make the cool effect only happen once.

This is what I have so far:

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

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

                int ClassType = (int)Job;

                if (Other.ItemQuality(ItemId) == 9)
                {
                    if (Job == 10 || Job == 11 || Job == 12 || Job == 13 || Job == 14 || Job == 15)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "warrior-s"));
                    }
                    if (Job == 40 || Job == 41 || Job == 42 || Job == 43 || Job == 44 || Job == 45)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "archer-s"));
                    }
                    if (Job == 20 || Job == 21 || Job == 22 || Job == 23 || Job == 24 || Job == 25)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "fighter-s"));
                    }
                    if (Job == 132 || Job == 133 || Job == 134 || Job == 135)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "taoist-s"));
                    }
                    if (Job == 142 || Job == 143 || Job == 144 || Job == 145)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "taoist-s"));
                    }
                    if (Job == 100 || Job == 101)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "taoist-s"));
                    }
                }
            }
I've tried with cases, but they wouldn't work.


Any help would be greatly appreciated.

lol...after 1 thing like : MyClient.SendPacket(General.MyPackets.String(UID, 10, "taoist-s"));
add Action = 100;
08/24/2008 13:29 kinshi88#7
Yes I have thought of that. But that means that the player cannot use cool while doing cool, like in Official Conquer.
08/24/2008 17:07 alexbigfoot#8
lol...what do u mean?
08/24/2008 20:44 kinshi88#9
Nevermind, I wasn't thinking last night =P

Code:
MyClient.SendPacket(General.MyPackets.String(UID, 10, "taoist-s"));
Action = 100;
Works perfect, thanks. I'll release when I'm done.
08/24/2008 21:00 nTL3fTy#10
Easier?

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

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

                int ClassType = (int)Job;

                if (Other.ItemQuality(ItemId) == 9)
                {
                    if (Job >= 10 && Job <= 15)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "warrior-s"));
                    }
                    if (Job >= 40 && Job <= 45)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "archer-s"));
                    }
                    if (Job >= 20 && Job <= 25)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "fighter-s"));
                    }
                    if (Job >= 132 && Job <= 135)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "taoist-s"));
                    }
                    if (Job >= 142 && Job <= 145)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "taoist-s"));
                    }
                    if (Job == 100 || Job == 101)
                    {
                        MyClient.SendPacket(General.MyPackets.String(UID, 10, "taoist-s"));
                    }
                }
            }
08/24/2008 21:39 alexbigfoot#11
Quote:
Originally Posted by kinshi88 View Post
Nevermind, I wasn't thinking last night =P

Code:
MyClient.SendPacket(General.MyPackets.String(UID, 10, "taoist-s"));
Action = 100;
Works perfect, thanks. I'll release when I'm done.
You`re welcome!
08/25/2008 01:28 maCaCa_Nádia#12
Hey, I did this and works well, BUT, I got an error at that :

string[] Splitter = TheEquip.Split('-');

help ?
08/25/2008 05:55 kinshi88#13
Actually, doesn't work perfect, but, meh =P

Works just fine.
08/25/2008 14:15 gerble93#14
can you post the finial product?
08/25/2008 15:42 YukiXian#15
How to show the Effect to everyone?