MCPcopy Create free account
hub / github.com/BuildCraft/BuildCraft / makeScale

Method makeScale

common/buildcraft/lib/misc/Matrix4i.java:26–34  ·  view source on GitHub ↗
(Vec3i vec)

Source from the content-addressed store, hash-verified

24 }
25
26 public static Matrix4i makeScale(Vec3i vec) {
27 // @formatter:off
28 return new Matrix4i(
29 vec.getX(), 0, 0, 0,
30 0, vec.getY(), 0, 0,
31 0, 0, vec.getZ(), 0,
32 0, 0, 0, 1);
33 // @formatter:on
34 }
35
36 public static Matrix4i makeRotY(int ang) {
37 if (ang % 90 != 0) throw new IllegalArgumentException("You can only have angles in increments of 90 degrees!");

Callers 3

testMakeScaleMethod · 0.95
Matrix4iClass · 0.95
addScaleMethod · 0.95

Calls 3

getXMethod · 0.65
getYMethod · 0.65
getZMethod · 0.45

Tested by 1

testMakeScaleMethod · 0.76