mirror of
https://github.com/Thorfusion/Mekanism-Community-Edition.git
synced 2026-11-21 20:42:17 +00:00
Work on making flamethrowers work nice. Still need to get first person neutral particles down.
This commit is contained in:
1 parent
6fbfd22583
commit
1a458834a8
3 files changed
+81
-3
No files matched your search
@@ -131,6 +131,22 @@ public class Pos3D
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
public Pos3D rotatePitch(double pitch)
|
||||
{
|
||||
double pitchRadians = Math.toRadians(pitch);
|
||||
|
||||
double y = yPos;
|
||||
double z = zPos;
|
||||
|
||||
if(pitch != 0)
|
||||
{
|
||||
yPos = y * Math.cos(pitchRadians) - z * Math.sin(pitchRadians);
|
||||
zPos = z * Math.cos(pitchRadians) + y * Math.sin(pitchRadians);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
/**
|
||||
* Scales this Pos3D by the defined x, y, an z values.
|
||||
|
||||
Reference in new issue
Block a user