Jump to content
Sign in to follow this  
Naiss

arma2netmysql Result

Recommended Posts

all i get in the debug message is ["0"] so how would i manage to check if thats the name? i tried to do if (blahblah == ['0']) then {}; but did not work :P

       private ["_return","_UserAccount"];

_return = _this select 0;
_return = call compile _return;
_return = (_return select 0) select 0;

DB_User_Exist = _return;
systemChat format ["Debug: %1",DB_User_Exist];

if (count (DB_User_Exist) == 0) then {
	RPP_DBChecked = true;
	RPP_NewPlayer = true;
	_msg = "Profile not found, Creating Profile please wait...";
	_color = RPP_Yellow;
	[_msg,_color] call RPP_MessageSystem;
	[] call RPP_MySQL_Client_CreateNewUser;
}
else
{
	RPP_DBChecked = true;
	RPP_NewPlayer = false;
	[] call RPP_MySQL_Client_LoadStats;
	_msg = "Profile Found, Loading stats...";
	_color = RPP_Green;
	[_msg,_color] call RPP_MessageSystem;
};

Share this post


Link to post
Share on other sites
if (blah in ['0']) then {};

Share this post


Link to post
Share on other sites

i think i explained it about wrong, this is what i can't get working

if (count (DB_User_Exist) == 0) then {

it wont really check it if it's 0 because it's ['0'] so it alweys says Profile found, loading stats

---------- Post added at 20:21 ---------- Previous post was at 19:52 ----------

got it working i just did this :P

if ("0" in DB_User_Exist) then {
	RPP_DBChecked = true;
	RPP_NewPlayer = true;
	_msg = "Profile not found, Creating Profile please wait...";
	_color = RPP_Yellow;
	[_msg,_color] call RPP_MessageSystem;
	[] call RPP_MySQL_Client_CreateNewUser;
}
else
{
	RPP_DBChecked = true;
	RPP_NewPlayer = false;
	[] call RPP_MySQL_Client_LoadStats;
	_msg = "Profile Found, Loading stats...";
	_color = RPP_Green;
	[_msg,_color] call RPP_MessageSystem;
};

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×