-1

I'm new to UE and i trying to make my first game (block breaker). My idea in general is:

  1. When starting the game, the pad can`t move.
  2. When clicking, the player chooses the direction in which the ball should be fired.
  3. After the ball is fired, the pad can now move.

My problem is that I can't get the variable 'CanPlayerMove' from BP_Ball in BP_Player. I will be very grateful if you help me, and also accept suggestions for the code, game, etc.

https://prntscr.com/26uwppx

https://prntscr.com/26uwpt1

https://prntscr.com/26uwpv0

https://prntscr.com/26uwpxm

https://prntscr.com/26uwq13

https://prntscr.com/26uwq38

https://prntscr.com/26uwq4a

afreto
  • 13
  • 4

1 Answers1

1

I think the main issue, is -- well I dont ever see you actually spawning a ball. I see some Sphere component that is on your player being moved around.

If your goal is to spawn an Actor (BP_Ball), then reference it later, go for that! Spawn BP_Ball in your 'Spawn Ball' function, and keep that reference around for later.

If your goal is to use a BP_Ball that already exists in the world, then what your looking for is Get Actor of Class

Gedden
  • 11
  • 3