getRoomUpgrade
exports["RiP-Hotels"]:getRoomUpgrade(hotelID, roomID, upgradeName)
This function fetches a certain item in room's storage
Arguments
Name | Type | Optional | Explenation |
---|---|---|---|
hotelID | Integer | No | Hotel id |
roomID | Integer | No | Hotel room id |
upgradeName | String | No | Upgrade name (config RiP.Upgrades ) |
Returned Value
Returns the upgrade level as an integer
or false
if the room or upgrade couldn't be fetched
Example
local upgradeLevel =exports["RiP-Hotels"]:getRoomUpgrade(1, 101, 'storage')
print("the storage upgrade level is "..(upgradeLevel or 0))