Accessing object in the main game from mod?

Hi,

Is it possible to make a mod that access a supposing existing object of the main game (TheIsland) and change it’s behavior or coords in realtime ?

I believe I need to have a Blueprint in my mod folder, with nodes in the graph section describing the behavior of the target objet, but I don’t know how to do that.

  • How can I access a main scene object (ex : Waterplane) from a mod ?
  • How can I change it’s behavior (ex : Waterplane.z = sin(t)) ?

Thanks in advance.

I don’t necessarily know the right way to do this, but when i was creating a well object I filled the center with a water material and was playing with the existing materials in the ark resources. If you take a look at the lake water material, simply search “water” with the filter “material” on it will be toward the beginning of list. But if you open up this material to edit it and you go into the “Graph” tab you can see exactly how they make it go up and down in time. The function is called UV Displacement.

Thanks for your help. My objective is to find a way to access any object of TheIsland from my mod. Is it possible to have a reference to the scene objects and modify their properties during runtime ?

you mean while you are actually running the ark client? No… you can only truly edit anything through the development kit…Its possible to load the island as the editor map in the dev kit to test things quicker but ive only heard horror stories about trying to run it there.

So bad, I wanted to make a mod with ocean tide. I remember when I made Flash games, you could access all object properties from a child script by calling parent.object.x, or root.object.x, and I thought I could do the same in Unreal.
So, it is impossible to move water, or change obelisks position without making a total conversion ?

Yeah you would have to make a Map mod or total conversion to make changes to those features as many other things depend on those being where they are and behaving how they do.

Not tested but you should be able to do a “get all actors of class” to get a reference to the waterplane. That will return an array of all waterplanes in the world(i think there only is one waterplane for the ocean though). You should then be able to modify the location. There is more to water than just the waterplane, i think you would need to also modify the water physics volume and post processing volume which are probably harder to identify from a get all actors of class.

I will surely test your idea , thanks. I know I need to access physics volumes and post processing, but why would it be harder ?

The problems i see here are that if there is more than one actor of the class in the world it get’s hard to identify your actual target actors. As i mentioned i think(and i might be wrong here) that there is only one waterplane for the ocean in the level. The cave and lake waterplanes are child classes and will also get returned but you can rule them out easily by their class.
Physics and post processing volumes are far more frequent in the level and get all actors of class will return a lot. It will be a lot harder to determine the actual physics and pp volumes you want to modify.
It might be possible to store the locations of the volumes you want and then compare them with the results from get all actors of class or use the “get display name” node(i think that this is not recommended but could work in this case) and compare it to the name of the volume in the level.

It will demand work to achieve as I’m new to Unreal, but that looks promising :slight_smile:

If you are new to ue4 this could help you: https://docs.unrealengine.com/latest/INT/Gameplay/HowTo/FindingActors/Blueprints/index.html

It works ! but …
Thanks to , I’m able to move the water plane and the postprocessing volume in realtime. But I can’t move the physics volumes as they are marked STATIC. I can’t find a way to make them movable from my mod blueprint :frowning:
I have identified the volumes PhysicsVolume to PhysicsVolume_36 as wanted targets (I think, not sufficient tested).
Any idea ?