Jump to content
  • 0

Random box (use getitem2)


Question

Posted (edited)

 

Like the title above, is it possible random box can use format getitem2

 

for ex:

gifbox can get knife+7 or MG+7

thx

Edited by melv0

3 answers to this question

Recommended Posts

  • 0
Posted
On 6/24/2017 at 3:22 PM, Kaze said:

Try this simple :D
You can easily configure the items at OnInit:

Item DB:


// SQL Version: REPLACE INTO `item_db2` VALUES (46996,'RANDOM_BOX','Random Box',18,NULL,NULL,200,NULL,NULL,NULL,NULL,0xFFFFFFFF,7,2,NULL,NULL,NULL,NULL,NULL,'doevent \"F_Random_Box::OnBoxClick\";',NULL,NULL);
// TXT Version: 46996,RANDOM_BOX,Random Box,2,10000,,200,,,,,0xFFFFFFFF,7,2,,,,,,{ doevent \"F_Random_Box::OnBoxClick\"; },{},{}

Script:

http://immortalsro.com/rAScripts/random_box.txt

thanks u for ur help

but i found more simple script :D

 

function	script	L_CustomLRGmid	{
	set @randOBB,rand(6);
	if(@randOBB==0){
		getitem2 32121,1,1,0,0,7905,7905,0,0;
	}
	if(@randOBB==1){
		getitem2 19509,1,1,0,0,7905,7905,0,0;
	}
	if(@randOBB==2){
		getitem2 20318,1,1,0,0,7905,7905,0,0;;
	}
	if(@randOBB==3){
		getitem2 20131,1,1,0,0,7905,7905,0,0;;
	}
	if(@randOBB==4){
		getitem2 20399,1,1,0,0,7905,7905,0,0;;
	}
	if(@randOBB==5){
		getitem2 20314,1,1,0,0,7905,7905,0,0;;
	}
	end;
}

and on item db just call that function

 

  • 0
Posted
41 minutes ago, melv0 said:

bump

 

Try this simple :D
You can easily configure the items at OnInit:

Item DB:

// SQL Version: REPLACE INTO `item_db2` VALUES (46996,'RANDOM_BOX','Random Box',18,NULL,NULL,200,NULL,NULL,NULL,NULL,0xFFFFFFFF,7,2,NULL,NULL,NULL,NULL,NULL,'doevent \"F_Random_Box::OnBoxClick\";',NULL,NULL);
// TXT Version: 46996,RANDOM_BOX,Random Box,2,10000,,200,,,,,0xFFFFFFFF,7,2,,,,,,{ doevent \"F_Random_Box::OnBoxClick\"; },{},{}

Script:

http://immortalsro.com/rAScripts/random_box.txt

  • Upvote 1

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