Skip to content

Commit 0ed5f2f

Browse files
committed
math.py - ColorRGBA.rgba wrap mult in int
1 parent d721587 commit 0ed5f2f

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

UnityPy/classes/math.py

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,10 @@ def __new__(
105105
@property
106106
def rgba(self) -> int:
107107
return (
108-
self.r * 255 << 24 | self.g * 255 << 16 | self.b * 255 << 8 | self.a * 255
108+
int(self.r * 255) << 24
109+
| int(self.g * 255) << 16
110+
| int(self.b * 255) << 8
111+
| int(self.a * 255)
109112
)
110113

111114
@rgba.setter

0 commit comments

Comments
 (0)