Jump to content

disable pickups


Fury

Recommended Posts

addEventHandler("onPlayerPickupUse",getRootElement(), 
function ananza() 
if ( not wasEventCancelled() ) then 
setTimer ( cancelEvent(), 1000, 1 ) 
outputChatBox ( "#c0c0c0* Repair pickups #abcdefdisabled#c0c0c0!", getRootElement(), 255, 0, 0, true ) 
end) 
addEventHandler("onMapStarting", getRootElement(), ananza) 

is that code is right? :)

ps: its for race mode.

Link to comment
Guest Guest4401
onPlayerPickUpRacePickup

Parameters

int/string pickupID, string pickupType, int vehicleModel 

  • pickupID: the number of the pickup in case of MTA:Race syntax (starting at 1), or the "id" attribute of the pickup in case of DM syntax.
  • pickupType: the pickup type. Can be "nitro", "repair" or "vehiclechange".
  • vehicleModel: if the pickup is of type vehiclechange, this is the vehicle model that it sets.

Source

The source is the player that picked up the pickup.

You can use this, but it's from race resource, so you must also use addEvent.

Link to comment
onPlayerPickUpRacePickup

Parameters

int/string pickupID, string pickupType, int vehicleModel 

  • pickupID: the number of the pickup in case of MTA:Race syntax (starting at 1), or the "id" attribute of the pickup in case of DM syntax.
  • pickupType: the pickup type. Can be "nitro", "repair" or "vehiclechange".
  • vehicleModel: if the pickup is of type vehiclechange, this is the vehicle model that it sets.

Source

The source is the player that picked up the pickup.

You can use this, but it's from race resource, so you must also use addEvent.

thanks :)

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...