UOX3 Scripting Info

Scripts allow you to modify your shard. Most tokens and arguments are self-explanatory, however, some parts of the script are rather obscure, this file should help you read and understand how the scripts work.

SERVER.SCP Some things to note: 0 is false for conditions, 1 for true.

SECTION SERVER
{

CRASH_PROTECTION 0 // 0 = crash protection, 1 = save on crash, 2 = reload on crash (LEAVE AT 0!!!)
SKILLCAP 700 // total number of skill points that caps the player at
STATCAP 999 // total stat cap, works in conjuction with racial cap. If this is less than the sum of the
// racial cap, then hitting this stops you raising skills. If higher than sum of racial cap
// you hit the individual limits first
USESPECIALBANK 0 // 1 turns Region banks on. With region banks, you have a global gold bank available, but
// you also have a regional item bank. Thus, items in your Britain bank are only available in
// Britain, not in Minoc
SPECIALBANKTRIGGER WARE // Trigger word for opening your special bank. Default is "I wish to open my ware bank"
SAVE_PER_LOOP -1 // set to -1 or 0 disables it, any other number is the number of items/npcs to save in a loop
DECAYTIMER 666 // Time, in seconds, for an item to decay
PLAYERCORPSEDECAYMULTIPLIER 4 // multiply this by the decaytimer and that's the time for player corpses to decay
LOOTDECAYSWITHCORPSE 0 // if this is 0, then loot won't decay till after corpse does, otherwise decays at the same time
INVISTIMER 60 // number of seconds person remain visible for when Invisibility is cast on them
SKILLDELAY 5 // number of seconds between usage of a skill
SKILLLEVEL 5 // This value multiplied by an item's minskill value indicates the maximum skill diff to create
OBJECTDELAY 1 // number of seconds between using items
GATETIMER 30 // Number of seconds that a gate remains open
SHOWDEATHANIM 1 // If 1, it shows the death animation upon death
GUARDSACTIVE 1 // If 1, guards are active in guarded regions
ANNOUNCE_WORLDSAVES 1 // If 1, then all players are told when the world is saving
BG_SOUNDS 2 // Must be 1 - 10, Higher the number, less chance of background sounds
ARCHIVEPATH // Path to the directory where world will be archived
BACKUP_SAVE_RATIO 5 // Every # time the world is saved it is archived
UOXBOT 0 // No longer used anymore, leave as the default
POISONTIMER 90 // Number of seconds before Poison will wear off
JOINMSG 1 // If 1, then when a user joins, it tells everyone a join message
PARTMSG 1 // If 1, then when a user leaves, it tells everyone a leave message
LOG 1 // If 1, server logs some critical messages
ROGUE 1 // Turns on thieving if 1
WEATHERTIME 60 // Number of seconds between weather updates (not used, will be in future)
SHOPTIME 60 // How often (in seconds) shops spawn with the shops turned on
SHOWLOGGEDOUTPCS 1 // If 1, then Gms see logged off PCs
CHAR_TIME_OUT 100 // Number of seconds before PC times out (when logging off)
MAXSTEALTHSTEPS 10 // Maximum number of steps takeable with stealth engaged
RUNNINGSTAMINASTEPS 15 // Number of steps you can run before stamina starts to drop
BOAT_SPEED 0.750000 // How often (in seconds) boats move
HTML 0 // If 0, then turned off, otherwise # of secs between HTML generation
CUT_SCROLL_REQUIREMENTS 1 // If 1, then scrolls take less skill than casting a spell out of your spellbook
PERSECUTION 1 // If 1, then a ghost can attack a living being to drain mana
AUTO_ACCT 1 // If not 0, then reloads accounts every 3 world saves
AUTO_CREATE_ACCTS 0 // If 1, new account made when not found on login
MSGBOARDPATH // Path to msgboard files, defaults to same dir as UOX
MSGPOSTACCESS 0 // If 0, no one but GMs post, otherwise everyone can
MSGPOSTREMOVE 0 // If 0, no one but GMs can remove, otherwise everyone can
MSGRETENTION 0 // Length of time to retain messages (0 indefinite), not sure on measurements
ESCORTACTIVE 0 // If 1, then escort quests are active (on board)
ESCORTINITEXPIRE 0 // Length of time that the escort is summoned for
ESCORTACTIVEEXPIRE 0 // Length of time in seconds before the escort quest expires on board
ESCORTDONEEXPIRE 0 // Length of time in seconds for which escort is alive once taken
FOOTSTEPS 0 // 0 is turned off, all else is on
COMMANDPREFIX ' // Sets the command prefix (eg: using ' means you would type 'command)
}

