What do you want to save?
Add Code snippet
New code examples
-
Other 2022-03-17 00:45:13
how to make an object move towards another in unity
/// <summary> /// Move 2D sprite towards target /// </summary> /// <param name="target"></param> /// <param name="movementSpeed"></param> private void Move(Vector3 target, float movementSpeed) { ... Add solution -
C# 2022-03-16 13:35:27
The type or namespace name 'Target' could not be found (are you missing a using directive or an assembly reference?)
} public float damage = 100f; // Update is called once per frame void Update () { if (Input.GetButtonDown("Fire1")) { shoot(); } } void shoot() { RaycastHit hit; if (Physics.Raycast(transform.position,transform.forwa... Add solution -
Go 2022-03-08 11:10:05
roblox how to make something go in an elliptical orbit
local center = workspace.Earth; local moon = script.Parent; local ORBIT_TIME = 2; local RADIUS = 10; local ECLIPSE = 0.5 local ROTATION = CFrame.Angles(0,0,0); local sin, cos = math.sin, math.cos; local ROTSPEED = math.pi*2/ORBIT_TIME; ECLIPSE = ECLIPS... Add solution -
C# 2022-03-04 05:20:02
how to move player with finger touch in unity
if (Input.touchCount > 0) { Touch touch = Input.GetTouch(0); // get first touch since touch count is greater than zero if (touch.phase == TouchPhase.Stationary || touch.phase == TouchPhase.Moved) { // get the touch position ... Add solution