[STARTING OFF]
{
It's fun to make your own items...
Just look in clothing.dfn - Run a windows search
General located in \dfndata\items\gear\clothing
Copy everything from clothing.dfn to a new document (Notepad Works) * Remember to Save the File a different name
Now you can begin editing you items; Let the fun begin.
}
[ADDING ATTRIBUTES]
{
This can be done by adding the following attributes to your items:
================================
STRADD=# // Add strength
DEXADD=# // Add dexterity
INTADD=# // Add intelligence
================================
}
[ADDING ATTRIBUTES ADVANCED]
{
Also see that your items Defense (DEF=#) Weight (weight=#) and Durability (hp=#) can be set.
==========================================
weight=# // Increase/Decrease weight
HP=# // Increase/Decrease item durability
DEF=# // Increase/Decrease physical resistance in percentage (%)
==========================================
Item ID=0x#### // This can look very scary. Its not really.
Before editing, I suggest checking out you base_item.dfn/base_armor.dfn
*This should help you to get a better understanding of the different attributes which can be added.
}
[ADDING SKILLS TO YOUR ITEMS - * BOM BOM BOM]
{
If you want your newly designed magic items to add points to your skills like these:
Tactics
Swordsmanship
Archery
Animal Taming
Magery
Meditation
Mining
Smithing
Tinkering
Ect...
Then you should check out your JavaScript folder.
This can be generally be found:
\UOX3\JS\
}
[ADDING SKILLS - HOW YOU DO IT]
{
Two ways to go about it:
You can either create a new script by copying an existing script to a new Notepad document and tweaking it a little. (Again Save you file as a different name)
e.g
===============================================
if (ourObj.id == 0x13fc || ourObj.id == 0x26c2 ||ourObj.id == 0x26c3 || ourObj.id ==0x27a5 || ourObj.id ==0x0f4f || ourObj.id ==0x13b1) {mChar.skills.tactics=(mChar.skills.tactics + 200);}
===============================================
*** If you were to change the "tactics" in: "(mChar.skills.tactics + 200)" to say archery you got some cool magic armor which adds to archery ***
** As far as I understand "(ourObj.id)" is the id of your item. This you can find in: your_magic_item's_filename.dfn file
* Please Clarify
- Or you can assign an existing script.
}
[ADDING SKILLS - IMPORTANT]
{
Either way you need assign a SCRIPT number to your new magic item
Check the SCRIPT numbers out in this file:
C:\UOX3\js\jse_fileassociations.txt // Default Install Patch - Mostly
}
[INFO - JSE_FILEASSOCIATIONS.TXT]
{
****Here SCRIPT numbers flow in sequence
***So if you made yourself a new SCRIPT I would suggest adding it in the 5000 range
**This is how you do it: 5033=custom/my_new_script.js (Use below as Example)
*Would not recommend adding your new scripts under the [ITEM_HEADER] titled [SERVER] and [COMMANDS], unless specified to do so by install instructions
E.g
================================
5020=custom/magici1.js
5021=custom/magici2.js
5022=custom/cursedi1.js
5023=custom/sa_weapons.js
5024=custom/ea_weapons.js
5025=custom/ex_weapons.js
5026=custom/spa_weapons.js
5027=custom/mw_arms.js
5028=custom/shld_arms.js
5029=custom/prt_arms.js
5030=custom/fort_arms.js
5031=custom/cursedi2.js
5032=custom/runebook.js
5033=custom/my_new_script.js
=================================
}
[ADDING YOU OWN CUSTOM MADE SCRIPT]
{
Assigning new SCRIPTS are easy easy...
Add the following to the bottom of your items attributes:
SCRIPT=5033 *Not the actual number you need to assign
E.g
*This is an example of an item with a SCRIPT added to it.
===============================
[lead_cloak] // Item Header
{ left facing // Direction which item will face
get=0x1515 // The "base item" - "0x1515" is a [item_header] * See [lead_cloak]
name=A Magic Cloak // The first name of the item - Before it is identified (Item Identification)
name2=A Lead Cloak // The iteme name - Both name 1 and name 2 can be edited
id=0x1515 // The actual item ID - Very important - If your having trouble with your items this is the first place to look
color=0x377 // The colour of the item - How the item will appear as loot and as spawned - Use Inside UO for easy access to colors
weight=80 // Carry weight of item
str=40 // Strength Required to carry item
hp=40 // Durability of item
DEXADD=-1 // Dexterity Penatly/Bonus (Note the + & - symbols before the amount)
DEF=5 // Physical Protection supplied by the item in Percent (%)
SCRIPT=5033 // The assigned SCRIPT - Remember to look in your jse_fileassociations.txt
}
==============================
}
------
Urgh
Benedict
PS: Please correct me if I have made any errors.
Making Wepons in your .DFN files: The Easy Way
awesome tutorial.
I used to script attribute bonuses and skill bonuses to my magical weapons.
The problem was, is that if you died, sometimes the effects became permenant. Have you noticed this with your scripts?
I abandoned my attempts and left it to the basic STRADD, DEXADD, and INTADD functions build into the DEF files.
Most of my bugs were regarding skill increases.
I used to script attribute bonuses and skill bonuses to my magical weapons.
The problem was, is that if you died, sometimes the effects became permenant. Have you noticed this with your scripts?
I abandoned my attempts and left it to the basic STRADD, DEXADD, and INTADD functions build into the DEF files.
Most of my bugs were regarding skill increases.