Jump to content
  • 0

Hi guyss can you me on this script?


Question

Posted (edited)

I would like to make this script

//item1

case 1: if (countitem(3301) == 0) { set .@id,3301; goto GetToken; } break;

//item2

case 2: if (countitem(3302) == 0) { set .@id,3302; goto GetToken; } break;

//item3

case 3: if (countitem(3303) == 0) { set .@id,3303; goto GetToken; } break;

//item4

case 4: if (countitem(3304) == 0) { set .@id,3304; goto GetToken; } break;

to delete item 2 (if i have one on my inventory), if i recieved item 1.

so basically what i need is, if i recieved this item1, it will automatically deletes the item2, and vice versa.. same as the 2nd one, if i get item4, it will automatically deletes item3 if i have one im my inventory...

(3301-3304 items are my custom id's btw..)

can anyone help me pls?? thank you... =)

Edited by critica

2 answers to this question

Recommended Posts

Posted

like this? :)

//item1
case 1: if (countitem(3301) == 0) {
if(countitem(3302))
delitem 3302,1;
if(countitem(3303))
delitem 3303,1;
if(countitem(3304))
delitem 3304,1;
set .@id,3301; goto GetToken;
} break;
//item2
case 2: if (countitem(3302) == 0) {
if(countitem(3301))
delitem 3301,1;
if(countitem(3303))
delitem 3303,1;
if(countitem(3304))
delitem 3304,1;
set .@id,3302; goto GetToken;
} break;
//item3
case 3: if (countitem(3303) == 0) {
if(countitem(3302))
delitem 3302,1;
if(countitem(3301))
delitem 3301,1;
if(countitem(3304))
delitem 3304,1;
set .@id,3303; goto GetToken;
} break;
//item4
case 4: if (countitem(3304) == 0) {
if(countitem(3302))
delitem 3302,1;
if(countitem(3303))
delitem 3303,1;
if(countitem(3301))
delitem 3301,1;
set .@id,3304; goto GetToken;
} break;

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