SECTION SPEED
{

NICE 1 // accepts 0 to 3, 0 is most processor intensive, 2 is default (and nice)
LORDB_LAG_FIX 0 // irrelevant, no longer used
CHECK_ITEMS 0.750000 // How often items are checked for action (in seconds)
CHECK_NPCS 1.000000 // How often NPCs are checked for action (in seconds)
NPC_TILE_CHECK 24 // How far away (in tiles) that NPCs check for intelligence
CHECK_NPCAI 1.000000 // How ofteh the NPCs AI is checked (must be no more than CHECK_NPCS)
CHECK_SPAWNREGIONS 300 // Number of seconds between spawn regions being checked for more spawns
CHECKMEM 3000000 // Doesn't affect anything, leave at default
CACHE_MULS 0 // Setting to 1 loads the statics, tiles and a map cache into RAM, significant speed boost
ACCOUNTFLUSH # // If # is 0, disabled, otherwise, # is mins between flushing
}

SECTION COMBAT
{

MAXRANGE 10 // Maximum range that can be attacked at (not active)
WRESTLESPEED 8 // Speed of wrestling (lower is quicker)
MAX_RANGE_SPELL 10 // Maximum range a spell can be cast at (not active)
MAXDMG 120 // Maximum damage that can be inflicted (not active)
DEATH_ON_THROAT 1 // indicates whether a critical neck hit is fatal (not active)
DIST_TO_POISON 2 // Distance within you can poison (not active)
COMBAT_HIT_MESSAGE 1 // Prints out combat hit messages if 1
MAX_ABSORBTION 20 // maximum amount that can be absorbed via armour
MAX_NON_HUMAN_ABSORBTION 100 // maximum amount that can be absorbed by NPCs
MONSTERS_VS_ANIMALS 1 // If 1, animals and monsters would attack each other
ANIMALS_ATTACK_CHANCE 45 // % chance that a monster will attack an animal
ANIMALS_GUARDED 1 // If 1, then animals are guarded in guard regions
NPC_DAMAGE_RATE 2 // Damage/Rate is the amount of damage that an NPC will sustain
NPC_BASE_FLEEAT 20 // base hp which NPCs flee at
NPC_BASE_REATTACKAT 40 // base hp which NPCs will attack at
ATTACKSTAMINA 0 // AMount of stamina gained (or lost, if negative) on attacking. Must have
// equal to at least the absolute value of this to attack as well
}

SECTION VENDOR
{

SELLBYNAME 0 // if 1, then item is sold by name rather than ID (doesn't work correctly)
SELLMAXITEM 7 // maximum number of items you can sell
TRADESYSTEM 0 // advanced trade system, if 1, then goods prices do fluctuate (based on GOOD settings)
RANKSYSTEM 0 // if 1, then difficulty is graded and varying quality pieces are made
}

SECTION REGENERATE
{

HITPOINTS_REGENRATE 8 // Number of seconds before 1 hp regenerates
STAMINA_REGENRATE 3 // Number of seconds before 1 stam point regenerates
MANA_REGENRATE 5 // Number of seconds before 1 mana point regenerates
ARMOR_AFFECT_MANA_REGEN 1 // If 1, enables meditation. Higher damage, less the speed regen rate
}

SECTION HUNGER
{

HUNGERRATE 1000 // How often you get hungrier in seconds
HUNGER_DAMAGE 2 // How much health is lost when you are starving
HUNGER_DAMAGE_RATE 60 // How often you lose health when you are starving
}

SECTION RESOURCE
{

MINECHECK 2 // Dictates areas that can be mined. 0 is anywhere, 1 is mountains,floors 2 is
// those areas that are flagged as mining regions
ORE_PER_AREA 10 // Amount of ore in an area
ORE_RESPAWN_TIME 600 // How long it takes to respawn ore, in seconds
ORE_RESPAWN_AREA 0 // How many ore areas there are in the world
LOGS_PER_AREA 3 // How many logs are in the area
LOG_RESPAWN_TIME 600 // How long it takes for the logs to respawn
LOG_RESPAWN_AREA 10 // Number of log areas there are in the world
}

SECTION REPSYS
{

MURDER_DECAY 1000 // How quickly murder rate decays in number of seconds
MAXKILLS 5 // Maximum number of kills before you go red
CRIMINAL_TIME 600 // Time in seconds that you are grey when criminal
}

SECTION TRACKING
{

BASE_TRACKING_RANGE 10 // Minimum distance that a person can track
MAX_TRACKING_TARGETS 20 // Maximum number of targets that can be tracked
BASE_TRACKING_TIME 30 // Minimum time you can track for
TRACKING_MESSAGE_REDISPLAY_TIME 2 // How often the tracking info updates in seconds
}

