Skip to content

Commit

Permalink
Merge pull request #169 from gamrguy/master
Browse files Browse the repository at this point in the history
just a whole buncha updates really
  • Loading branch information
sayterdarkwynd authored Aug 16, 2019
2 parents f4f63df + cfaa62c commit 5613283
Show file tree
Hide file tree
Showing 39 changed files with 958 additions and 1,772 deletions.
2 changes: 1 addition & 1 deletion items/generic/food/tier3/desertsalsa.consumable.patch
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
{
"op": "replace",
"path": "/description",
"value": "A refreshing salsa made from desert fruits. The taste is amazing. ^yellow;Type: Robot^reset;"
"value": "A refreshing salsa made from desert fruits. The taste is amazing. ^yellow;Type: Robot, Plant^reset;"
}
]
2 changes: 1 addition & 1 deletion items/generic/food/tier4/oceanrisotto.consumable.patch
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
{
"op": "replace",
"path": "/description",
"value": "A salty and aromatic rice dish. ^orange;Type: Cooked Meat^reset;"
"value": "A salty and aromatic rice dish. ^orange;Type: Fish, Plant^reset;"
}
]
2 changes: 1 addition & 1 deletion items/generic/food/tier4/oceansurprise.consumable.patch
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
{
"op": "replace",
"path": "/description",
"value": "A Hylotl dish, overloaded with ingredients of questionable oceanic origin. ^orange;Type: Cooked Meat^reset;"
"value": "A Hylotl dish, overloaded with ingredients of questionable oceanic origin. ^orange;Type: Fish, Plant^reset;"
}
]
2 changes: 1 addition & 1 deletion items/generic/food/tier4/oculemonstew.consumable.patch
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
{
"op": "replace",
"path": "/description",
"value": "A tangy, somewhat slimy stew made of oculemon and meat scraps. ^orange;Type: Cooked Meat^reset;"
"value": "A tangy, somewhat slimy stew made of oculemon and meat scraps. ^orange;Type: Cooked Meat, Plant^reset;"
}
]
2 changes: 1 addition & 1 deletion items/generic/food/tier4/seafoodgratin.consumable.patch
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
{
"op": "replace",
"path": "/description",
"value": "Fish baked with fish-like fruit. A fishy dish! ^orange;Type: Cooked Meat^reset;"
"value": "Fish baked with fish-like fruit. A fishy dish! ^orange;Type: Fish, Plant^reset;"
}
]
2 changes: 1 addition & 1 deletion items/generic/food/tier4/sushi.consumable.patch
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@
{
"op": "replace",
"path": "/description",
"value": "Delicious rolls of rice and seaweed. A Hylotl favourite. ^orange;Type: Cooked Meat^reset;"
"value": "Delicious rolls of rice and seaweed. A Hylotl favourite. ^orange;Type: Fish, Plant^reset;"
}
]
15 changes: 15 additions & 0 deletions scripts/fr_scripts/auraWhenLow.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@


function FRHelper:call(args, main, dt)
self.auraReload = (self.auraReload or args.auraReload) - dt
local res
if not status.isResource(args.resource) then
res = args.resourceDefault
else
res = status.resourcePercentage(args.resource)
end
if self.auraReload <= 0 and res < args.threshold then
world.spawnProjectile(args.projType, mcontroller.position(), entity.id(), args.projVelocity or {0, 0}, args.track, args.projParameters)
self.auraReload = args.auraReload
end
end
19 changes: 19 additions & 0 deletions scripts/fr_scripts/feneroxStuff.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
function FRHelper:call(args, main, dt, ...)
local nighttime = world.timeOfDay() > 0.5
local underground = world.underground(mcontroller.position())

local foodValue
if status.isResource("food") then
foodValue = status.resourcePercentage("food")
else
foodValue = args.foodDefault
end

if nighttime or underground and (foodValue >= args.foodThreshold) then
status.modifyResourcePercentage("health", args.healingRate * dt)

self:applyStats(args, args.name or "FR_feneroxNightBonus", main, dt, ...)
else
self:clearPersistent(args.name or "FR_feneroxNightBonus")
end
end
26 changes: 26 additions & 0 deletions scripts/fr_scripts/foodRush.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
--[[
Provides a speed bonus that increases when you're well fed.
Arguments:
{
"foodDefault" : 0.5, -- What food % to use on NPCs and casual mode players
"speedFactor" : 4.25, -- Changes how much speed you get per % of food bar
"minSpeed" : 1.0, -- Minimum amount of speed bonus
"maxSpeed" : 1.2 -- Maximum amount of speed bonus
}
The above default arguments show an effect that caps at +20% speed at 85% food.
]]


