Jump to content
  • 0

NPC Speaks To Character Only Once


prontera,133,217,5	script	Item Test	4_M_MANAGER,{

	for (.@i = 0; .@i < @inventorylist_count; .@i++) {
		.@id = @inventorylist_id[.@i];
		.@inventory_amount = @inventorylist_amount[.@i];
		.@is_equipped = @inventorylist_equip[.@i];
		.@is_refined = @inventorylist_refine[.@i];
		.@is_carded = @inventorylist_card1[.@i];

		mes getitemname(.@id) + ": ID=" + .@id + ", equipped=" + .@is_equipped + ", refined=" + .@is_refined + ", carded=" + .@is_carded;

		.@storage_count = getd("$global_storage" + .@id);

		if (!.@is_equipped) {
			setd("$global_storage" + .@id, .@storage_count + .@inventory_amount);

		mes .@storage_count + " -> " + getd("$global_storage" + .@id);



I wrote a small script to see the contents of the arrays that are populated by getinventorylist.


The first time I speak to the NPC on a character, I get the output that I expect.




However, every subsequent attempt to speak to the NPC, nothing happens. A dialogue box doesn't open, and no errors are logged in the console. If I restart the server, the NPC still won't talk to me. If I make a new character, then the NPC will talk to me exactly one time again.


Does anyone know why this might be? 


EDIT: You can remove this thread, in my loop header I had a typo:

for ([email protected] = 0; i < @inventorylist_count; i++)


Edited by ahoy

Share this post

Link to post
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.

Answer this question...

×   Pasted as rich text.   Restore formatting

  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.


  • Create New...

Important Information

By using this site, you agree to our Terms of Use.