PTP admin.
help me guys the script is not properly working i already change the sql table name from select to level to the group_id where stands group ID level. because this script came from rathena which is not compatible for hercules database. anyway
my problem when i set the premium account the group ID value wont change but the others table is excuted. just the group ID is not affected by the script.
View attachment vip.txt
{
mes "Account ID: "+.@accountId+".";
sleep2 rand(100,850);
query_sql("INSERT INTO vip_silver (`account_id`,`account_name`,`start_date`,`end_date`,`status`) VALUES ("+.@accountId+",'"+.@accountName$+"','"+gettimestr("%Y-%m-%d",21)+"','"+gettimestr("%Y-%m-%d",21)+"','ACTIVE');");
sleep2 100;
query_sql("UPDATE vip_silver SET end_date = DATE_ADD(start_date, INTERVAL "+.@silverDays+" DAY) WHERE account_id = "+.@accountId+";");
query_sql("UPDATE `login` SET `group_id` = "+$VIPs_SilverAccLevel+" WHERE `account_id` = "+.@accountId+";");
query_sql("UPDATE login SET `account_type` = 'SILVER' WHERE account_id = "+.@accountId+";");
mes "Account "+.@accountId+" added";
mes "successfuly!";
close;
}
}
close;
case 2: // Delete
set .@getSilverList_1$,query_sql("SELECT account_name FROM vip_silver LIMIT 0,127;", .@silverList_1$); // query_sql can only display the first 128 lines of a table. This is so sad
if ( getarraysize(.@silverList_1$) == 0 )
{
mes "There are currently no VIP";
mes "Silver accounts.";
close;
}
else
help me guys the script is not properly working i already change the sql table name from select to level to the group_id where stands group ID level. because this script came from rathena which is not compatible for hercules database. anyway
my problem when i set the premium account the group ID value wont change but the others table is excuted. just the group ID is not affected by the script.
View attachment vip.txt
else // If the account is not already a VIP Silver one, add a new entry.joven15 said:PTP admin.
help me guys the script is not properly working i already change the sql table name from select to level to the group_id where stands group ID level. because this script came from rathena which is not compatible for hercules database. anyway
my problem when i set the premium account the group ID value wont change but the others table is excuted. just the group ID is not affected by the script.
View attachment vip.txt
{
mes "Account ID: "+.@accountId+".";
sleep2 rand(100,850);
query_sql("INSERT INTO vip_silver (`account_id`,`account_name`,`start_date`,`end_date`,`status`) VALUES ("+.@accountId+",'"+.@accountName$+"','"+gettimestr("%Y-%m-%d",21)+"','"+gettimestr("%Y-%m-%d",21)+"','ACTIVE');");
sleep2 100;
query_sql("UPDATE vip_silver SET end_date = DATE_ADD(start_date, INTERVAL "+.@silverDays+" DAY) WHERE account_id = "+.@accountId+";");
query_sql("UPDATE `login` SET `group_id` = "+$VIPs_SilverAccLevel+" WHERE `account_id` = "+.@accountId+";");
query_sql("UPDATE login SET `account_type` = 'SILVER' WHERE account_id = "+.@accountId+";");
mes "Account "+.@accountId+" added";
mes "successfuly!";
close;
}
}
close;
case 2: // Delete
set .@getSilverList_1$,query_sql("SELECT account_name FROM vip_silver LIMIT 0,127;", .@silverList_1$); // query_sql can only display the first 128 lines of a table. This is so sad
if ( getarraysize(.@silverList_1$) == 0 )
{
mes "There are currently no VIP";
mes "Silver accounts.";
close;
}
else