summaryrefslogtreecommitdiff
path: root/gamemode/itemsystem/common.lua
diff options
context:
space:
mode:
authorAlexander Pickering <alexandermpickering@gmail.com>2016-04-30 13:42:44 -0400
committerAlexander Pickering <alexandermpickering@gmail.com>2016-04-30 13:42:44 -0400
commit677682840305841d4538c6f5d5151f36959ae56f (patch)
tree5c54da005a0648837f76567fdfb02335a1eced52 /gamemode/itemsystem/common.lua
parent57b9d6d553943190c58b7d5f77d2ee475fe36479 (diff)
downloadgmstranded-677682840305841d4538c6f5d5151f36959ae56f.tar.gz
gmstranded-677682840305841d4538c6f5d5151f36959ae56f.tar.bz2
gmstranded-677682840305841d4538c6f5d5151f36959ae56f.zip
More work on makeing things plantable
Diffstat (limited to 'gamemode/itemsystem/common.lua')
-rw-r--r--gamemode/itemsystem/common.lua12
1 files changed, 11 insertions, 1 deletions
diff --git a/gamemode/itemsystem/common.lua b/gamemode/itemsystem/common.lua
index 674c0ce..5a47c24 100644
--- a/gamemode/itemsystem/common.lua
+++ b/gamemode/itemsystem/common.lua
@@ -17,6 +17,16 @@ function startProcessGeneric(player, string, time, ondone)
end)
end
-function genericMakePlantable( tbl )
+local function plant(player, planttype)
+ print("Plant method called!")
+end
+function genericMakePlantable( tbl )
+ local plant = function(player)
+ plant(player,tbl.Name)
+ end
+ if(tbl.Actions == nil) then
+ tbl.Actions = {}
+ end
+ tbl.Actions["Plant " .. tbl.Name] = plant
end