Jump to content
Sign in to follow this  
Ragno

Add usage of constants on item_db.conf structure

Recommended Posts

There are some numeric values that are constant to all items and doesn't change, it could be changed to constants and improve the understanding of item_db.

 

Those values are: Type, Upper, Gender, Loc, View (can be seen constant name on lub files), Stack and Sprite.

 

Example:

 

{
	Id: 1626
	AegisName: "Piercing_Staff"
	Name: "Piercing Staff"
	Type: TYPE_WEAPON
	Buy: 20
	Weight: 500
	Atk: 80
	Matk: 145
	Range: 1
	Job: {
		Magician: true
		Acolyte: true
		Priest: true
		Wizard: true
		Monk: true
		Sage: true
	}
	Upper: {
		Upper: true
		Third Job: true
		Upper Third Job: true
		Baby Third Job: true
	}
	Loc: LOC_WEAPON
	WeaponLv: 3
	EquipLv: 70
	View: WEAPONTYPE_ROD
	Script: <"
		bonus bInt,4;
		bonus bIgnoreMdefRate,10+getrefine();
	">
},

 

In this example is changed values from Type, Upper, Loc and View to constants.

Edited by Ragno

Share this post


Link to post
Share on other sites

In most fields already possible to use constants.

But only need use name in quotes:

 

 

...
Type: "IT_WEAPON"
...

Share this post


Link to post
Share on other sites

 

In most fields already possible to use constants.

But only need use name in quotes:

 

 

...
Type: "IT_WEAPON"
...

 

You are totally right, and also there are the constants for item types, but not for Loc and View fields.

 

I also try to put the upper field separated as job, but it wasn't successful.

Share this post


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

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

Loading...
Sign in to follow this  

×
×
  • Create New...

Important Information

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