Jump to content
  • 0

Question

Posted


function script bg_checkmsg {
.@checkemulator = callfunc("bg_getconfiginfo","1");


if( !.@checkemulator )
query_sql "SELECT `value` FROM `char_reg_num` WHERE `char_id`='" + getarg(0) + "' AND `key`='bg_enable_msg'", .@value;
else
query_sql "SELECT `value` FROM `acc_reg_num` WHERE `account_id`='" + getarg(0) + "' AND `key`='bg_enable_msg'", .@value;


return (!getarraysize(.@value)?0:1);
}


 

I am using the function of acc_reg_num but she not this recording in SQL because the syntax is wrong someone can fix?

4 answers to this question

Recommended Posts

  • 0
Posted
function script bg_checkmsg {
.@checkemulator = callfunc("bg_getconfiginfo","1");


if( !.@checkemulator )
query_sql ("SELECT `value` FROM `char_reg_num` WHERE `char_id`='" + getarg(0) + "' AND `key`='bg_enable_msg'", .@value);
else
query_sql ("SELECT `value` FROM `acc_reg_num` WHERE `account_id`='" + getarg(0) + "' AND `key`='bg_enable_msg'", .@value);


return (!getarraysize(.@value)?0:1);
}

You'll need to add ( after query_sql and ) before semicolon.

 

Rynbef~

  • 0
Posted
function script bg_checkmsg {
.@checkemulator = callfunc("bg_getconfiginfo","1");


if( !.@checkemulator )
query_sql ("SELECT `value` FROM `char_reg_num` WHERE `char_id`='" + getarg(0) + "' AND `key`='bg_enable_msg'", .@value);
else
query_sql ("SELECT `value` FROM `acc_reg_num` WHERE `account_id`='" + getarg(0) + "' AND `key`='bg_enable_msg'", .@value);


return (!getarraysize(.@value)?0:1);
}

You'll need to add ( after query_sql and ) before semicolon.

 

Rynbef~

 

no semi colon or got still going to work :) there is nothing problem there.

  • 0
Posted

depend on  "When" did you save/update the values.

the server itself save/update these values every short interval based on your conf configuration. Default: 300 seconds.

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...