Jump to content
  • 0

How to make a Custom OBB, or OCA


budabeads

Question


  • Group:  Members
  • Topic Count:  16
  • Topics Per Day:  0.00
  • Content Count:  42
  • Reputation:   1
  • Joined:  02/16/12
  • Last Seen:  

hello master scripters! im back! hahahaha

can you teach us how to make a custom Old Blue Box, or Old Card Album...

thanks master scripters!!!!

this is for all of us!!!

Link to comment
Share on other sites

13 answers to this question

Recommended Posts


  • Group:  Members
  • Topic Count:  69
  • Topics Per Day:  0.02
  • Content Count:  592
  • Reputation:   31
  • Joined:  11/14/11
  • Last Seen:  

- this is already been answered

here's the step

open ra/db/item_db2.txt

make a new item -

25500,Custom_Box,Custom Box,2,10000,,200,,,,,0xFFFFFFFF,7,2,,,,,,{ getitem groupranditem(IG_whatever),1; },{},{}

next step is

open ra/db/const.txt

Find IG_Advanced_Weapons_Box 61

below add this

IG_whatever 63 //IG_whatever must be same in the item_db2.txt script command

next step

open ra/db/item_group_db.txt

import: db/item_whatever.txt - put this

next step

make a new script named

item_whatever.txt - place this in ra/db/

next step

open item_whatever.txt - in ra/db/item_whatever.txt

//Explanation 63 - is the number you input in const.txt

// - 1111 - this is the itemID

// - 9 - this is the rate

63,1111,9

63,<Item ID>,<Rate>

next step

open ra/src/map/itemdb.h

find this part

#define MAX_ITEMGROUP #62

the number is 62 where in const.txt the max group number is 62 - but you add another item group..

- just add + 1 in 62 so make it

#define MAX_ITEMGROUP #63

Viola you are done~

  • Upvote 2
Link to comment
Share on other sites

  • 0

  • Group:  Members
  • Topic Count:  11
  • Topics Per Day:  0.00
  • Content Count:  39
  • Reputation:   0
  • Joined:  05/05/17
  • Last Seen:  

On 1/9/2015 at 11:41 AM, Saisho said:
Sry old topic i know but things changed o.o
 
Is this what am i supposed to look for? or its already obsolete?

#define MAX_ITEMGROUP_RANDGROUP 4 ///Max group for random item (increase this when needed). TODO: Remove this limit and use dynamic size if needed

Edit: Just to make it clear, i remember i had to do something like that before, but now the wiki dont mention this part anymore so idk...

 

 

#define MAX_ITEMGROUP 400 ///The max. item group count (increase this when needed). TODO: Remove this limit and use dynamic size or DBMap if needed

They removed this line, because size is loaded dynamically. You can proceed in two ways
Just follow this tutorial but replace the MAX_ITEMGROUP with this method:

1 . Short way

  • Use db/<re><pre-re>/item_misc.txt
  • Add your IG group there
  • Done


2 . Long Way

  • Open src/map/itemdb.c
  • look for this lines

        sv_readdb(dbsubpath1, "item_avail.txt",         ',', 2, 2, -1, &itemdb_read_itemavail, i);

        sv_readdb(dbsubpath1, "item_stack.txt",         ',', 3, 3, -1, &itemdb_read_stack, i);

        sv_readdb(dbsubpath1, "item_nouse.txt",         ',', 3, 3, -1, &itemdb_read_nouse, i);

        sv_readdb(dbsubpath2, "item_group_db.txt",        ',', 2, 10, -1, &itemdb_read_group, i);

        sv_readdb(dbsubpath2, "item_bluebox.txt",        ',', 2, 10, -1, &itemdb_read_group, i);

        sv_readdb(dbsubpath2, "item_violetbox.txt",        ',', 2, 10, -1, &itemdb_read_group, i);

        sv_readdb(dbsubpath2, "item_cardalbum.txt",        ',', 2, 10, -1, &itemdb_read_group, i);

        sv_readdb(dbsubpath1, "item_findingore.txt",    ',', 2, 10, -1, &itemdb_read_group, i);

        sv_readdb(dbsubpath2, "item_giftbox.txt",        ',', 2, 10, -1, &itemdb_read_group, i);

        sv_readdb(dbsubpath2, "item_misc.txt",            ',', 2, 10, -1, &itemdb_read_group, i);

  • and add your own db, recompile and thats it (not tested)

 

 

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  43
  • Topics Per Day:  0.01
  • Content Count:  815
  • Reputation:   86
  • Joined:  10/26/12
  • Last Seen:  

