Go Back   RunUO - Ultima Online Emulation > RunUO > FAQ Forum

FAQ Forum A place to find answers to the most frequently asked questions, and a place to post said answers. Do NOT use this forum to ask questions.

Reply
 
Thread Tools Display Modes
Old 04-16-2008, 05:44 PM   #1 (permalink)
Master of the Internet
 
Lord_Greywolf's Avatar
 
Join Date: Dec 2005
Posts: 6,038
Send a message via Yahoo to Lord_Greywolf
Default Light on weapons or any equipable object

ok - finialy figured this out WITH OUT having to use up a layer for it

use an existing item all players have

this requires mul mods and then patching to players

and a short addin the scripts for the items you want to light up

1st step - need a mul modifier - i suggest Mulpatcher
I also suggest you read this thread:
Interactive Custom Art Tutorial

need to make a copy of the backpack art & art gump pics
start up mulpatcher, load up art, artgump and tiledata
find the pics for the backpack in art and artgump - save them to bitmaps
then find and empty spot in both (0xE5B and 0xC4F5 work nicely)
set them to the correct bitmap that you saved
and write own the animation number for the gumpart - if using above should be 1A5
then go into tile data
find the spot you used for new back pack (if as above 0xE5B)
an use the following settings in there
Name: backpack
weight: 3
height: 1
Quality (not quanity): 21
unknown 4: 1
then chack:
A
Container
Wearable
Lightsource

save art, artgump & tiledata

then patch those 5 files to your players

Now the easy step:

add this in the weapon, armor, etc script
or merge it in if you have these sections all ready

Code:
		public override bool OnEquip( Mobile from )
		{
			if (base.OnEquip( from ))
			{
				if(from is PlayerMobile && from.Backpack != null)
				{
					from.Backpack.Light = LightType.Circle300;
					from.Backpack.ItemID = 3675;
				}
			}
			return base.OnEquip( from );
		}

		public override void OnRemoved( object parent )
		{
			if ( parent is Mobile )
			{
				Mobile m = (Mobile)parent;
				if (m.Backpack != null) m.Backpack.ItemID = 3701;
			}
			base.OnRemoved( parent );
		}
now even though that says 300 circle - it really is smaller (but evewn the latern works that way - bigger on ground than when carrying)

when they equip the item - presto they have light
when it is removed - they don't

Works great - does not take up a layer slot
and you can have some light there for them
__________________
http://www.AoAUO.com

:) ..... Come for the Customs, Play for the Fun. Return to see your new Friends ..... :)
Lord_Greywolf is offline   Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



Powered by vBulletin® Version 3.7.0
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
SEO by vBSEO 3.2.0 RC5