function FRHelper:call(args)
local foodValue
if status.isResource("food") then
foodValue = status.resourcePercentage("food")
else
foodValue = args.foodDefault
end

foodValue = foodValue / args.speedFactor
mcontroller.controlModifiers({ util.lerp(foodValue, args.minSpeed, args.maxSpeed) })
end
3 changes: 1 addition & 2 deletions scripts/fr_scripts/healthRegen.lua
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,12 @@
Simple HP regeneration effect.
Restores the given % of HP every second this is active.
Arguments:
"args" : {
"healingRate" = 0.015
}
]]

function FRHelper:call(args, main, dt, ...)
sb.logInfo(tostring(args.healingRate).." "..tostring(dt))
status.modifyResourcePercentage("health", args.healingRate * dt)
end
9 changes: 7 additions & 2 deletions scripts/fr_weaponscripts/perfectblockbonus.lua
Original file line number Diff line number Diff line change
Expand Up @@ -49,19 +49,24 @@ function FRHelper:call(args, main, ...)

local newargs = {stats={}}
for _,stuff in ipairs(args.stats or {}) do
local newStat = {stat=stuff.stat, baseMultiplier=stuff.baseMultiplier or nil, amount=stuff.amount or nil}
local newStat = {stat=stuff.stat, baseMultiplier=stuff.baseMultiplier or nil, amount=stuff.amount or nil, effectiveMultiplier=stuff.effectiveMultiplier or nil}
if args.statCombos[stuff.stat] then
local data = args.statCombos[stuff.stat]
if newStat.amount then
newStat.amount = newStat.amount + data.comboBase * (data.comboMult or 1) * main.blockCountShield
if data.max then
newStat.amount = math.min(newStat.amount, data.max)
end
else
elseif newStat.baseMultiplier then
newStat.baseMultiplier = newStat.baseMultiplier + data.comboBase * (data.comboMult or 1) * main.blockCountShield
if data.max then
newStat.baseMultiplier = math.min(newStat.baseMultiplier, data.max)
end
else
newStat.baseMultiplier = newStat.effectiveMultiplier + data.comboBase * (data.comboMult or 1) * main.blockCountShield
if data.max then
newStat.effectiveMultiplier = math.min(newStat.effectiveMultiplier, data.max)
end
end
end
table.insert(newargs.stats, newStat)
Expand Down
11 changes: 9 additions & 2 deletions species/akkimari.raceeffect
Original file line number Diff line number Diff line change
Expand Up @@ -39,5 +39,12 @@
]
}
],
"special" : [ "argonianRegen" ]
}
"scripts" : [
{
"script" : "/scripts/fr_scripts/healthRegen.lua",
"args" : {
"healingRate" : 0.0001
}
}
]
}
23 changes: 21 additions & 2 deletions species/argonian.raceeffect
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,18 @@
}
}
],
"liquidEffects" : [
{
"controlModifiers" : {
"liquidImpedance" : 0.4,
"liquidForce" : 90,
"liquidJumpProfile" : {
"jumpSpeed" : 60.0
},
"speedModifier" : 1.37
}
}
],
"weaponEffects" : [
{
"weapons" : [ "spear" ],
Expand All @@ -47,5 +59,12 @@
]
}
],
"special" : [ "argonianRegen", "swimboost1" ]
}
"scripts" : [
{
"script" : "/scripts/fr_scripts/healthRegen.lua",
"args" : {
"healingRate" : 0.0001
}
}
]
}
1 change: 1 addition & 0 deletions species/argonian.species.patch
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
^green;+40%^reset; Max Food, ^green;+6% Speed^reset;, ^green;+11% Jump^reset;
^green;+40%^reset; Poison, ^green;+10%^reset; Cosmic and ^green;+10%^reset; Radioactive Resist
^green;+1100^reset; oxygen, Swim Boost.
^green;Slowly regenerate HP^reset;
Immunity: Poison

