How do you have an object use another object as a sword

How can you make an object hold another object as a sword/gun etc

Here is another topic about this: [url]Layering Sprites]