Hi, I am trying to fix a code that is of my interest. But with this part of the code I can not find out the problem.
First through the rest skill the hom_vaporize is done.
The idea is to save card[1] and card[2] ids same as in the pet.cpp when it comes to obtaining an egg.
Then in pc.cpp / pc_isUseitem
switch( nameid ) {
case 50844:
if(hd){
if(hom->evomoment == 1){
clif_displaymessage(sd->fd, "Usted no puede retornar.");
return 0;
}
break;
}
case 8031:
if(sd){
if(hd)
if(hom->evomoment == 1){
clif_displaymessage(sd->fd, "No puedes invocar otro pokemon mientras tu pokemon activo esta evolucionando.");
return 0;
}
if (sd->sc.data[SC_NOCHAT])
return 0;
if(sd->hd != NULL)
return 0;
if(sd->inventory.u.items_inventory[n].card[3] > 2){
hom_create_request(sd, (sd->inventory.u.items_inventory[n].card[3]));
clif_specialeffect(&sd->bl,41,AREA);
return 1;
}
if(sd->inventory.u.items_inventory[n].card[3] == 1){
clif_displaymessage(sd->fd, msg_txt(sd,718));
return 0;
}
if(sd->inventory.u.items_inventory[n].card[3] == 0){
sd->status.hom_id = MakeDWord(sd->inventory.u.items_inventory[n].card[1], sd->inventory.u.items_inventory[n].card[2]);
intif_homunculus_requestload(sd->status.account_id, sd->status.hom_id);
clif_specialeffect(&sd->bl,1049,AREA);
return 1;
}
break;
}
By having tmp_item.card [3] = 0;
will perform this action, which should return the homunculus
if(sd->inventory.u.items_inventory[n].card[3] == 0){
When not using the item does not recover the homunculus, someone has some idea of the problem. Thanks for any help!!!
Question
Tauro
Hi, I am trying to fix a code that is of my interest. But with this part of the code I can not find out the problem.
First through the rest skill the hom_vaporize is done.
The idea is to save card[1] and card[2] ids same as in the pet.cpp when it comes to obtaining an egg.
Then in pc.cpp / pc_isUseitem
switch( nameid ) { case 50844: if(hd){ if(hom->evomoment == 1){ clif_displaymessage(sd->fd, "Usted no puede retornar."); return 0; } break; } case 8031: if(sd){ if(hd) if(hom->evomoment == 1){ clif_displaymessage(sd->fd, "No puedes invocar otro pokemon mientras tu pokemon activo esta evolucionando."); return 0; } if (sd->sc.data[SC_NOCHAT]) return 0; if(sd->hd != NULL) return 0; if(sd->inventory.u.items_inventory[n].card[3] > 2){ hom_create_request(sd, (sd->inventory.u.items_inventory[n].card[3])); clif_specialeffect(&sd->bl,41,AREA); return 1; } if(sd->inventory.u.items_inventory[n].card[3] == 1){ clif_displaymessage(sd->fd, msg_txt(sd,718)); return 0; } if(sd->inventory.u.items_inventory[n].card[3] == 0){ sd->status.hom_id = MakeDWord(sd->inventory.u.items_inventory[n].card[1], sd->inventory.u.items_inventory[n].card[2]); intif_homunculus_requestload(sd->status.account_id, sd->status.hom_id); clif_specialeffect(&sd->bl,1049,AREA); return 1; } break; }
By having tmp_item.card [3] = 0;
will perform this action, which should return the homunculus
if(sd->inventory.u.items_inventory[n].card[3] == 0){
When not using the item does not recover the homunculus, someone has some idea of the problem. Thanks for any help!!!
Link to comment
Share on other sites
0 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.