The Cartooners Posted August 31, 2008 Share Posted August 31, 2008 OK, I have moved my Item command to the Author Script section as seen below. function zitemArmour:OnPickUp() -- #GroupDescription=onPickUpArmour -- -- #Comment=onPickUpArmour Comment -- OnItemPickUp() end The function call also exists within the Author Script section as seen below. function OnItemPickup() --IncrementPickUpCount() if varPickedUpCount > 1 then --if currentZone ~= nil then -- if item ~= nil then -- item:MoveTo(currentZone) ErrorMsgPickUp() -- end --end else --if currentZone ~= nil then -- if item ~= nil then -- zitem.item:MoveTo(Player) GoodMsgPickUp() -- end --end end end As you can see I have commented a lot of stuff out to just get the basic function call to work BUT I receive an error "attempt to call global 'OnPickUP()' (a nil value)" Anyone any ideas on this one? Thanks Quote Link to comment
+Geofellas Posted August 31, 2008 Share Posted August 31, 2008 OnItemPickUp() function OnItemPickup() Spot the difference (hint: check character case) Quote Link to comment
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.