- this is already been answered

here's the step

open ra/db/item_db2.txt

make a new item -

25500,Custom_Box,Custom Box,2,10000,,200,,,,,0xFFFFFFFF,7,2,,,,,,{ getitem groupranditem(IG_whatever),1; },{},{}

next step is

open ra/db/const.txt

Find IG_Advanced_Weapons_Box 61

below add this

IG_whatever 63 //IG_whatever must be same in the item_db2.txt script command

next step

open ra/db/item_group_db.txt

import: db/item_whatever.txt - put this

next step

make a new script named

item_whatever.txt - place this in ra/db/

next step

open item_whatever.txt - in ra/db/item_whatever.txt

//Explanation 63 - is the number you input in const.txt

// - 1111 - this is the itemID

// - 9 - this is the rate

63,1111,9

63,<Item ID>,<Rate>

next step

open ra/src/map/itemdb.h

find this part

#define MAX_ITEMGROUP #62

the number is 62 where in const.txt the max group number is 62 - but you add another item group..

- just add + 1 in 62 so make it

#define MAX_ITEMGROUP #63

Viola you are done~

i follow ur guide and the mapserver says error invalid group id 63

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  94
  • Topics Per Day:  0.02
  • Content Count:  2192
  • Reputation:   252
  • Joined:  11/11/11
  • Last Seen:  

how to add annoucher items obtained from the box?

You just keep adding items into the file... if it's a custom box, you add items to your custom box .txt file. If you just wanna add more items to the normal OBB, go to (Pre)Renewal/item_bluebox.txt and add your items there.

// Structure of Database:

// GroupID,ItemID,Rate

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  6
  • Topics Per Day:  0.00
  • Content Count:  18
  • Reputation:   0
  • Joined:  01/10/13
  • Last Seen:  

how to add announcer in custom box? for example a player got a thana card in a custom box. then it will broadcast that he just got a thana card.

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  75
  • Topics Per Day:  0.02
  • Content Count:  170
  • Reputation:   1
  • Joined:  03/26/13
  • Last Seen:  

- this is already been answered

here's the step

open ra/db/item_db2.txt

make a new item -

25500,Custom_Box,Custom Box,2,10000,,200,,,,,0xFFFFFFFF,7,2,,,,,,{ getitem groupranditem(IG_whatever),1; },{},{}

next step is

open ra/db/const.txt

Find IG_Advanced_Weapons_Box 61

below add this

IG_whatever 63 //IG_whatever must be same in the item_db2.txt script command

next step

open ra/db/item_group_db.txt

import: db/item_whatever.txt - put this

next step

make a new script named

item_whatever.txt - place this in ra/db/

next step

open item_whatever.txt - in ra/db/item_whatever.txt

//Explanation 63 - is the number you input in const.txt

// - 1111 - this is the itemID

// - 9 - this is the rate

63,1111,9

63,<Item ID>,<Rate>

next step

open ra/src/map/itemdb.h

find this part

#define MAX_ITEMGROUP #62

the number is 62 where in const.txt the max group number is 62 - but you add another item group..

- just add + 1 in 62 so make it

#define MAX_ITEMGROUP #63

Viola you are done~

i follow the guide but its have error invalid group id 63

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  7
  • Topics Per Day:  0.00
  • Content Count:  16
  • Reputation:   0
  • Joined:  01/02/14
  • Last Seen:  

mine looks like this... how will I do it? O.O

 

#define MAX_ITEMGROUP 390

Link to comment
Share on other sites


  • Group:  Members
  • Topic Count:  52
  • Topics Per Day:  0.01
  • Content Count:  185
  • Reputation:   20
  • Joined:  01/06/13
  • Last Seen:  

Sry old topic i know but things changed o.o
 
Is this what am i supposed to look for? or its already obsolete?
#define MAX_ITEMGROUP_RANDGROUP 4 ///Max group for random item (increase this when needed). TODO: Remove this limit and use dynamic size if needed

Edit: Just to make it clear, i remember i had to do something like that before, but now the wiki dont mention this part anymore so idk...

Edited by Saisho
Link to comment
Share on other sites

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.

×
×
  • Create New...