SECTION BEGGING
{

BEGGING_RANGE 3 // How close you have to be to beg
BEGGING_TEXT0 Could thou spare a few coins?
BEGGING_TEXT1 Gold or live !
BEGGING_TEXT2 I have a family to feed, think of the children.
}

SECTION FISHING
{

BASE_FISHING_TIME 100 // Minimum amount of time needed for fishing
RANDOM_FISHING_TIME 50 // Random amount of time on top of the base time
}

SECTION SPIRITSPEAK
{

SPIRITSPEAKTIMER 300 // How long Spirit Speak lasts for (in seconds)
}

SECTION TIME_LIGHT
{
DAY 799
HOUR 1
MINUTE 42
AMPM 1
MOON1UPDATE 0
MOON2UPDATE 0
MOON1 7
MOON2 5

DUNGEONLIGHTLEVEL 7 // Light level for dungeon
WORLDFIXEDLEVEL 0 // This must be 255 for day/night cycling to work, fixed world light level
WORLDCURLEVEL 14 // current light level in the world
WORLDBRIGHTLEVEL 3 // brightest light setting for world
WORLDDARKLEVEL 25 // darkest setting the light can be
SECONDSPERUOMINUTE 5 // number of real seconds per UO minute
}

EOF

Back to Help Index



TRIGGER.SCP

SECTION TRG 1
{ Section open bracket
EMT Player emotes message
MSG Displays message for player
SND Plays hex sound reference
HEA Does math on players health
ACT Player displays action referred by ACTIONS.SCP
} Section close bracket

Back to Help Index



NPC.SCP
SECTION NPC 554
{
NAME a ratman mage
ID 002a // Not an item!
SKIN 03ea // Color of skin, Use /tweak to modify in game
DIRECTION N // Direction of initial facing
BACKPACK // Has a pack of loot when dead
PACKITEM 469 // Specific loot on corpse
MAGERY 500 700 // Range of magery skill is 50 to 70
SPATTACK 255 // Spell attack value
SPADELAY 10 // Delay in Real Life seconds per cast
LOOT 6 // Random item from lootlist 6
LOOT 10
LOOT 20
GOLD 0 96 // Range of gold found on corpse.
STR 96 // Strength--note this does not have a tenth placeholder as does skills
DEX 0 0
INT 36
KARMA -1500 // Karma level of creature, not the karma you get if you kill it
FAME 1500 // Fame level
PARRYING 500 // skill and the level, so Parrying of 50.0
MAGICRESISTANCE 350
TACTICS 500
FENCING 500
// Damage per Weapon
DAMAGE 3 15 // Range of damage
DEF 14 // AR Armor rating
NPCWANDER 4 // Type of wander mode. Refer to GM Commands
FX1 -1 // Refers to where the npc spawns
FY1 -1
FZ1 -1
FX2 20
NPCAI 2 // Refers to the mentality, the Artificial Intelligence.
TOTAME 1100 // Base chance to tame--you would need 110.0 Taming.
}
Back to Help Index



ENVOKE.SCP

For use by wtrigrs (world triggers) format is xhhhh. Correct any missing zeroes that should be included if only 3 numbers. The 'x' is the hex place holder.

Back to Help Index



