Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 5 Next »

For this command, we will utilize event dispatchers from which our AC_Cavrnus_SyncMove script will bind to. Adding event dispatchers is not mandatory, but merely a way to prevent the blueprints from being cluttered with repeated node logic.

Level Blueprint

In order for the objects in the space to be properly synced, we must mark them as sync-able. Lets do this programmatically.

  1. Locate the Level Blueprint by using the shown dropdown below.

image-20240619-155539.png
  1. In the Level Blueprint Event Graph, add the following CavernizeLevel. No inputs/outputs are required for this function.

image-20240619-160008.png
  1. Add the following logic to the newly created CavernizeLevel function, which finds all Actors in the level, adds a SyncWorldTransform and CavrnusPropertiesContainer along with setting the mesh to movable.

image-20240619-160149.png
  1. Finally in the Event Graph, add the following space connection logic and call the CavernizeLevel function when connected.

image-20240619-155851.png

BP_BasePawn

  1. Add AC_Cavrnus_SyncMove to BP_BasePawn

image-20240613-225916.png

TransformManager

  1. Add an event dispatcher to broadcast changes made to the ModifiedActors array.

image-20240613-230155.png

image-20240613-230211.png

  1. In the same TransformManager blueprint, locate the AddTransformActor function and add the shown logic in green. Notice here we are making use of the event dispatch.

image-20240613-230658.png

image-20240613-230709.png

  1. Lets repeat the same process but in the BP_TransformComponent.

image-20240619-154448.png

image-20240619-154710.png

  1. Call the newly added event from the following pieces of logic.

image-20240619-154517.pngimage-20240619-155317.png

Transforms are now synced!

  • No labels