Ravenfield

Ravenfield

87 ratings
Vision occluder remover
   
Award
Favorite
Favorited
Unfavorite
Content Type: Mutators
File Size
Posted
Updated
35.109 KB
16 Jul, 2022 @ 10:44pm
19 Jul, 2022 @ 4:33pm
3 Change Notes ( view )

Subscribe to download
Vision occluder remover

Description
This mutator removes all vision occluders (usually trees) on the map, and replace capturepoints to resupply zones.

Use this if there are too many trees dropping the framerate, or the map is suffering serious lack of resupply crates.



behaviour("mapremover")

function mapremover:Awake()
local goArray = GameObject.FindObjectsOfType(GameObject);
for i=1,#goArray do
if self.script.mutator.GetConfigurationBool("point") and goArray.GetComponent(ResupplyCrate)~=nil then
self.gameObject.Destroy(goArray)
end
if self.script.mutator.GetConfigurationBool("vision") and goArray.layer==23 then
local dt=goArray
if goArray.transform.parent~=nil then
dt=goArray.transform.parent.gameObject
end
self.gameObject.Destroy(dt)
end
end

if self.script.mutator.GetConfigurationBool("point") then
for i=1,#ActorManager.capturePoints do
local laserHit = Physics.Raycast(Ray(ActorManager.capturePoints.transform.position+Vector3(0,30,0), Vector3(0,-1,0)), 100, RaycastTarget.Opaque)
if laserHit ~= nil then
self.gameObject.Instantiate(self.targets.resupplyzone, ActorManager.capturePoints.transform.position+Vector3(0,30-1*laserHit.distance, 0), Quaternion.Euler(-90,ActorManager.capturePoints.transform.eulerAngles.y,0))
end

for c=1,ActorManager.capturePoints.transform.childCount do
ActorManager.capturePoints.transform.GetChild(c-1).gameObject.SetActive(false)
end
end
end
self.gameObject.Destroy(self.gameObject)
end
15 Comments
CAPT Nowa ★|||| 25 Nov, 2022 @ 11:52am 
Hey, noticed a bug where the first option box would glitch TOW launcher turrets as well as sometimes the stands of MG turrets
I love this mod, it's pretty handy but is there some way to fix that?
Snaz 29 Jul, 2022 @ 11:27am 
Deforestation, the mutator. :steamthumbsup:
MURP 22 Jul, 2022 @ 6:32pm 
idk if you can do this but can you pls make a mod that can change mag size dmg balance damage
Tony 21 Jul, 2022 @ 10:48am 
Literally gave me +10 fps in sofa's overlord wth, Im not expecting that.
1650th 20 Jul, 2022 @ 5:36am 
Nice
吾乃白丁MR500 19 Jul, 2022 @ 6:48pm 
great!!!!!!
Titanus 17 Jul, 2022 @ 10:37pm 
Noice
Hijong park  [author] 17 Jul, 2022 @ 8:54pm 
How would that mutator work ?
Jake 17 Jul, 2022 @ 7:55am 
hey can we get a seperate flag resupply mutator?
NOOB 17 Jul, 2022 @ 5:55am 
프레임 올라가서 좋네요