Hi everyone can any help me on how to figure this out?
All party member will start having 20 tickets. If they accept a certain task all party members ticket will reduced by one and the gettimetick will attach to each party member.
please help me fix this. Thanks
.@party_id = getcharid(1);
getpartymember .@party_id, 1;
getpartymember .@party_id, 2;
for ( .@i = 0; .@i < $@partymembercount; .@i++ ) {
set .@nb,query_sql("SELECT ticket,time FROM rdc WHERE account_id = "+$@partymemberaid[.@i]+"", .ticket,.time );
if ( .ticket[.@i] == 20 ){
set .time[.@i],gettimetick(2) + 604800;
set .ticket[.@i],.ticket[.@i] - 1;
query_sql("UPDATE `rdc` SET `time` = '"+.time[.@i]+"', `ticket` = '"+.ticket[.@i]+"' WHERE account_id = "+$@partymemberaid[.@i]+"");
} else {
set .ticket[.@i],.ticket[.@i] - 1;
query_sql("UPDATE `rdc` SET `ticket` = '"+.ticket[.@i]+"' WHERE account_id = "+$@partymemberaid[.@i]+"");
}
callfunc "InstDrake";
}
Hi everyone can any help me on how to figure this out?
All party member will start having 20 tickets. If they accept a certain task all party members ticket will reduced by one and the gettimetick will attach to each party member.
please help me fix this. Thanks
Share this post
Link to post
Share on other sites