Lopaskurwa
Well-Known Member
- Joined
- Oct 6, 2017
- Messages
- 936
- Solutions
- 2
- Reaction score
- 57
Hello,
so i have really simple script which works like this You press on tree(use) it transforms that tree to another object and creates item so basically this script blueberry bush you press use you take those blueberrys from the tree, but i dont know how to reset it back after one hours so its like grows back.
So once you press use it wont go back to 14480 so i want to make after like one hour it goes back to 14480 and you can take those blueberries again so basically you can repeat same action after one hour
TFS 1.2
so i have really simple script which works like this You press on tree(use) it transforms that tree to another object and creates item so basically this script blueberry bush you press use you take those blueberrys from the tree, but i dont know how to reset it back after one hours so its like grows back.
Code:
function onUse(cid, item, frompos, item2, topos)
bluebushid = 14480 -- Itemid of the blueberry bush
bushid = 14481 -- Itemid of the empty bush
blueberryid = 2677 -- Itemid of blueberries
doTransformItem(item.uid, bushid)
doCreateItem(blueberryid, 3, frompos)
doDecayItem(item.uid)
end
So once you press use it wont go back to 14480 so i want to make after like one hour it goes back to 14480 and you can take those blueberries again so basically you can repeat same action after one hour
TFS 1.2