Function related issue.
#1

Problem I am having a minor issue with a simple function, I created this function to: 1) check the PlayerInfo to see if the player's PhoneNumber is >1 thus printing to the function N/A. Else if the player has a phone number the function prints that number. The function is not printing or showing if the player doesnot have a number.

Код:
stock PlayerPhoneExist(playerid)
{
	if(PlayerInfo[playerid][phonenumber]<1)
	{
		format(iStr,sizeof(iStr),"I/A");
		print(iStr);
	}
	else
	{
		format(iStr,sizeof(iStr),"%d", PlayerInfo[playerid][phonenumber]);
		print(iStr);
	}
	return 1;
}
how i plan on calling this function.

new istr;
format(istr, sizeof(istr), "%s %s" , RPNAME(playerid), GetPlayerPhoneExist(playerid)
SendClientmessage(playerid, COLOR_RED, istr);



please assist.
Reply


Messages In This Thread
Function related issue. - by SlayerHodge - 16.07.2018, 21:24
Re: Function related issue. - by IdonTmiss - 16.07.2018, 21:26
Re: Function related issue. - by SlayerHodge - 17.07.2018, 00:00
Re: Function related issue. - by Dayrion - 17.07.2018, 03:20
Re: Function related issue. - by SlayerHodge - 17.07.2018, 03:30
Re: Function related issue. - by GangstaSunny. - 17.07.2018, 04:03
Re: Function related issue. - by GhostHacker9 - 17.07.2018, 04:09
Re: Function related issue. - by Hreesang - 17.07.2018, 06:17
Re: Function related issue. - by SlayerHodge - 17.07.2018, 17:23

Forum Jump:


Users browsing this thread: 1 Guest(s)