More Lua functions

Item:isContainer() / Container:isContainer()
Item:getParent()
Item:getTopParent()
Container:getItemCountById() / Tile:getItemCountById()
Creature:getParent()
Player:getContainerId()
Player:getContainerById()
Player:getContainerIndex()
Small changes

Return true if item:getParent() or item:getTopParent() has a virtual
cylinder.
Defined weapon types in Lua

Use them with itemType:getWeaponType()
Added a few functions to global.lua
WEAPON_DIST was also changed to WEAPON_DISTANCE
Small cleanup