BootCamp week 2 Flashcards
1
Q
How to repeatedly call an Method?
A
InvokeRepeating(“MethodName”, how long to wait to start, how often to repeat)
2
Q
How to use Force on an object?
A
Rigidbody Add Force (Variable for vector2)
3
Q
How to use 3D audio in 2D space?
A
3D audio set to Linear Rolloff, Max Distance to around 10, Spatial blend to 1 to enable 3D Audio, Remove Audio from camera and add it to Player.
4
Q
How to swap Enemy Direction?
A
Create a Variable and Multiply and Equal it with a Vector2(-1,1)
5
Q
How to check to flip sprite using Enemy Direction Variable?
A
SpriteRenderer.FlipX = Variable.X > 0
6
Q
How to use Mathf.Lerp?
A
Var variable = MathF.lerp(Variable to use, desired variable, percentage)