Forum C# Developer Server Crashes when I..

Developer Server Crashes when I..

Postby codgamer101 » September 15th, 2015, 10:50 pm

Hello i made a giftcode system and when i enter the wrong code the Developer System crashes Bringing me to c# saying the code don't exist
I'm trying to alert the player saying wrong code but it crashes before reaching to alert function

Here is why i get the crash
Code: Select all
if (obj.Key != message.GetString(0))


How can i prevent the crash and just alert the player?

Thanks, Kota
codgamer101
 
Posts: 25
Joined: January 28th, 2015, 6:45 am

Re: Developer Server Crashes when I..

Postby Guillaume » September 16th, 2015, 12:31 am

Are you sure you have a message received as string ?
Did you test message.Length or message.Count, something like that and verified that there is at least one object ?

Can you put a breakpoint and "inspect" your message object un Debug ?
Guillaume
 
Posts: 277
Joined: March 28th, 2014, 1:59 am
Location: France

Re: Developer Server Crashes when I..

Postby codgamer101 » September 16th, 2015, 12:45 am

codgamer101
 
Posts: 25
Joined: January 28th, 2015, 6:45 am

Re: Developer Server Crashes when I..

Postby Guillaume » September 16th, 2015, 1:01 am

Put a breakpoint before the exception on your server.

I'm sure that you don't have verified if there is something at index 0 in your message, OR if that your BigDB object "obj" is null or not null.
Guillaume
 
Posts: 277
Joined: March 28th, 2014, 1:59 am
Location: France

Re: Developer Server Crashes when I..

Postby codgamer101 » September 16th, 2015, 1:09 am

I have sent u a private message
codgamer101
 
Posts: 25
Joined: January 28th, 2015, 6:45 am

Re: Developer Server Crashes when I..

Postby Guillaume » September 16th, 2015, 1:13 am

Guillaume
 
Posts: 277
Joined: March 28th, 2014, 1:59 am
Location: France

Re: Developer Server Crashes when I..

Postby oonka » October 29th, 2015, 6:49 pm

I'm having same issue with this, anyone figure out why?
oonka
 
Posts: 22
Joined: October 10th, 2015, 9:19 pm

Re: Developer Server Crashes when I..

Postby Guillaume » October 29th, 2015, 8:11 pm

Have you taken a look on the "ErrorLog" service on your dashboard for additional informations ?
Guillaume
 
Posts: 277
Joined: March 28th, 2014, 1:59 am
Location: France

Re: Developer Server Crashes when I..

Postby oonka » October 30th, 2015, 5:11 am

I have fixed the error, @codgamer use the original player.io load code and it will work
oonka
 
Posts: 22
Joined: October 10th, 2015, 9:19 pm


Return to C#



cron