Hello guys, I need help with my script.
Basically I need NPC usage data to be stored in SQL. (It's already being done, but I want to improve the information.)
I am using this script that removes refinement as an example:
case 3:
if (getequipisequiped(EQI_HEAD_LOW)) goto baixo_remove;
next;
mes @np$;
mes "Você deve equipar o equipamento antes de tentar remover o refinamento.";
close;
baixo_remove:
if(getequiprefinerycnt(EQI_HEAD_LOW) <= 0) { next; mes @np$; mes "Eu não posso remover o refinamento deste item!"; close; }
if(countitem(7619) < 10){
next;
mes @np$;
mes "Desculpe, mas você não possui os ^FFA500^FFA500"+getitemname(7619)+"^000000^000000 necessários para remover o refinamento do seu equipamento"; close; }
next;
mes @np$;
mes "Ok, vamos começar!";
delitem 7619,10;
progressbar "ffff00",.progress_time;
atcommand "@refine 1-10";
query_sql "INSERT INTO `refinador_especial` (`account_id`, `char_id`, `Equipamento`, `ID`, `Refinamento`, `Data`) VALUES ('"+ getcharid(3) +"', '"+ getcharid(0) +"', 'Cabeça - Baixo','????' '-10', '"+gettimestr("%d/%m/%Y - %H:%M:%S", 25)+"')";
close;
What I need:
How do I get the equipment ID the player is using?
I want to add this information to SQL
Question
Gladius
Hello guys, I need help with my script.
Basically I need NPC usage data to be stored in SQL. (It's already being done, but I want to improve the information.)
I am using this script that removes refinement as an example:
case 3: if (getequipisequiped(EQI_HEAD_LOW)) goto baixo_remove; next; mes @np$; mes "Você deve equipar o equipamento antes de tentar remover o refinamento."; close; baixo_remove: if(getequiprefinerycnt(EQI_HEAD_LOW) <= 0) { next; mes @np$; mes "Eu não posso remover o refinamento deste item!"; close; } if(countitem(7619) < 10){ next; mes @np$; mes "Desculpe, mas você não possui os ^FFA500^FFA500"+getitemname(7619)+"^000000^000000 necessários para remover o refinamento do seu equipamento"; close; } next; mes @np$; mes "Ok, vamos começar!"; delitem 7619,10; progressbar "ffff00",.progress_time; atcommand "@refine 1-10"; query_sql "INSERT INTO `refinador_especial` (`account_id`, `char_id`, `Equipamento`, `ID`, `Refinamento`, `Data`) VALUES ('"+ getcharid(3) +"', '"+ getcharid(0) +"', 'Cabeça - Baixo','????' '-10', '"+gettimestr("%d/%m/%Y - %H:%M:%S", 25)+"')"; close;
What I need:
How do I get the equipment ID the player is using?
I want to add this information to SQL
Link to comment
Share on other sites
2 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.