Jump to content
  • 0

Help: Check VIP Status


Question

Posted (edited)

Hi Everyone,

By any chance do we already have a command wherein we can check a player's VIP status on Admin account? Because I cannot find the SQL for VIP status. I would appreciate your help in here ?

 

Thank you.

Edited by Ronald

6 answers to this question

Recommended Posts

  • 0
Posted (edited)

VP accounts are by default group_id 5 (if I am not mistaken) found in login table.

 

 

Not tested.

-	script	VIP_Checker	-1,{
OnCheck:
	if(!(.@nb = query_sql(SELECT `account_id` FROM `login` WHERE `group_id` = '5'", .@aid))) {
		dispbottom "No data found.";
		end;
	}
	dispbottom "VIP Account ID list :";
	for ( .@i = 0; .@i < .@nb; .@i++ )
		dispbottom (.@i+1) +". Account ID : "+ .@aid[.@i];
	dispbottom "Total of "+.@nb +" Active VIP account(s).";
	end;
OnInit:
	bindatcmd "checkvip", strnpcinfo(0)+"::OnCheck", 60, 60; // @checkvip to list active vip accounts
}

 

Edited by Mabuhay
  • 0
Posted
---------------------------------------

*vip_status(<type>,{"<character name>"})

Returns various information about a player's VIP status.

Valid types:
 VIP_STATUS_ACTIVE - VIP status: true if the player is a VIP or false if not
 VIP_STATUS_EXPIRE - VIP expire timestamp if the player is VIP or 0 if not
 VIP_STATUS_REMAINING - VIP time remaining in seconds

NOTE: This command is only available if the VIP System is enabled.

---------------------------------------

*vip_time <time>,{"<character name>"};

Changes a player's VIP time (in minutes). A positive value will increase time, and a
negative value will decrease time.

NOTE: This command is only available if the VIP System is enabled.

---------------------------------------

 

  • Upvote 1
  • 0
Posted
4 hours ago, Mabuhay said:

VP accounts are by default group_id 5 (if I am not mistaken) found in login table.

 

 

Not tested.


-	script	VIP_Checker	-1,{
OnCheck:
	if(!(.@nb = query_sql(SELECT `account_id` FROM `login` WHERE `group_id` = '5'", .@aid))) {
		dispbottom "No data found.";
		end;
	}
	dispbottom "VIP Account ID list :";
	for ( .@i = 0; .@i < .@nb; .@i++ )
		dispbottom (.@i+1) +". Account ID : "+ .@aid[.@i];
	dispbottom "Total of "+.@nb +" Active VIP account(s).";
	end;
OnInit:
	bindatcmd "checkvip", strnpcinfo(0)+"::OnCheck", 60, 60; // @checkvip to list active vip accounts
}

 

Not working. ?  But still,thankyouuu.

  • 0
Posted
On 6/25/2020 at 3:58 PM, Ronald said:

Not working. ?  But still,thankyouuu.

mabuhay just miss 1 "

try this
 

-	script	VIP_Checker	-1,{
OnCheck:
	if(!(.@nb = query_sql("SELECT `account_id` FROM `login` WHERE `group_id` = '5'", .@aid))) {
		dispbottom "No data found.";
		end;
	}
	dispbottom "VIP Account ID list :";
	for ( .@i = 0; .@i < .@nb; .@i++ )
		dispbottom (.@i+1) +". Account ID : "+ .@aid[.@i];
	dispbottom "Total of "+.@nb +" Active VIP account(s).";
	end;
OnInit:
	bindatcmd "checkvip", strnpcinfo(0)+"::OnCheck", 60, 60; // @checkvip to list active vip accounts
}

 

  • Upvote 1
  • 0
Posted
On 6/27/2020 at 7:48 PM, LearningRO said:

mabuhay just miss 1 "

try this
 


-	script	VIP_Checker	-1,{
OnCheck:
	if(!(.@nb = query_sql("SELECT `account_id` FROM `login` WHERE `group_id` = '5'", .@aid))) {
		dispbottom "No data found.";
		end;
	}
	dispbottom "VIP Account ID list :";
	for ( .@i = 0; .@i < .@nb; .@i++ )
		dispbottom (.@i+1) +". Account ID : "+ .@aid[.@i];
	dispbottom "Total of "+.@nb +" Active VIP account(s).";
	end;
OnInit:
	bindatcmd "checkvip", strnpcinfo(0)+"::OnCheck", 60, 60; // @checkvip to list active vip accounts
}

 

Thank you for confirming. ?

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...