Taalasmaa Posted July 23, 2009 Posted July 23, 2009 Hello, I was wondering, that how to make money pickup.. With respawn I tried code what was in mta development, but didn't work. So, I don't wanna money drop, just pickup I maked nice money pot script which you have to find, but how can I do money pickup which give 10k
Taalasmaa Posted July 24, 2009 Author Posted July 24, 2009 Yes, I tried.. There's codes what I tried: createPickup ( -2056.58, -184.65, 225.32, 1274, 10000, respawnTime = 30000 ) and also: <pickup id="pickup (money) (1212)" amount="10000" posX="2479.5717773438" posY="-1657.3337402344" posZ="13.326832771301" respawn="30000" type="money" /> And there was also one, but I can't find it anymore So i'm tried createPickup.
norby89 Posted July 24, 2009 Posted July 24, 2009 createPickup ( -2056.58, -184.65, 225.32, 1274, 10000, respawnTime = 30000 ) local money = createPickup ( -2056.58, -184.65, 225.32, 3, 1274, 30000 ) function pickupUse ( player ) givePlayerMoney ( player, 10000 ) end addEventHandler ( "onPickupUse", money, pickupUse ) You forgot the type of the pickup, which must be 'custom' and 'amount' only works for health, armor or weapon pickups so you can't just put it in there like that, however you can attach an event handler to the pickup so when a player steps on it, you give them 10k. If you want to be able to pick it up while in a car too then use "onPickupHit" instead.
Lordy Posted July 24, 2009 Posted July 24, 2009 err.. What does the respawnTime = 30000 do there? That'd output syntax error I think Edit: You edited it nub norby89 now
Taalasmaa Posted July 25, 2009 Author Posted July 25, 2009 Worked, but if it reaspawn nobody cannot see the icons.. But you can pickup it... But canno't see the icon "money icon" or/marker, How to fix it?
50p Posted July 25, 2009 Posted July 25, 2009 It's a bug. The pickup will appear when it's streamed in. Go far away from the pickup location and come back, you will see it. The only solution would be to create the pickup in the same place and delete the one that respawns.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now