mirror of
https://github.com/processing/processing4.git
synced 2026-06-16 04:26:26 +02:00
oh right, this is Java
This commit is contained in:
@@ -870,8 +870,8 @@ public class PVector implements Serializable {
|
||||
|
||||
public PVector setHeading(float angle) {
|
||||
float m = mag();
|
||||
x = m * Math.cos(a);
|
||||
y = m * Math.sin(a);
|
||||
x = (float) (m * Math.cos(angle));
|
||||
y = (float) (m * Math.sin(angle));
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user