Hi, so I’ve managed to be able to change the location of the scene capture component using these blueprints below. But for some reason when i try to change the Z axis the capture doesn’t change. Now i have the outer part of the platform showing on the camera view (Which I don’t want) Need help resolving this issue.
Here’s a link to a gif I made showing the map/ camera switching: Animated GIF - Find & Share on GIPHY
See the problem with that is that all 3 of the platforms are a different size entirely.
i try to change the Z axis the capture
Here you say that the Z does not change. So it does change but you’re unsure what to change it to in order to keep the platform in the capture’s view? Is that it?
the problem with that is that all 3
of the platforms are a different size
- use bounds of the platform mesh to create the offset
- or give each platform a unique value
Besides, you shouldn’t be punching raw numbers into anything. We’re doing OOP here. The platform is an actor, it has an anchor above. When we switch to the next platform, pull the data from that actor.
And where do you change the Z of the actor? We can’t see it here; here you’re placing the capture actor at the platform location. Either shift the component within this actor or offset the entire actor.
Or, ensure the Platform vectors already contain the desired Z offset.
Each platform has an anchor and when you switch to it, you place the capture at the location of that scene component.
This way, when you run into situation where math fails because dimensions do not conform to set rules, you can create manual offsets. You can have as many platforms as needed and its the platform itself that stores the data.
I’ve done exactly what you’ve suggested and the capture view still doesn’t change
I’ve done exactly what you’ve
suggested and the capture view still
I suggested 3 different options above…
- vector offsets
- using component as an anchor
I can’t help without understanding what goes wrong. If you’re not sure what’s happening, start printing and observing the values you’re sending to the actor.
The component approach would look something like this:
The above would position the spawned actor at the location of that dragon head billboard.
I’ve done the component approach but I received an error on the ‘set actor location’.
Sorry, but this method of pulling the information out of you is not working for me. If you need help, you need to chip in.
Post your setup, screenshots, description of how it’s supposed to work. And perhaps mention what error… it is.
Yeah sorry for the lack of information, was just in a meeting and due another meeting soon.
This is the Blueprint. The error I’m getting is this.
When I launch the game and switch between locations only the main start location shows.
I’ve linked a vid in this gif: Animated GIF - Find & Share on GIPHY
How are you setting values of those actor references? Creating a variable does little. It’s like creating a string and forgetting to type text. Sure you have a string but it says nothing.
We can’t see the process above and access none simply means that the instance of object you’re pointing at does not exist.
How does the engine know what you mean by Platform1 - you may have 0 or 1000 platforms. The variable is not pointing at anything.
The platform variables are object references and oh I just checked and your right the default value isn’t set. But I can’t set the value/ target in my First person Bp. Where would i be able to set a value?
Depends on the structure of the project, how the Game Mode and Levels work. What’s loaded and what’s spawned dynamically.
If the player is in the Level already and so are the platforms:
- make the variables Instance Editable and:
If the player is spawned dynamically:
- have the Level tell them about the platforms
- the player holds an array ready to be populated:
If you’re using some other structure to organise the project, you’ll need to explain.
Okay so I’ve followed the top image and by moving these billboards on the x and the y axis the capture moves too. But when i move the billboards down the capture doesn’t change.
In the editor viewport or PIE? How are you moving it? How are you updating the position of the capture?
If you’re expecting things to update in the editor, you’ll need to get the Contraction Script involved.
I’m moving the billboards in the player editor and saving current every time.
Based off a project linked in the previous thread; it really works fine. Do recheck your steps:
I’m moving the billboards in the
player editor and saving current every
There’s no reason to save anything. Not sure what that means but if you’re storing something in variables, you might be simply unnecessarily overriding values.
Again, without seeing what you’re doing, it’s impossible to tell what goes wrong.
And it works with the capture actor being a separate entity as well: