[Help Request] Broadcasting Messages [5165]

03/13/2010 03:36 -NewDawn-#1
Hey Everyone!
I decided that I'm going to just keep my 5165 source, thus I'm picking up where I left off. =]

This is my goal in the Broadcast System:
I want to be able to broadcast a message without CPs.

I started by doing this:
Code:
case 2050:
                            {
                                if (Data[4] == 3 && GC.MyChar.Silvers >= 100000)
                                {
                                    if (Game.World.BroadCastCount <= 100)
                                    {
                                        GC.MyChar.Silvers -= 100000;

                                        string Message = "";
                                        for (byte i = 0; i < Data[13]; i++)
                                            Message += Convert.ToChar(Data[14 + i]);


                                        Game.BroadCastMessage B = new NewestCOServer.Game.BroadCastMessage();
                                        B.Name = GC.MyChar.Name + GC.AuthInfo.Status;
                                        B.Message = Message;
                                        B.Place = Game.World.BroadCastCount;
                                        Game.World.BroadCasts[Game.World.BroadCastCount] = B;
                                        Game.World.BroadCastCount++;

                                        Data[8] = B.Place;
                                        GC.AddSend(Data);
                                    }
                                }
                                break;
                            }
After that, I tested it with 100 CPs in my pocket.
It worked....

Then my testers tried it and couldn't use it.
It requires 5 Cps to get to the Broadcast window (Packet 2050).

Help? =\
03/13/2010 03:40 Arcо#2
Quote:
Originally Posted by -NewDawn- View Post
Hey Everyone!
I decided that I'm going to just keep my 5165 source, thus I'm picking up where I left off. =]

This is my goal in the Broadcast System:
I want to be able to broadcast a message without CPs.

I started by doing this:
Code:
case 2050:
                            {
                                if (Data[4] == 3 && GC.MyChar.Silvers >= 100000)
                                {
                                    if (Game.World.BroadCastCount <= 100)
                                    {
                                        GC.MyChar.Silvers -= 100000;

                                        string Message = "";
                                        for (byte i = 0; i < Data[13]; i++)
                                            Message += Convert.ToChar(Data[14 + i]);


                                        Game.BroadCastMessage B = new NewestCOServer.Game.BroadCastMessage();
                                        B.Name = GC.MyChar.Name + GC.AuthInfo.Status;
                                        B.Message = Message;
                                        B.Place = Game.World.BroadCastCount;
                                        Game.World.BroadCasts[Game.World.BroadCastCount] = B;
                                        Game.World.BroadCastCount++;

                                        Data[8] = B.Place;
                                        GC.AddSend(Data);
                                    }
                                }
                                break;
                            }
After that, I tested it with 100 CPs in my pocket.
It worked....

Then my testers tried it and couldn't use it.
It requires 5 Cps to get to the Broadcast window (Packet 2050).

Help? =\
Are you sure you used the right exe after you debugged?
03/13/2010 04:17 -NewDawn-#3
Quote:
Originally Posted by .Arco View Post
Are you sure you used the right exe after you debugged?
yes. rofl. I'm not that nooby =P
and why did someone thank you for that? rofl!
03/13/2010 04:24 CptSky#4
You need to edit the client-side part...
03/13/2010 04:28 Arcо#5
Quote:
Originally Posted by CptSky View Post
You need to edit the client-side part...
I'm pretty sure he didn't do any clientside edits or he would have tried that already. He was able to do it no problems.
03/13/2010 04:38 -NewDawn-#6
Quote:
Originally Posted by .Arco View Post
I'm pretty sure he didn't do any clientside edits or he would have tried that already. He was able to do it no problems.
Well yah, I did try client side edits. I changed a few lines in the StrRes Configuration File so that the client said "Cost: 100k" instead of "Cost: 5 CPs".

How does that have to do with the problem though? It can't be client based. The server is what communicates with the character.
03/13/2010 04:39 Arcо#7
Quote:
Originally Posted by -NewDawn- View Post
Well yah, I did try client side edits. I changed a few lines in the StrRes Configuration File so that the client said "Cost: 100k" instead of "Cost: 5 CPs".

How does that have to do with the problem though? It can't be client based. The server is what communicates with the character.
There are alot of things that are server side that involve client side shiz.
Give one of your players your strres and see if that works.
03/13/2010 04:50 -NewDawn-#8
Quote:
Originally Posted by .Arco View Post
There are alot of things that are server side that involve client side shiz.
Give one of your players your strres and see if that works.
strres?
03/13/2010 04:50 Arcо#9
Quote:
Originally Posted by -NewDawn- View Post
strres?
.ini
03/13/2010 05:14 -NewDawn-#10
Quote:
Originally Posted by .Arco View Post
.ini
Oh, no. I tried it on mine and it doesn't work when I have 0 CPs. It can't be client sided anyways. The client can't check your CPs...

And all I changed in that is so it SAYS that it costs 100k.
[Only registered and activated users can see links. Click Here To Register...]

The problem is, people with 0 CPs can't even get to that window.
(at a friend's house for a few hours... afk)
03/13/2010 05:21 Arcо#11
Quote:
Originally Posted by -NewDawn- View Post
Oh, no. I tried it on mine and it doesn't work when I have 0 CPs. It can't be client sided anyways. The client can't check your CPs...

And all I changed in that is so it SAYS that it costs 100k.
[Only registered and activated users can see links. Click Here To Register...]

The problem is, people with 0 CPs can't even get to that window.
(at a friend's house for a few hours... afk)
It sure as heck can be clientsided. Idk why you're saying it can't lol.
03/13/2010 05:48 CptSky#12
Quote:
Originally Posted by -NewDawn- View Post
Well yah, I did try client side edits. I changed a few lines in the StrRes Configuration File so that the client said "Cost: 100k" instead of "Cost: 5 CPs".

How does that have to do with the problem though? It can't be client based. The server is what communicates with the character.
StrRes -> String Ressource... You think that the check of the CPs is in a string? If you really want to use money, just remove the client-side check. For the moment, before sending the packet, the client check if your character have enough CPs. You can change it for money, but its more easy to remove the check and anyway, the server already check the value...

Nothing to add... If you can't understand that, its that you are not ready.
03/14/2010 05:46 walmartboi#13
Quote:
Originally Posted by -NewDawn- View Post
Well yah, I did try client side edits. I changed a few lines in the StrRes Configuration File so that the client said "Cost: 100k" instead of "Cost: 5 CPs".

How does that have to do with the problem though? It can't be client based. The server is what communicates with the character.
Hint hint: StrRes.ini (It's your best friend in the Private Server world) :)
03/15/2010 02:47 -NewDawn-#14
That won't work. I'll try it but it won't work. Those are only strings that replace a code.

...

Didn't work. It's just a string that goes into the client. I'm telling you guys that it's server side... i just can't figure out what triggers it.
03/15/2010 03:09 Arcо#15
Quote:
Originally Posted by -NewDawn- View Post
That won't work. I'll try it but it won't work. Those are only strings that replace a code.

...

Didn't work. It's just a string that goes into the client. I'm telling you guys that it's server side... i just can't figure out what triggers it.
Off topic but how are you going to tell people that have been coding for +1year that its not something, when you only been coding for >1month.