mirror of
https://github.com/pmret/papermario.git
synced 2024-11-09 12:32:38 +01:00
welp
This commit is contained in:
parent
347a654115
commit
6b1367d212
@ -47,7 +47,8 @@ def read_splat(splat_config: str):
|
|||||||
|
|
||||||
for segment in all_segments:
|
for segment in all_segments:
|
||||||
for subdir, path, obj_type, start in segment.get_ld_files():
|
for subdir, path, obj_type, start in segment.get_ld_files():
|
||||||
path = subdir + "/" + path
|
print(path)
|
||||||
|
path = (segment.name if segment.name.endswith("/") else "") + subdir + "/" + path
|
||||||
|
|
||||||
objects.add(path)
|
objects.add(path)
|
||||||
segments[path] = segment
|
segments[path] = segment
|
||||||
|
@ -1,9 +1,9 @@
|
|||||||
#include "common.h"
|
#include "common.h"
|
||||||
#include "battle/battle.h"
|
#include "battle/battle.h"
|
||||||
|
|
||||||
#include "battle/actor/goomba.h"
|
#include "goomba.h"
|
||||||
#include "battle/actor/paragoomba.h"
|
#include "paragoomba.h"
|
||||||
#include "battle/actor/spiked_goomba.h"
|
#include "spiked_goomba.h"
|
||||||
|
|
||||||
#define NAMESPACE b_area_kmr_part_1
|
#define NAMESPACE b_area_kmr_part_1
|
||||||
|
|
||||||
|
@ -1550,10 +1550,10 @@ segments:
|
|||||||
- [0x4313F0, c]
|
- [0x4313F0, c]
|
||||||
- [0x431660, c]
|
- [0x431660, c]
|
||||||
- [0x4318D0, c]
|
- [0x4318D0, c]
|
||||||
- [0x431B80, .data, battle/area_kmr_part_1/battles]
|
- [0x431B80, .data, battles]
|
||||||
- [0x431FB0, .data, battle/actor/goomba]
|
- [0x431FB0, .data, goomba]
|
||||||
- [0x433970, bin]
|
- [0x433970, bin]
|
||||||
- [0x4398A0, .rodata, battle/area_kmr_part_1/battles]
|
- [0x4398A0, .rodata, battles]
|
||||||
- [0x439984, bin]
|
- [0x439984, bin]
|
||||||
- name: battle/area_kmr_part_2/
|
- name: battle/area_kmr_part_2/
|
||||||
type: code
|
type: code
|
||||||
@ -2338,14 +2338,18 @@ segments:
|
|||||||
files:
|
files:
|
||||||
- [0x72E530, c]
|
- [0x72E530, c]
|
||||||
- [0x72EA20, data]
|
- [0x72EA20, data]
|
||||||
- name: battle/item/coconut
|
- name: battle/item/coconut/
|
||||||
type: code
|
type: code
|
||||||
start: 0x72F720
|
start: 0x72F720
|
||||||
vram: 0x802A1000
|
vram: 0x802A1000
|
||||||
overlay: True
|
overlay: True
|
||||||
files:
|
files:
|
||||||
- [0x72F720, c, battle/item/coconut]
|
- [0x72F720, c, aux]
|
||||||
- [0x72F960, .data, battle/item/coconut]
|
- [0x72F960, .data, aux]
|
||||||
|
# - [0x72F960, .data, aux]
|
||||||
|
# - [0x72F960, ci8, coconut, w, h]
|
||||||
|
# - [0x72F960, palette, coconut]
|
||||||
|
# - [0x72F960, .data, coconut]
|
||||||
- name: battle/item/electro_pop
|
- name: battle/item/electro_pop
|
||||||
type: code
|
type: code
|
||||||
start: 0x7305A0
|
start: 0x7305A0
|
||||||
@ -2742,7 +2746,7 @@ segments:
|
|||||||
- [0x7E3700, c]
|
- [0x7E3700, c]
|
||||||
- [0x7E4690, c]
|
- [0x7E4690, c]
|
||||||
- [0x7E4D00, data]
|
- [0x7E4D00, data]
|
||||||
- [0x7E7380, .rodata, world/script_api/7E2AA0]
|
- [0x7E7380, .rodata, 7E2AA0]
|
||||||
- name: world/area_mac/machi/
|
- name: world/area_mac/machi/
|
||||||
type: code
|
type: code
|
||||||
overlay: True
|
overlay: True
|
||||||
@ -3279,13 +3283,13 @@ segments:
|
|||||||
- [0x8C82B0, c]
|
- [0x8C82B0, c]
|
||||||
- [0x8C83A0, c]
|
- [0x8C83A0, c]
|
||||||
- [0x8C85E0, c]
|
- [0x8C85E0, c]
|
||||||
- [0x8C85E0, .data, world/area_kmr/kmr_03/8C7F90]
|
- [0x8C85E0, .data, 8C7F90]
|
||||||
- [0x8C8680, .data, world/area_kmr/kmr_03/8C8140]
|
- [0x8C8680, .data, 8C8140]
|
||||||
- [0x8C88E0, .data, world/area_kmr/kmr_03/8C82B0]
|
- [0x8C88E0, .data, 8C82B0]
|
||||||
# - [0x8C9400, bin]
|
# - [0x8C9400, bin]
|
||||||
- [0x8C9780, .data, world/area_kmr/kmr_03/8C83A0]
|
- [0x8C9780, .data, 8C83A0]
|
||||||
- [0x8CA2D0, .data, world/area_kmr/kmr_03/8C85E0]
|
- [0x8CA2D0, .data, 8C85E0]
|
||||||
- [0x8CA8F0, .rodata, world/area_kmr/kmr_03/8C8140]
|
- [0x8CA8F0, .rodata, 8C8140]
|
||||||
- name: world/area_kmr/kmr_04/
|
- name: world/area_kmr/kmr_04/
|
||||||
type: code
|
type: code
|
||||||
overlay: True
|
overlay: True
|
||||||
@ -3391,10 +3395,10 @@ segments:
|
|||||||
start: 0x8EB360
|
start: 0x8EB360
|
||||||
vram: 0x80240000
|
vram: 0x80240000
|
||||||
files:
|
files:
|
||||||
- [0x8EB360, c, world/area_kmr/kmr_12/header]
|
- [0x8EB360, c, header]
|
||||||
- [0x8EB390, .data, world/area_kmr/kmr_12/header]
|
- [0x8EB390, .data, header]
|
||||||
- [0x8EB420, .data, world/area_kmr/kmr_12/events]
|
- [0x8EB420, .data, events]
|
||||||
- [0x8EBE10, .rodata, world/area_kmr/kmr_12/events]
|
- [0x8EBE10, .rodata, events]
|
||||||
- name: world/area_kmr/kmr_20/
|
- name: world/area_kmr/kmr_20/
|
||||||
type: code
|
type: code
|
||||||
overlay: True
|
overlay: True
|
||||||
@ -3589,9 +3593,9 @@ segments:
|
|||||||
files:
|
files:
|
||||||
- [0x929270, c]
|
- [0x929270, c]
|
||||||
- [0x9292B0, c]
|
- [0x9292B0, c]
|
||||||
- [0x9292D0, .data, world/area_sbk/sbk_00/929270]
|
- [0x9292D0, .data, "929270"]
|
||||||
- [0x929A00, .data, world/area_sbk/sbk_00/9292B0]
|
- [0x929A00, .data, 9292B0]
|
||||||
- [0x929A80, .rodata, world/area_sbk/sbk_00/929270]
|
- [0x929A80, .rodata, "929270"]
|
||||||
- name: world/area_sbk/sbk_01/
|
- name: world/area_sbk/sbk_01/
|
||||||
type: code
|
type: code
|
||||||
overlay: True
|
overlay: True
|
||||||
@ -3600,9 +3604,9 @@ segments:
|
|||||||
files:
|
files:
|
||||||
- [0x929A90, c]
|
- [0x929A90, c]
|
||||||
- [0x929AD0, c]
|
- [0x929AD0, c]
|
||||||
- [0x929AF0, .data, world/area_sbk/sbk_01/929A90]
|
- [0x929AF0, .data, 929A90]
|
||||||
- [0x929E00, .data, world/area_sbk/sbk_01/929AD0]
|
- [0x929E00, .data, 929AD0]
|
||||||
- [0x92A290, .rodata, world/area_sbk/sbk_01/929A90]
|
- [0x92A290, .rodata, 929A90]
|
||||||
- name: world/area_sbk/sbk_02/
|
- name: world/area_sbk/sbk_02/
|
||||||
type: code
|
type: code
|
||||||
overlay: True
|
overlay: True
|
||||||
|
@ -1,4 +1,5 @@
|
|||||||
PyYAML>=5.3.1,<6
|
PyYAML>=5.3.1,<6
|
||||||
pypng==0.0.20
|
pypng==0.0.20
|
||||||
colorama>=0.4.4,<0.5
|
colorama>=0.4.4,<0.5
|
||||||
capstone>=4.0.2,<5
|
python-ranges>=0.1.3,<0.2
|
||||||
|
capstone>=4.0.2,<5
|
@ -46,7 +46,7 @@ def get_funcs_defined_in_c(c_file):
|
|||||||
|
|
||||||
class N64SegCode(N64Segment):
|
class N64SegCode(N64Segment):
|
||||||
def parse_segment_files(self, segment, seg_start, seg_end, seg_name, seg_vram):
|
def parse_segment_files(self, segment, seg_start, seg_end, seg_name, seg_vram):
|
||||||
prefix = seg_name if seg_name.endswith("/") else f"{seg_name}_"
|
prefix = "" if seg_name.endswith("/") else f"{seg_name}_"
|
||||||
|
|
||||||
ret = []
|
ret = []
|
||||||
prev_start = -1
|
prev_start = -1
|
||||||
@ -733,7 +733,11 @@ class N64SegCode(N64Segment):
|
|||||||
|
|
||||||
if file_type == "c":
|
if file_type == "c":
|
||||||
c_path = os.path.join(
|
c_path = os.path.join(
|
||||||
base_path, "src", split_file["name"] + "." + self.get_ext(split_file["subtype"]))
|
base_path,
|
||||||
|
"src",
|
||||||
|
self.name if self.name.endswith("/") else "",
|
||||||
|
split_file["name"] + "." + self.get_ext(split_file["subtype"])
|
||||||
|
)
|
||||||
|
|
||||||
if os.path.exists(c_path):
|
if os.path.exists(c_path):
|
||||||
defined_funcs = get_funcs_defined_in_c(c_path)
|
defined_funcs = get_funcs_defined_in_c(c_path)
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
from pathlib import Path, PurePath
|
from pathlib import Path, PurePath
|
||||||
from util import log
|
from util import log
|
||||||
|
import os
|
||||||
|
|
||||||
default_subalign = 16
|
default_subalign = 16
|
||||||
|
|
||||||
@ -129,7 +130,7 @@ class Segment:
|
|||||||
for subdir, path, obj_type, start in self.get_ld_files():
|
for subdir, path, obj_type, start in self.get_ld_files():
|
||||||
# Hack for non-0x10 alignment
|
# Hack for non-0x10 alignment
|
||||||
if start % 0x10 != 0 and i != 0:
|
if start % 0x10 != 0 and i != 0:
|
||||||
tmp_sect_name = path.replace(".", "_")
|
tmp_sect_name = os.path.join(subdir, path).replace(".", "_")
|
||||||
tmp_sect_name = tmp_sect_name.replace("/", "_")
|
tmp_sect_name = tmp_sect_name.replace("/", "_")
|
||||||
tmp_vram = start - self.rom_start + self.vram_start
|
tmp_vram = start - self.rom_start + self.vram_start
|
||||||
s += (
|
s += (
|
||||||
|
Loading…
Reference in New Issue
Block a user