Spawning blueprint does not spawn anything (UE4) - unreal-engine4

Here's a problem: my goal is to have a ball game with obstacles. I made two obstacles (cubes with triggers) and the spawner code does not spawn them - nothing at all. It does compile without errors, but just does not work. These blueprints are part of the track class (the track the ball is on). Here is the code: (obst amount = 7 - the code before it works fine - its linked to event tick)
Here are the obstacles: (no code in them)
Here is the track:
I'm using Unreal Engine 4.26.2

If it is showing up in the outliner, but you don't see it here's what I would try.
First, unplug your X and Y location. Manually input something you know is right in front of the player.
If you can see it after that, start printing the the coordinates of the spawn location. If those look right and you can't see it still, try spawning a regular cube instead. If you could see the cube but not your obstacle, then I'd check the obstacle BP. In that case it's likely either the scale of the mesh component or it's set to be hidden in game.
Sorry I know this isn't a definitive answer, but I don't have enough reputation to comment instead.

Related

Player character falls through the floor when respawned

I am following Unreal's tutorial titled Twin Stick Shooter with Blueprint. I am on the step called Respawning the Hero. I've done all of the instructions for that step, but when my player is respawned, they fall through the floor. I am using Unreal Engine 4.26.2 which is a different version than the tutorial uses.
In my game mode, I've tried all available settings of Collision Handling Override within Spawn Actor from Class. In the Class Defaults of my player, I've tried all options for Spawn Collision Handling Method. I've made sure that my PlayerStart is above the floor. None of the solutions I've found by searching have applied to my issue, as far as I can tell.
Thanks!
Within TwinStick Mode
Within HeroCharacter
Within HeroCharacter
Your HeroCharacter spawn location is not set. and thus the location is (0,0,0).
Connect output execution pin from Set Game Mode node to the Set Player Spawn Transform node.

Flutter Flame game - animation speed (update duration)

for those who are familiar with using Flame in Flutter for game development, I'm wondering if you can just advise me whether I'm on the right track, or not - because I'm not sure if what I'm seeing in my testing is what I expected. I started out with Flame because I thought it seemed like a relatively simple way to make the basic game that I'm aiming to make.
I'm making a basic game where there are four boundaries defined on each edge of the screen, and a ball will bounce around the four boundaries. The boundaries are defined as widgets (because I want to control the properties of each - sometimes they'll be "electrified", meaning the ball shouldn't collide with them). And the ball is a widget as well, of course. I've got some basic code done where I can drag a line from the ball to indicate the direction that I want to start bouncing, and then the ball will bounce around the boundaries (just using basic angle of incidence = angle of reflection to determine the direction of movement).
The code to do the movement is in the "update" method of the ball widget - however, what I'm finding is that the time between updates is somewhere around 200-300 milliseconds, so if I want to show the ball moving at any kind of pace, it has to jump a good number of pixels at each "update" tick - and thus the movement looks "jerky".
Am I doing this the right way? Is there a different (better) approach that will make the movement appear smoother? Or, I'm wondering whether the duration of the "update" ticks is a result of running the code via debug in an Android emulator? (I'm using Android Studio for the emulation, and Visual Studio Code to build the project). I know I don't have actual code here in the question, because essentially I don't have an issue with my code not running - I would just like to understand if that duration of "update" ticks is "normal", and if the resulting "jerky" animation is just to be expected - or do I need to look at a different approach? Thanks in advance!
You should preferably not be using widgets for moving game parts, you should be using Flame components. So you could have for example 4 SpriteComponents as the walls and then the ball as another SpriteComponent and then you can use the collision detection system to act upon when the ball touches one of the walls.
https://docs.flame-engine.org/main/collision_detection.html

How to make an object bend in the opposite direction as it moves into Unity

I need to move a 3D object like in the "Run sausage" game.
https://www.youtube.com/watch?v=CQa5PUlSfwk
There, as the character runs forward, its body kind of bends backwards, in the direction opposite to the movement.
In particular I do a simulation of a tornado in Unity, but when I want to go forward to the upper part of the tornado moved back, and after 1 second reaches the lower part ("legs")
Any suggestions would help me. Thank you
The movement like in the Sausage Run game can be achieved easily by using animator controller specifically Blend Tree. Watch this tutorial is you are not already familiar with these
https://www.youtube.com/watch?v=E-zQw4GabKw

Animation not working on an instantiated prefab (weapon)

So i'm working on this project and i'm using it to finally learn how to animate in 3D (taking a small break from coding hehe)
So here i am faced with a problem and i have no idea what i did wrong. First let me explain how everything works.
So the Animator is attached to the player, and the player obviously has a structure of legs arms...etc
everything inside the player is being animated by this animator.
So i have a weapon (a wooden sword) that has it's pivot attached to it's bottom (in case it helps to know)
i'm animating it from that pivot point, which happens to be the parent to which the sword model is a child to.
When i hit the V key the weapon gets instantiated in the player's hand (which is an empty gameobject) and when i press the F key the player attack and activates a trigger in the animation that starts the attack animation.
But the animation is not working properly. more precisely the key frames of the weapon are not being player(as you can see in the video all the rotation axes give the coordinates of 0 0 0 throughout all the animation.
But, ...and this is where the strange things start!... when i manually go through each second to play the animation and see what's happening, you can see that those coordinates start to change and it shows the animation exactly as it's supposed to be. then when i switch back to idle state so that i can start moving around the player normally. when i hit the F key to attack the correct animation is player and no problem happens... Magic? i don't think so... :p
what do you think? what could be causing this problem.
Who's up to solve my riddle :cool:
Seriously guys what's going on here, i need help.o_O
Thank you all ;)
The Video : HERE
In general: You are using an ALPHA version 2019.3.0a4 ... in short don't.
As any alpha version it is like to have some bugs .. especially since you are not even using the latest instance of the alpha which afaik would be 2019.3.0a12!
2019.3.0b1 is actually even already in BETA state a lot of former bugs should be fixed there - but it is still a beta release meaning it is not ready for production.
So in general don't even use the beta. Rather stick to the latest stable release version which would now be 2019.2.3f1
There is not directly listed one relating to the animator not finding a certain object at first and then not animating it .. but as said alpha version are likely to have bugs. Also since it is an instantiated prefab the original instance will be gone .. then by name it gets re-assigned by the animator so the main issue might be that you instantiate it in the first place instead of just having it already from the beginning.
You should consider only using the parent/pivot object of that sword and not animate the sword itself at all. Simply spawn it as a child of the animated pivot and you should be fine,

Path finding on a 2d plataformer game. Making enemies jump

I am working 2D Platform running game and I am stuck at this issue, i cant figure it out how to make my enemies jump through platforms as they follow the player. I used A* path finding with a Grid graph for my flying enemy and it works just fine. But with the ground troops i don't know what to do. Any recommendations where to start and what to study? Thanks in advance
Place a Trigger (Collider) attached with the Platform at the point where you want your enemy to Act (Jump in your case). and Attach a script to your Enemy to Handle its actions whenever it enters that trigger. you can make it Jump/Fly or whatever you want to. Thumb up if its helpful :)