RunUO Community

This is a sample guest message. Register a free account today to become a member! Once signed in, you'll be able to participate on this site by adding your own topics and posts, as well as connect with other members through your own private inbox!

[RunUO 2.0 SVN 199] The 'Cut-o-matic' Lumber Addon

FingersMcSteal

Sorceror
[RunUO 2.0 SVN 199] The 'Cut-o-matic' Lumber Addon

Update 23/December/2008
New version for SVN 300 shards which use's the standard woods that are already added to servers (ML wood types) BaseLog's changed to just Log in there scripts... the CS files is the newer version at the bottom of this post, i'll leave the original addon version there too.

I've also added a Granite Furness which i'd made some time ago... Put granite in to turn it into sand.

********************************

Description
It's the 'cut-o-matic' lumber sawmill addon, ok seriously, it's a saw mill addon for normal logs. Got a pile of logs you want turned into boards then this is the item to do it. It consists of a crate at one end, a spinning saw blade on top, and a platform at the other end, all you need to do is drop a pile of logs onto the crate and collect the boards at the other end.

Features
Included features are... a totally open top spinning blade with the ability to cut your fingers off and bleed in the comfort of your own home.

Installing
Just place anywhere in the script section/folders of your shard and re-compile.
This was built on a SVN 199 Revision server with a fully patched set of game files.

Commands
No commands, once installed type [add sawmilladdondeed or add to your server how you see fit.
 

Attachments

  • SawmillAddon.zip
    2 KB · Views: 380
  • SawmillAddon.cs
    12.4 KB · Views: 138
  • GraniteFurnessAddon.cs
    12.3 KB · Views: 133

Hotshot

Sorceror
well one thing it dont do is cut logs from Karma Ore System, I tried cutting Bloodwood logs and will not cut them, only cuts normal logs. I know people can use a handsaw to cut, just think this is a nice addon.... i'll look for update
 

zoggins

Sorceror
This is freaking awesome. :) I am thinking about allowing other things to be dragged on it to be destroyed like the OSI sacrificial alter. :)
 
here is an updated version, for use with colored logs and a "demonic" twist

i have modified the on drop section for use with colored logs - it is set up to use my logs
but if you copy and paste the whole section into yours and then just replace with your logs and boards - should work
or use the full script (as discused below) and modify that section for your logs and boards

the "demonic twist" is this:
when you touch the blades - it custs off your hands
this forces you to drop anything in your hands to the ground (including gloves worn)
it then "replaces" your hands with "bloody stumps" (equal to wrestling but is base bashing and uses wrestling skill)
these are not movable - so they can not equip a weapon or shield
(might or might not be able to put on armor gloves - depends on your run uo verion and osi patch combo)
there is also added in a "magical 1st aid kit" on the saw - by double clicking it - it will magicaly reattach your hands

of course if you try to touch the blades aging when you have stumps - it tells you you want the 1st aid kit

enjoy
 

Attachments

  • SawmillAddon - Lord greywolf.cs
    11.3 KB · Views: 109

FingersMcSteal

Sorceror
I'm just glad people like it, sometimes the small simple things are all you need to make it worth while.

Nice to see someones used it and created something better.
 
well not sure about better (except for maybe the other log types)

but deffently a "different" version

just realized when i modified the name of the "stumps" i forgot a ; after it
so just add a ; at the end of line 304 - sorry about that
 

Macil

Sorceror
How might I go about adding a lumberjacking skill check to using this item? So there is a fail rate for crafting boards with this like there is with ingots and a forge?
 

FingersMcSteal

Sorceror
You would need to take a look at this part of the code...

Code:
public override bool OnDragDrop(Mobile from, Item dropped)
{
int amounttocut = 0;
if (!from.InRange(this.GetWorldLocation(), 1))
{
from.SendMessage(89, "You are too far from the machine, step closer.");
return false;
}
else
{
[COLOR=red]if (dropped is Log)[/COLOR]
[COLOR=red]{[/COLOR]
// It's a NORMAL log
Log yourlogs = (Log)dropped;
dropped.Delete();
amounttocut = yourlogs.Amount;
from.SendMessage(89, "You recieve {0} boards", amounttocut);
Effects.PlaySound(from.Location, from.Map, 0x218); // Plays the saw sound
Item spawn = new Board(amounttocut);
spawn.MoveToWorld(new Point3D(this.X, this.Y-3, this.Z+3), this.Map);
return true;
}
from.SendMessage(89, "This can only cut logs.");
return false;
}
return false;
}

After the red code would need to have the skill check code and anything else you wanted before allowing the log to go through the machine.
(Codes from the release at the top).
 

koluch

Sorceror
Bug with this version of the sawmill

Lord_Greywolf;714886 said:
here is an updated version, for use with colored logs and a "demonic" twist

i have modified the on drop section for use with colored logs - it is set up to use my logs
but if you copy and paste the whole section into yours and then just replace with your logs and boards - should work
or use the full script (as discused below) and modify that section for your logs and boards

the "demonic twist" is this:
when you touch the blades - it custs off your hands
this forces you to drop anything in your hands to the ground (including gloves worn)
it then "replaces" your hands with "bloody stumps" (equal to wrestling but is base bashing and uses wrestling skill)
these are not movable - so they can not equip a weapon or shield
(might or might not be able to put on armor gloves - depends on your run uo verion and osi patch combo)
there is also added in a "magical 1st aid kit" on the saw - by double clicking it - it will magicaly reattach your hands

of course if you try to touch the blades aging when you have stumps - it tells you you want the 1st aid kit

enjoy
If you are holding a 2 handed weapon and dbl click the first aide sign, it poofs the weapon you are holding :(

Would like to compare this version with the original, the archive at the top is no good(corrupt end of file or something)
Could someone repost the original release please?

Thanks!

Koluch
 

FingersMcSteal

Sorceror
I'll re-post the original, i'm having the same problem here at work trying to get hold of my own work from the site... once i get home of course.
 

FingersMcSteal

Sorceror
Here's a re-post of the original code and also an updated version too.

It un-zip's into its own folders, both sawmills are pretty much the same except the mill2 folder contains a slight variation which will cut the other types of logs provided there named the same in the servers.
 

Attachments

  • Sawmill.rar
    4.3 KB · Views: 40

coyan

Sorceror
I love the look, and the way this works.. Its a nice house addon for my shard, But there are a coupla problems, and its not all with your sawmill...

First, I got the one with all colors of logs, and it will accept all logs, but will only give out regular boards. When I first put it in, there where errors on both the logs, and boards, But it was an error in the capitol letters in the names, I fixed it and its the same thing, only get regular boards...

So I tried to just make boards from the carp menu and find that RUNUO 2.0 rc2 has no option for crafting colored boards, yet the boards are in the script. I have no idea how to fix that.. Im thinking that may be why im not getting colored boards with the sawmill also. You cant even craft anything with the colored boards anyway, so no biggie here...

What I would like to know tho, Is if its possible to have it cut the logs, and give more boards than using carp?? I was hoping to get 2-3 boards per log, but again, no idea how to make it happen.. can you help with that?

Anyway, thanks for a great addon..
coy

P.S.
Ok i figured out how to get more boards on the sawmill.. here is what I changed...

Code:
if (dropped is Log)
                    {
                        // It's a NORMAL log
                        Log yourlogs = (Log)dropped;
                        dropped.Delete();
                        amounttocut = yourlogs.Amount;
                        from.SendMessage(89, "You recieve {0} boards", [COLOR="Red"]amounttocut * 4)[/COLOR];
                        Effects.PlaySound(from.Location, from.Map, 0x218);  // Plays the saw sound
                        Item spawn = new Board[COLOR="Red"]((amounttocut) * 4 )[/COLOR];
                        spawn.MoveToWorld(new Point3D(this.X, this.Y - 3, this.Z + 3), this.Map);
                        return true;
                    }
 
Top