aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ethyl.py8
-rw-r--r--testrlan.py27
-rw-r--r--write-brlan.py17
3 files changed, 36 insertions, 16 deletions
diff --git a/ethyl.py b/ethyl.py
index cdbdd01..2e01409 100644
--- a/ethyl.py
+++ b/ethyl.py
@@ -3,14 +3,14 @@ formats = {
'pane': '''
u8 flags_1 // 8
u8 flags_2 // 9
- u8 alpha // a
+ u8 alpha // a
u8 alpha_2 // b
char name[0x18] // c
float x // 24
float y // 28
float z // 2c
- float pane_unk1 = 0 // 30
- float pane_unk2 = 0 // 34
+ float flip_x = 0 // 30 - note: flip_x = rotate around the x axis, which is a *vertical* flip
+ float flip_y = 0 // 34
float angle // 38
float xmag // 3c
float ymag // 40
@@ -22,7 +22,7 @@ formats = {
u16 len1 // 4c
u16 len2 // 4e
u16 mat_off // 50
- u16 font_idx // 52; into fnl1
+ u16 font_idx // 52 - into fnl1
u8 unk4 // 54
u8 pad[3] = [0, 0, 0]// 55
u32 name_offs // 58
diff --git a/testrlan.py b/testrlan.py
index 70955d8..2abec49 100644
--- a/testrlan.py
+++ b/testrlan.py
@@ -3,14 +3,27 @@
'flags': 1,
'anims': [
('RLPA', 'pic', CAT_COORDS, [
- (COORD_X, [
- (20.0, 0.0, 3.0),
- (40.0, 15.0, 3.0)
+ #(COORD_X, [
+ #(20.0, 0.0, 1.0),
+ #(40.0, 15.0, 1.0)
+ #]),
+ #(COORD_Y, [
+ #(10.0, 0.0, 1.0),
+ #(30.0, 15.0, 1.0)
+ #]),
+ #(COORD_ANGLE, [
+ #(0.0, 0.0, 1.0),
+ #(70.0, 360.0, 1.0),
+ #]),
+ (COORD_XMAG, [
+ (0.0, 0.5, 0.0),
+ (70.0, 0.5, 0.0),
]),
- (COORD_Y, [
- (10.0, 0.0, 3.0),
- (30.0, 15.0, 3.0)
- ])
+ (COORD_YMAG, [
+ (0.0, 3.5, 0.0), # Interpolation is weird. If I specify the same value for the two points and factor = 1, I get a HUGE increase in the middle.
+ (70.0, 0.5, 0.0),
+ ]),
+
]),
('RLVC', 'pic', CAT_COORDS, [
diff --git a/write-brlan.py b/write-brlan.py
index a01f287..e9fa710 100644
--- a/write-brlan.py
+++ b/write-brlan.py
@@ -1,11 +1,18 @@
import sys, struct, re
from ethyl import *
-CAT_COORDS = 0x1000000
-CAT_2_UNK = 0x2000000 # alpha and stuff
-COORD_X = 0
-COORD_Y = 1
-
+CAT_COORDS = 0x1000000
+CAT_2_UNK = 0x2000000 # alpha and stuff
+COORD_X = 0
+COORD_Y = 1
+COORD_Z = 2
+COORD_FLIP_X = 3
+COORD_FLIP_Y = 4
+COORD_ANGLE = 5
+COORD_XMAG = 6
+COORD_YMAG = 7
+COORD_WIDTH = 8
+COORD_HEIGHT = 9
f = open(sys.argv[1], 'r')
data = eval(f.read())
f.close()