WTRIGRS.SCP Same format as ENVOKE.SCP
SECTION x0c96
{ Pick dates
REQ x09a6 x09a5 // Note the 'x'precedes a four digit hex number. Anytime you see 3 digits,
// chances are it's wrong, and needs a zero after the 'x'.
MSG You pick some dates // This is the message displayed as the trigger is fired.
SND 00 4f // This is the sound played as the trigger is fired.
ACT 13 // This is the player action.
IDADD 17 27 1 // IDADD refers to the hex value of an item, The third number is the amount.
NEWTYPE 14 // This operator makes the item edible

Back to Help Index



ITEMS.SCP - ITEMMENU refers to the menu gump when using the /add command.
// Smithy Hammer
SECTION ITEM 98
{
ID 13E4 // The hex value of the item
LAYER 1 // Where the item goes on the paperdoll when equipped
LODAMAGE 3 // Low range of damage
HIDAMAGE 15 // High range of damage
HP 60 // Durability of the item
DECAY // Sets item to decaying if left out of a container
VALUE 25 // The resell/sell value in npc shops
RESTOCK 1 // The amount in shopkeepers restock layer
STR 30 // Strength required to use
SPD 50 // Speed of weapon
WEIGHT 800 // Weight, #/10, thus this would be 8 stones
}

Back to Help Index



NTRIGRS.SCP - Make sure any npc triggers are listed here, not in TRIGGERS.SCP.

CREATE.SCP - Makemenus for professions. Skill=required skill of user, resource is how much material is needed to make item additem from ITEMS.SCP.

SKILLS.SCP - This is the listing of the skills currently in use. Recall that skills use a tenth place holder, ie: Alchemy 700 is actually 70.0. Now, you see SKILLPOINT 0 70 50. What that means is this: From the range zero to 7.0 skill, you will get 5.0 skill points when this skill is used. I am not sure if this means successful use or both unsuccesful and success, but my money is on success. Also note the stats: This looks like minimum requirements. Zippy says different: 0 70 50 means at skill zero, you gain 70% of the time on success, 50% of the time on failure.

SPELLS.SCP - This one has good descriptions of the operators in the script.

SPEECH.SCP - DEFAULT is for anything the npc can't understand. ON is what PC's say. Great for setting up clues to quests.

ADVANCE.SCP - For advancement gates. Refer to Just Michael's FAQ for a good explanation.

GRAVE.SCP - Lootlist in NECRO.SCP. Use a shovel on a grave--but be careful of the undead!

HOUSE.SCP - SPACEY & SPACEX are the required area operators of clear land. You can comment them out to place buildings where you wish. CHARXYZ is where the player is put in relation to the placement of building.

MENUS.SCP - Here you can edit the Game Master or Counselor Call menus.

LOCATION.SCP - Use /goplace ## in ref to these numbers.

MISC.SCP - Edit books/update gump.

NECRO.SCP - Loot and creature lists for grave digging.

COLORS.SCP - Lists colors.

SPAWN.SCP - A region spawning setup. Use x1 y1 as northwest box corner x2 y2 as southeast box corner.

Back to Help Index



REGIONS.SCP - This snippet on how to make guarded regions provided by Lord Astynax.

Altering/Setting Guard Zones

This is an example on how to alter/set your own guard zones. It's pretty easy, but it can be somewhat time-consuming if you are setting a zone to a large area...All this information is edited in your "regions.scp"

SECTION REGION 3
{
NAME the town of Britain // The message you will get upon entering the guarded zone
MIDILIST 1 // Selects the midis that are played within your guarded area
GUARDED 1 // Used to define wether or not the zone is guarded "1" is guarded "0" is not
GUARDNUM 1000 // The guard npc's that will be found within your guarded zone
GUARDNUM 1000
GUARDNUM 1000
GUARDNUM 1000
GUARDNUM 1000
GUARDNUM 1001
GUARDNUM 1001
GUARDNUM 1001
GUARDNUM 1001
GUARDNUM 1001
GUARDOWNER Lord British's // The name displayed upon entry of a guard zone
MAGICDAMAGE 0 // The command that determines whether magic does damage within the city limits, "1" is yes, "0" is no
MARK 1 // Determines whether marking is allowed within the zone, "1" is yes, "0" is no
GATE 1 // Determines wether Gating is allowed within the zone, "1" is allowed, "0" is not
RECALL 1 // Works the same as the GATE command
SNOWCHANCE 10 // Used to decide the % chance snow will occur in the zone
RAINCHANCE 25 // Used to decide the % chance rain will occur in the zone
X1 1330 // These are the coordinates you must set to define the zoned area
Y1 1695 // X1/Y1 is point "a" X2/Y2 is point "b"
X2 1407 // You must "point A, point B" your way around the zone you want to create
Y2 1845 // Get the where coordinates for each point,
X1 1407 // and alternate between a point "a" and point "b" until you make the zone you want.
Y1 1490
X2 1680
Y2 1695
X1 1407
Y1 1695
X2 1680
Y2 1795
X1 1680
Y1 1525
X2 1730
Y2 1695
X1 1407
Y1 1795
X2 1455
Y2 1845
}

That's it, Not very hard, just quite repetitive. You can add as many guard zones as you want though I'm not sure what happens if two guard zones overlap. hehe I wouldn't recommend trying. For a zone border like Britain common, and Britain farms, you use the same coordinates for the border in both zones. Good luck, and have fun!

Back to Help Index



Advanced Trading System

Script File: Regions.scp

Usage:

    For every region you can add:
      GOOD (num) (Num is set into items.scp in every items.)
      BUYABLE (num)
        (Num range from -00 to +00 and is the % to add or remove from item value. (1000=100.0% , 342=34.2%) For example: if you have IRON ORE set as GOOD 1 (sets into items.scp) with VALUE=5 GP, and set here in region 3 (britain):
        GOOD 1
        BUYABLE -153
        when you go into Britain and say "Hi Vendor Buy" you see the IRON ORE as value 4...why???
        Simple: BUYABLE=-153
          -153 / 1000 =-0.153 (as -15.3% of original price)
          -0.153 x 5 (IRON ORE VALUE) = -0.765
          5 (IRON ORE VALUE) - 0.756 = 4(.235)
      SELLABLE (num)
        (Num range from -00 to +00 and is the % to add or remove from item value. (1000=100.0% , 342=34.2%)This is the same as BUYABLE but take effect when you say "Hi Vendor Sell".
      RANDOMVALUE (num1) (num2)
        (Num range from -00 to +00 every item will be set on VALUERATE (Random from num1 to num2) and every VendorRestock each Item Value will be modified based on valuerate). For Example: If you set IRON ORE as GOOD 1 with VALUE=10 and RANDOMVALUE -100 100, its value changes every restock-time ranging from 9 (-10.0%) to 11 (10.0%). This changes will be added afetr calculating SELLABLE and BUYABLE and take affect when you say "Hi Vendor Buy" or "Hi Vendor Sell".

Back to Help Index



Houses

The new house system works as Follows:

Everything is stored in house.scp there are 2 types of sections for this file:
SECTION HOUSE # (This will be used in the deed's morex)
{
ID #### (Multi id# (From insideUO) take the number inside UO gives and add 40, so a small house is 0000068 this translates into ID 4068)
SPACEX # ((optional)The RADIUS of clear space needed from the center of the house.)
SPACEY # ((optional)Same as SPACEX only for the Y axis)
CHARX # ((optional)Offset from the center of the house that the Person making the house will be placed at when the house is built)
CHARY # ((optional)Same as charX only for Y)
CHARZ # ((optional)Same as charX only for Z)
HOUSE_ITEM # (This refers to the other type of sections in house.scp for placing Misc items in the house, Up to 100 per house.)
}

SECTION HOUSE ITEM # (For items place in and around the house)
{
ITEM # (Item # from items.scp)
LOCK ((optional) makes the item's more=the key's more, so in effect makes that item lockable, mostly for signs, doors, and chests.)
MOVEABLE ((optional)Default is that all items are not movebale, use this to make them moveable)
DECAY ((optional)Make the item Decay)
NODECAY ((optional) Default, make the item not decay)
PACK ((optional) Makes the item appear in the player's backpack)
X (Offset from the center of the house)
Y (Same as X only for Y)
Z (same as X only for Z)
}

Set the deed's moreX to the SECTION HOUSE number and that house an all associated items will be added. You can enter your house without unlocking the door if you have the key in your MAIN pack. Just like OSI.... "You quickly unlock, use, then relock the door." Enjoy the new housing system!

Back to Help Index



HTML Stream

The HTML Stream feature allows UOX to print an HTML file (You set the name and DIR) with the data you specify.... Example, Say I'm running a UOX shard, and run my webpage locally, and I want UOX to print my shard's status, every, lets say, 30 secnods. I set HTML to 30 in server.scp and then script my web page in htmlstrm.scp (See below) and every 30 seconds UOX will create this webpage as I have scripted it.

server.scp: In SECTION SERVER add the line: HTML # somewhere.. where number is the Time IN SECONDS you want the page to update, 0 or -1 will disable html streaming.

htmlstrm.scp: *Note* All commands MUST have their own line. Commands Must be first thing on the line, everything after the command will be ignored.(Exept for LINE)

SECTION ONLINE_PAGE
{
C:\UOX\index.html File name MUST be first. filename and dir should be the ONLY things on this line

LINE Put HTML tags, and ANYTHING here that you would like the page to show, in HTMl code, like images, colors fonts etc.. Put as many as you want.

TIME -this command will rpint the current time in "hh:mm:ss AM/PM" format.

NOW -This command will get the NEXT online player's name, so If I make 10 of these commands, each command will show a player's name, only the first 10 names will be displayed, the others will be ignored.

NOWNUM -Number of people online

ACCOUNTNUM -Number of accounts on the server

CHARCOUNT -Number of characters on the server (Large shards may experience a LITTLe lag with this.. if you use NPC before this command, charcount will be cached, so if you use charcount, you might as well use NPCS, and viceversa)

NPCS -Number of NPCs on the server

ITEMCOUNT -Number of items on the server (Small lag on large servers)

UPTIME -Time the server has been up in hh:mm:ss format

IP # -IP of the server # is the number of the server in the ini (First entry is number 1 so put IP 1)

GMNUM -Number of GMs online.

CNSNUM -number of counselors online

PDUMP -Performance dump (
after each line)

SIMCYC -Simulation cycles per second (Number only)

UDTIME -How often the page is updated (The number you scripted in server.scp (in minutes))

VER -Shows the server version and OS (ei "70.03.00 [WIN32]" or "70.03.00 [LINUX]")

BUILD -Shows the UOX Build number (eg: Build 15g)
}

SECTION OFFLINE_PAGE
{
C:\UOX\index.html -- FILENAME FIRST!!!
When the server is shut down, this page will be saved, commands avalible here are LINE, UPTIM, and TIME only.
}

Back to Help Index



Instalog/Timeout

Everything is marked with //Instalog, there's one bugfix and one lagfix marked with (//LagFix in priv3target() ) and (//BugFix in checkauto() ). If ya wanna check for characters in world use online() this will show characters that are logedout, but not timed out. other wise if you wanna check Characters on line and in the world (Like for Messages) use a for(now) loop with perm[].

Inn locations are scripting at the end of regions.scp and SECTION INSTALOG {} thanks to Mr.Fixit for scripting them. Timeout time is in server.scp SECTION SERVER {} CHAR_TIME_OUT (in seconds, default is 300(5 Minutes).

Back to Help Index



NEWBIE.SCP
SECTION BESTSKILL 0 Refers to skills in SKILLS.SCP
{ // ALCHEMY
PACKITEM Refers to ITEMS.SCP
}

SECTION DEFAULT
{ // THIS GOES TO ALL NEWBIES DESPITE SKILL
PACKITEM Refers to ITEMS.SCP.
}

Be aware that item 328 is a bag; as this has 'newbie' privilege, it will protect all items in it from loss due to death. Comment it out // if this is not a feature on your shard.

- The newbie.scp is set up accoring to skills.
- ALCHEMY 0
- ANATOMY 1
- ANIMALLORE 2
- ITEMID 3
- ARMSLORE 4
- PARRYING 5
- BEGGING 6
- BLACKSMITHING 7
- BOWCRAFT 8
- PEACEMAKING 9
- CAMPING 10
- CARPENTRY 11
- CARTOGRAPHY 12
- COOKING 13
- DETECTINGHIDDEN 14
- ENTICEMENT 15
- EVALUATINGINTEL 16
- HEALING 17
- FISHING 18
- FORENSICS 19
- HERDING 20
- HIDING 21
- PROVOCATION 22
- INSCRIPTION 23
- LOCKPICKING 24
- MAGERY 25
- MAGICRESISTANCE 26
- TACTICS 27
- SNOOPING 28
- MUSICIANSHIP 29
- POISONING 30
- ARCHERY 31
- SPIRITSPEAK 32
- STEALING 33
- TAILORING 34
- TAMING 35
- TASTEID 36
- TINKERING 37
- TRACKING 38
- VETERINARY 39
- SWORDSMANSHIP 40
- MACEFIGHTING 41
- FENCING 42
- WRESTLING 43
- LUMBERJACKING 44
- MINING 45
- 46 has a purpose so leave it blank DO NOT EDIT IT
- 47 is for default items that go to all newbies no matter what skill they have. This may be editd like 0 - 45.
- To edit it just add:
PACKITEM ##
where ## is the number of the item in the items.scp. Item lists may be used here too. This is exactly like how PACKITEM is used in the npc.scp.

Back to Help Index



Player Vendors

HARDCODED Player vendor NPC # is 2117, this means whatever NPC is # 2117 will be added as a player vendor.. you could make an Orc or a daemon vendor, it'll work :-).

Say Vendor buy to the vendor and you will get a targeting cursor target what's you wanna buy, and if you have enough money, it's yours. If you own the vendor, you can drag things on and off the vendor, when you drop something in his pack (not ON him) You will be asked to set the price, set it to 0 and the default from scripts will be used, you will then be asked to set a description. To get the gold from you vendor, just say "vendor gold" and he will tell you how much you have earned that day, how much he is keep as his pay (10%) and how much is left for you. If he has made less than 10 gold, he keeps ALL of it. If he has made more than 65535 gold, things get tricky. It *should* work out so if you make lets say, 80,000 gold, you should say vendor gold twice, the first time he will give you 65535, the next time, he will give you whats remaining, but he will take his 10% out both times, so be careful or he'll rip you off :-)

A player vendor deed can be ANY time with type 217.

Back to Help Index



Races

This is only a first and prelimenary implementation of player races. You will find that there has been another script added to the build, races.scp. Inside races, you will find the definitions for 11 existing races (not completely fleshed out). Basically, here is the layout for the player races.

SECTION RACE #
{
NAME Dwarf // Name of race
STRCAP 100 // Cap on strength
DEXCAP 100 // Cap on dexterity
INTCAP 100 // intelligence cap
REQUIREBEARD // Males must have beards, will add if needed
NOBEARD // Must have no beard, will delete if they have it
GENDER MALE // Only males can be this race, acceptable values MALE, and FEMALE
BEARDMIN 0440 // Min beard colour, must have max also, if 0, then disabled
BEARDMAX 0480 // Max beard colour, must have min also, if 0, then disabled
SKINMIN 0480 // Skin min colour, must have max also, if 0, then disabled
SKINMAX 0520 // Skin max colour, must have min also, if 0, then disabled
HAIRMIN 0440 // Hair min colour, must have max also, if 0, then disabled
HAIRMAX 0520 // Hair max colour, must have min also, if 0, then disabled
SKILLNAMEG 2 // Skill name gain and how much (SKILLNAME = MAGERY or whatever skill you want)
SKILLNAMEL 2 // skill name loss and how much
RACIALENEMY 1 // Racial enemy number... can be more than one entry
RACIALAID 2 // Racial aid number... can be more than one entry
LIGHTDAMAGE 5 // take 5 damage from light
LIGHTAFFECT // if here, take damage from light
LIGHTSECS 5 // take damage from light every 5 secs
HEATDAMAGE 5 // take 5 damage from heat
HEATAFFECT // if here, take damage from heat
HEATSECS 5 // take damage from heat every 5 secs
COLDDAMAGE 5 // take 5 damage from cold
COLDAFFECT // if here, take damage from cold
COLDSECS 5 // take damage from cold every 5 secs
LIGHTNINGDAMAGE 5 // take 5 damage from lightning
LIGHTNINGAFFECT // if here, take damage from lightning
LIGHTNINGSECS 5 // take damage from lightning every 5 secs
RAINDAMAGE 5 // take 5 damage from rain
RAINAFFECT // if here, take damage from rain
RAINSECS 5 // take damage from rain every 5 secs
SNOWDAMAGE 5 // take 5 damage from snow
SNOWAFFECT // if here, take damage from snow
SNOWSECS 5 // take damage from snow every 5 secs
NIGHTVIS 3 // night vision bonus... the number is the light level bonus you get at ANY time
PLAYERRACE 0 // 0 is nonplayer race, 1 is player race
LANGUAGEMIN 500 // skill value needed to interpret that races speech
}

Skill gain/loss information can be adjusted dynamically now, though it still can default to:
For skill gain

0 None
1 Slight
2 Moderate
3 Significant

and for skill loss

0 None
1 Slight
2 Moderate
3 Significant

Basically, add a SECTION COMBAT MODS like this

SECTION COMBAT MODS
{
MOD0 0     // % bonus for mod 0
MOD1 5
MOD2 10
MOD3 25
MOD4 50
}

If you don't have at least 4 entries, the defaults are used.

Any racial aid is flagged green, and an enemy is flagged orange. Murderers still take precedence over everything though. Race name will show up in paperdoll, as well as above their char when you click on them, as long as it is not the default race. Skill bonuses and losses are in as well (I believe), but haven't really tested this all too well. I have allowed for the creation of race gates as well, which are one time only uses (type 83, examples in file). So you will start out as a human, but can only switch races once. So be warned! There is a way to make them reusable, but that is VERY fantasy shattering, being able to switch constantly.

General:

I realize it's not that flash an implementation (only really useful if we could have newer art, and different object IDs... ah well, perhaps one day). But I hope you like it, nonetheless. Either way, it should be a simple thing to do.

Enjoy!!!

I have other tasks for now like adding new skills. Going to try and tackle that! It's easy enough to modify the Skills.mul and skills.idx file. Already done that and added entries. Plus I plan on adding a newer better weather system, to complement some of the features in here.

Adding a race gate:

Adding a race gate is actually quite simple. Just follow the layout I put below, for items.scp

SECTION ITEM 11501
{
NAME Elf // name of the gate
ID 0dda // moongate type... I only use this because it is easily visible
COLOR 0015 // color of moongate
DIR 1 // direction facing... who knows?
TYPE 83 // MUST be type 83, otherwise it won't work
MOREX 1 // Race to convert to
MOREY 0 // 0 means it's not reusable, 1 means it is
}

Also, I have modified the script for existing weapons... only useful for weapons anyway :) If you add what's following, it will work as a racial weapon. I have been thinking about racial armour, but who knows?

RACE 0     // Racial weapon against race 0

Add this to the item you want to modify, and it does double damage on that race. Abaddon, Angel of the Abyss

Back to Help Index



Spawn.scp

SECTION SPAWNREGION 0 // The number doesn't really matter here.. Just helps keep track
{
LIST 500 // NPC list, can have upto 512 of these in one spawn region.. Random NPC will be picked each time
MAX 1000 // Max characters spawned in this region (With new speed stuff this can be a LOT)
X1 1 // Top left X chord
Y1 1 // Top left Y chord
X2 5000 // Lower right X chord
Y2 5000 // Lower right Y chord
MINTIME 0 // Minum spawn time, Randomly picked between min and max for next spawn
MAXTIME 10 // Maximum spawn time, 0 and 0 will spawn once every 10 seconds
}

SECTION PREDEFINED_SPAWN TOWN // NAME of predefined spawn
{
LIST 500 // Same as Above
MAX 1000 // Same as above
MINTIME 0 // Same as above
MAXTIME 10 // Same as above
// Predefined spawns are to be placed in regions.scp like SPAWN TOWN
// Doing so will use the region's X and Y with the info from the PREDEFINED_SPAWN to set up a spawn region
}

EOF // MUST be here!!!! If this isn't here uox will freeze in an infy loop

Back to Help Index



Splitting Monsters

npc.scp:

add these commands to any npc

SPLIT ##
SPLITCHANCE ##

where SPLIT is how many it can split into when hit

SPLIT 3

it has a posibility of spliting up to 3 extra npcs each time hit

and where SPLITCHANCE is the chance that an NPC has to split when hit

SPLITCHANCE 50

the npc has a 50 percent chace of splitting each time hit.

Back to Help Index



Spellcasting Monsters

This is a brief guide on how to set up monsters for using magic. Settings:-

In order for your monsters to use spells you must include the SPATTACK and SPADELAY settings under the Monsters section in the npc.scp file. The value SPATTACK is set to is a combination of bits represented decimally, and the value SPADELAY is the delay between each time the monster uses a spell. There is an example below if you are confused. The first 13 bits represents spells and the last 3 Fireballs.

Spell Table:-

Bit dec Spell
1 1 MagicArrow
2 2 Harm
3 4 Clumsy
4 8 FeebleMind
5 16 Weaken
6 32 Fireball
7 64 Curse
8 128 Lighting
9 256 Paralyze
10 512 MindBlast
11 1024 Engerybolt
12 2048 Explosion
13 4096 FlameStrike
14 8192 Dragon Breath - 20 % of source health
15 16384 Dragon Breath - 40 % of source health
16 32768 Dragon Breath - 60 % of source health

A monster using lighting, fireball and explosion. SPATTACK = 2198 The value is calculated as so:- 2198 = 128(lighting) + 32 (fireball) + 2048 (Explosion)

The damage your monster will do with a spell cast is set using the MAGERY SKILL setting, again in the monsters section of the ncp.scp/uox3.scp. The level of magery will effect the damage in the same way fit does for player characters. The exception to the rule is damage the last 3 Fireballs which is set by the level of hits points of the monsters.

Setting the magery level.
SKILL 25 700
SKILL is the setting name
25 is the magery id in the skill table
700 is 70 magery (level/10)

Example Monsters
SECTION NPC 24
{
NAME a lich
ID 0018
SKIN 0000
DIRECTION N
BACKPACK
GOLD 120 230
PACKITEM 104
ATT 80
DEF 70
STR 200
INT 150
DEX 35
NPCWANDER 4
FX1 -1
FX2 20
FY1 -1
FZ1 -1
FAME 4000
KARMA -5000
NPCAI 2
LOOT 10
SPATTACK 8191 All spells
SPADELAY 30
SKILL 25 700 70 magery
}

SECTION NPC 93
{
NAME an ancient wyrm
ID 003b
SKIN 07de
DIRECTION N
BACKPACK
ATT 350
DEF 150
STR 1500
DEX 50
INT 600
NPCAI 0
LOOT 1
GOLD 800 2000
NPCWANDER 4
FX1 -1
FY1 -1
FZ1 -1
FX2 20
FAME 10000
KARMA 500
LOOT 10
SPATTACK 32768 60 % hit dammage fireball only
SPADELAY 80
}

Back to Help Index



Gump System, inscribe.gmp

New Gump System:

Read the inscribe.gmp file, it is well documented and should be easy to follow. If you then go into the UOX code you will see how i implemented it. Now I did NOT write the new gump system, rather Kathrrack did, and I am very impressed by it. Note that you now have to compile with the im.cpp, im.h and fromuox.h files to get all this to work properly.

Inscription:

Ok guys, inscription as we all know it is now here, straight from UO itself. It works like normal, click on inscribe skill, click on blank scroll (0e 34) select circle then spell and poof, you now have a scroll of whatever. Inscription currently checks the inscribe skill on a sliding scale based on the spell you are inscribing. This may need later tweaking if it is too easy to do (or too hard for that matter)

Engraving:

This is new and non-UO, select inscribe skill and target a piece of armor. It will then ask you for circle and spell to engrave. If successful, you will place the spell on the item with 5 charges on it. This checks the magery skill, the tinkering skill and the inscription skill, it is rather hard to master. Again this may need tweaking later. A player may engrave any item that has att or def greater than zero, thus shirts, armor, weapons, hats may all be engraved. Food and pets may NOT.

Back to Help Index