diff options
| author | Alexander Pickering <alexandermpickering@gmail.com> | 2016-04-16 22:51:41 -0400 |
|---|---|---|
| committer | Alexander Pickering <alexandermpickering@gmail.com> | 2016-04-16 22:51:41 -0400 |
| commit | 573c19a5535deef9e015f0655fb495d91bac86a3 (patch) | |
| tree | bf053ad6f2e51f6208841ab3a0f0c3b828f856b7 /gamemode/craftablesystem/furnaces/techfurnace.lua | |
| parent | 522cd90fe8b9d5e797647f731b526048383ff36b (diff) | |
| download | gmstranded-573c19a5535deef9e015f0655fb495d91bac86a3.tar.gz gmstranded-573c19a5535deef9e015f0655fb495d91bac86a3.tar.bz2 gmstranded-573c19a5535deef9e015f0655fb495d91bac86a3.zip | |
Refactored some of the code for the furnaces
Diffstat (limited to 'gamemode/craftablesystem/furnaces/techfurnace.lua')
| -rw-r--r-- | gamemode/craftablesystem/furnaces/techfurnace.lua | 51 |
1 files changed, 12 insertions, 39 deletions
diff --git a/gamemode/craftablesystem/furnaces/techfurnace.lua b/gamemode/craftablesystem/furnaces/techfurnace.lua index 274ce57..2706019 100644 --- a/gamemode/craftablesystem/furnaces/techfurnace.lua +++ b/gamemode/craftablesystem/furnaces/techfurnace.lua @@ -47,47 +47,20 @@ COMBI.Results["Silver"] = 1 GMS.RegisterCombi( COMBI, "gms_techfurnace" ) -/* 5 Silver */ -local COMBI = {} - -COMBI.Name = "Silver 5x" -COMBI.Description = "Silver can be used to create more advanced buildings and tools." -COMBI.Entity = "gms_techfurnace" - -COMBI.Req = {} -COMBI.Req["Silver_Ore"] = 5 - -COMBI.Results = {} -COMBI.Results["Silver"] = 5 +local SilverMultiples = {5,10,25} -GMS.RegisterCombi( COMBI, "gms_techfurnace" ) +for k,v in pairs(SilverMultiples) do + local COMBI = {} -/* 10 Silver */ -local COMBI = {} + COMBI.Name = "Silver " .. v .. "x" + COMBI.Description = "Silver can be used to create more advanced buildings and tools." + COMBI.Entity = "gms_techfurnace" -COMBI.Name = "Silver 10x" -COMBI.Description = "Silver can be used to create more advanced buildings and tools." -COMBI.Entity = "gms_techfurnace" + COMBI.Req = {} + COMBI.Req["Silver_Ore"] = v -COMBI.Req = {} -COMBI.Req["Silver_Ore"] = 10 + COMBI.Results = {} + COMBI.Results["Silver"] = v -COMBI.Results = {} -COMBI.Results["Silver"] = 10 - -GMS.RegisterCombi( COMBI, "gms_techfurnace" ) - -/* 25 Silver */ -local COMBI = {} - -COMBI.Name = "Silver 25x" -COMBI.Description = "Silver can be used to create more advanced buildings and tools." -COMBI.Entity = "gms_techfurnace" - -COMBI.Req = {} -COMBI.Req["Silver_Ore"] = 25 - -COMBI.Results = {} -COMBI.Results["Silver"] = 25 - -GMS.RegisterCombi( COMBI, "gms_techfurnace" ) + GMS.RegisterCombi( COMBI, "gms_techfurnace" ) +end |
