WhatFT Posted March 20, 2012 Group: Members Topic Count: 142 Topics Per Day: 0.03 Content Count: 511 Reputation: 7 Joined: 02/15/12 Last Seen: April 11, 2014 Share Posted March 20, 2012 I don't know how to get a DB Script on this kind of Prize Box.. What is the DB SCRIPT for this one? Thinking that the Item/Prize Box contains -Chance to get Random Items -The same as the Old Blue/Purple Boxes. -Will not replace or Will replace OBB & OPB. Quote Link to comment Share on other sites More sharing options...
Flaid Posted March 20, 2012 Group: Members Topic Count: 20 Topics Per Day: 0.00 Content Count: 398 Reputation: 140 Joined: 01/04/12 Last Seen: February 19, 2022 Share Posted March 20, 2012 There's quite a few ways to do it, if you really want to obtain a random item, use this script. It's a simple function. function script PrizeBox { setarray .PrizeBoxItems[0],5013,6414,5142,4124,5123; set .Random, getarraysize( .BoxItems ); getitem .PrizeBoxItems[ rand( .Random ) ]; end; } On this line you set the items you want the box to randomly give out: setarray .PrizeBoxItems[0],5013,6414,5142,4124,5123; Now you simply add this as your item script. 20000,Prize_Box,Prize Box,0,150,,80,,,,,0xFFFFFFFF,31,2,,,,,,{ callfunc "PrizeBox"; },{},{} Quote Link to comment Share on other sites More sharing options...
Emistry Posted March 20, 2012 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10018 Reputation: 2369 Joined: 10/28/11 Last Seen: 19 hours ago Share Posted March 20, 2012 (edited) try this http://upaste.me/index.php?show=17976 aw...Flaid is a minute faster than me..>.< Edited March 20, 2012 by Emistry Quote Link to comment Share on other sites More sharing options...
WhatFT Posted March 20, 2012 Group: Members Topic Count: 142 Topics Per Day: 0.03 Content Count: 511 Reputation: 7 Joined: 02/15/12 Last Seen: April 11, 2014 Author Share Posted March 20, 2012 (edited) XD Which one will I better to use? @Emistry What will I put in the [ .Random ] ? Edited March 20, 2012 by Paulinds Quote Link to comment Share on other sites More sharing options...
simplemhan Posted March 20, 2012 Group: Members Topic Count: 50 Topics Per Day: 0.01 Content Count: 308 Reputation: 3 Joined: 12/18/11 Last Seen: March 4, 2014 Share Posted March 20, 2012 (edited) you can also try this item_db2 script 25500,Custom_Box,Custom Box,2,10000,,200,,,,,0xFFFFFFFF,7,2,,,,,,{ getitem groupranditem(IG_whatever),1; },{},{} const.txt: IG_whatever<TAB>55 Find IG_Advanced_Weapons_Box 61, check the last number and name for the last IG_ and add the following below that IG_whatever 62 (Depending on the last ID in there of course AND make sure to tab after IG_whatever, NOT space) item_group_db.txt: import: db/item_whatever.txt item_whatever.txt: 62,<Item ID>,<Rate> 62,<Item ID>,<Rate> 62,<Item ID>,<Rate> 62,<Item ID>,<Rate> // As many as you want item_whatever.txt // Structure of Database: // GroupID,ItemID,Rate 62,ID,1 //The Group ID you must set in your db/const.txt 62,5013,1 //Lord Kaho's Horn itemdb.h #define MAX_ITEMGROUP #62 - change this to your IG_whatever# and add plus 1 means #define MAX_ITEMGROUP #63 for my example. Edited March 20, 2012 by simplemhan Quote Link to comment Share on other sites More sharing options...
Flaid Posted March 20, 2012 Group: Members Topic Count: 20 Topics Per Day: 0.00 Content Count: 398 Reputation: 140 Joined: 01/04/12 Last Seen: February 19, 2022 Share Posted March 20, 2012 XD Which one will I better to use? It doesn't matter, they are the same, almost scripted the same even. Quote Link to comment Share on other sites More sharing options...
Emistry Posted March 20, 2012 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10018 Reputation: 2369 Joined: 10/28/11 Last Seen: 19 hours ago Share Posted March 20, 2012 XD Which one will I better to use? It doesn't matter, they are the same, almost scripted the same even. well...both are origin of my script...O.O anyway... the 1 post by Flaid just can get 1 item.. the below 1 i post... you can set how many items can be get in 1 box.. and every single items that you can get in the box have it's own quantity... anyway...choose at your own... Quote Link to comment Share on other sites More sharing options...
Flaid Posted March 20, 2012 Group: Members Topic Count: 20 Topics Per Day: 0.00 Content Count: 398 Reputation: 140 Joined: 01/04/12 Last Seen: February 19, 2022 Share Posted March 20, 2012 Your script? How can it be your script if I was the first to post here D: Quote Link to comment Share on other sites More sharing options...
simplemhan Posted March 20, 2012 Group: Members Topic Count: 50 Topics Per Day: 0.01 Content Count: 308 Reputation: 3 Joined: 12/18/11 Last Seen: March 4, 2014 Share Posted March 20, 2012 mine is the same script in old blue box, ect. Quote Link to comment Share on other sites More sharing options...
Emistry Posted March 20, 2012 Group: Forum Moderator Topic Count: 93 Topics Per Day: 0.02 Content Count: 10018 Reputation: 2369 Joined: 10/28/11 Last Seen: 19 hours ago Share Posted March 20, 2012 well..whatever...i dont wannt argu on this stuff...so just let it be...perhap my misunderstanding... @TS.. there is nothing you have to change in the script part.. all you have to do is just edit the setarray part for the item listing / amount Quote Link to comment Share on other sites More sharing options...
WhatFT Posted March 20, 2012 Group: Members Topic Count: 142 Topics Per Day: 0.03 Content Count: 511 Reputation: 7 Joined: 02/15/12 Last Seen: April 11, 2014 Author Share Posted March 20, 2012 THANKS FOR SHARING EVERYONE !! Appreciate it Quote Link to comment Share on other sites More sharing options...
Question
WhatFT
I don't know how to get a DB Script on this kind of Prize Box..
What is the DB SCRIPT for this one?
Thinking that the Item/Prize Box contains
-Chance to get Random Items
-The same as the Old Blue/Purple Boxes.
-Will not replace or Will replace OBB & OPB.
Link to comment
Share on other sites
10 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.