Hooks/Server/playerBoughtFood

From Official DarkRP Wiki
Jump to: navigation, search
Hook
Hook name playerBoughtFood(Player ply, table food, Entity spawnedfood, number cost)
Description:
Called when a player bought food.
Returns: nil
Realm: NewerServer.png
BBCode Link: [b][url=http://wiki.darkrp.com/index.php?title=Hooks/Server/playerBoughtFood]playerBoughtFood hook[/url][/b]

Parameters

  1. ply (Player)
  2. The player who bought food.

  3. food (table)
  4. Food table.

  5. spawnedfood (Entity)
  6. Entity of spawned food.

  7. cost (number)
  8. How much player paid.

Return values

This hook does not accept return values. You can still return a value to override the default implementation of this hook.