^orange;Environment^reset;:
Expand Down
24 changes: 11 additions & 13 deletions species/avian.raceeffect
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"stats" : [
{ "stat" : "maxHealth", "baseMultiplier" : 0.85 },
{ "stat" : "maxEnergy", "baseMultiplier" : 1.1 },
{ "stat" : "powerMultiplier", "baseMultiplier" : 1.05 },
{ "stat" : "maxHealth", "effectiveMultiplier" : 0.85 },
{ "stat" : "maxEnergy", "effectiveMultiplier" : 1.1 },
{ "stat" : "powerMultiplier", "effectiveMultiplier" : 1.05 },
{ "stat" : "fallDamageMultiplier", "baseMultiplier" : 0.65 },
{ "stat" : "physicalResistance", "amount" : -0.05 },
{ "stat" : "electricResistance", "amount" : 0.25 },
Expand All @@ -24,31 +24,29 @@
{
"weapons" : [ "shortspear" ],
"stats" : [
{ "stat" : "powerMultiplier", "baseMultiplier" : 1.06 },
{ "stat" : "powerMultiplier", "effectiveMultiplier" : 1.06 },
{ "stat" : "critChance", "amount" : 1 }
]
},
{
"weapons" : [ "machinepistol" ],
"stats" : [
{ "stat" : "critChance", "baseMultiplier" : 1 }
{ "stat" : "critChance", "amount" : 1 }
]
}
],
"weaponScripts" : [
{
"script" : "/scripts/fr_weaponscripts/aviancombo.lua",
"weapons" : [ "dagger" ],
"contexts" : [
"meleeslash-fire"
]
"contexts" : [ "meleeslash-fire" ]
},
{
"script" : "/scripts/fr_weaponscripts/freebonus.lua",
"contexts" : [ "staff-init" ],
"args" : {
"stats" : [
{ "stat" : "powerMultiplier", "baseMultiplier" : 1.2 }
{ "stat" : "powerMultiplier", "effectiveMultiplier" : 1.2 }
],
"scripts" : [
{
Expand All @@ -64,7 +62,7 @@
"aerialEffect" : {
"airStats" : {
"stats" : [
{ "stat" : "powerMultiplier", "baseMultiplier" : 1.12 }
{ "stat" : "powerMultiplier", "effectiveMultiplier" : 1.12 }
]
},

Expand All @@ -75,8 +73,8 @@
"windLow" : {
"speed" : 5,
"stats" : [
{ "stat" : "maxHealth", "baseMultiplier" : 1.15 },
{ "stat" : "protection", "baseMultiplier" : 1.1 }
{ "stat" : "maxHealth", "effectiveMultiplier" : 1.15 },
{ "stat" : "protection", "effectiveMultiplier" : 1.1 }
],
"controlModifiers" : {
"speedModifier" : 1.19,
Expand All @@ -87,4 +85,4 @@
}
},
"tech" : [ "flight_avian" ]
}
}
61 changes: 28 additions & 33 deletions species/callistan.raceeffect
Original file line number Diff line number Diff line change
Expand Up @@ -18,38 +18,33 @@
{ "stat" : "slushslowImmunity", "amount" : 1 }
],
"diet" : "carnivore",
"envEffects" : [{
"biomes" : [
"garden",
"forest",
"tundra",
"snow"
],
"stats" : [{
"stat" : "maxHealth",
"baseMultiplier" : 1.15
},
{
"stat" : "powerMultiplier",
"baseMultiplier" : 1.1
}
]
}],
"weaponEffects" : [{
"weapons" : [
"energy"
],
"stats" : [{
"stat" : "energyRegenPercentageRate",
"baseMultiplier" : 1.25
},
{
"stat" : "critChance",
"amount" : 3
"envEffects" : [
{
"biomes" : [ "garden", "forest", "tundra", "snow" ],
"stats" : [
{ "stat" : "maxHealth", "baseMultiplier" : 1.15 },
{ "stat" : "powerMultiplier", "baseMultiplier" : 1.1 }
]
}
],
"weaponEffects" : [
{
"weapons" : [ "energy" ],
"stats" : [
{ "stat" : "energyRegenPercentageRate", "baseMultiplier" : 1.25 },
{ "stat" : "critChance", "amount" : 3 }
]
}
],
"scripts" : [
{
"script" : "/scripts/fr_scripts/foodRush.lua",
"args" : {
"foodDefault" : 0.5,
"speedFactor" : 4.25,
"minSpeed" : 0.0,
"maxSpeed" : 0.2
}
]
}],
"special" : [
"callistanFoodRush"
}
]
}
}
Loading

0 comments on commit 5613283

Please sign in to comment.