Giter Club home page Giter Club logo

melee's People

Contributors

altimortasdk avatar antidote avatar br- avatar camthesaxman avatar celestialamber avatar drgn-drc avatar electronicsarchiver avatar encounter avatar epochflame avatar fluentcoding avatar johnnyurosevic avatar jordan-zilch avatar ka-lua avatar kiwi515 avatar nicolasrmerz avatar psilupan avatar r-burns avatar repiteo avatar revosucks avatar ribbanya avatar rjeli avatar runlava avatar seizefire avatar snuffysasa avatar stephenjayakar avatar thefoxcam avatar tri-wing avatar vetritheretri avatar vinceau avatar wyatt-avilla avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

melee's Issues

ObjUpdate Funcs of HSD Incorrectly Use `enum_t` instead of `unsigned int`

As discussed on Discord, the ObjUpdate functions of various HSD types were changed to have enum_t for the type argument, when it is in fact an unsigned int that uses a list of #define rather than an enum. An example of this is MObjUpdateFunc.

This branch addresses some of that in commits as well as incorrect prototype declarations that were part of CObj, if someone wants to cherry-pick them. master...PsiLupan:melee:cobj-match

Standardize float literal syntax

Normally I'm not picky about how floats are written, and I usually prefer to leave off as much as I can like f32 x = 0;. But since we're trying to match exactly, I think it would be useful to standardize all of our literals to be suffixed with either F or L. I know 0.0 is explicitly a double in C, but having the extra L should make it easier to scan the code.

Some existing literals use lowercase f so I think we should agree on one or the other.

Replace `TODO` comments with GitHub issues

dolphin

gx

GXFifo

GXLight

sysdolphin

baselib

mtx

shadow

melee

ft

fighter

ftbosslib

ftdata

chara/ftIceClimber/fticeclimber2_nana

chara/ftKirby/ftkirby

chara/ftMasterHand/ftMasterHand_2

chara/ftMasterHand/ftMasterHand_8

chara/ftSamus/ftsamus3

gr

ground

mp

mpcoll

pl

player

Match 100% of `grTPeach` and 69.69% of `grTMewtwo`

Progress calculation sometimes experiences regressions

930d31b:

Progress:
    Code sections: 731049 / 3882272 bytes in src (18.830443%)
    Data sections: 182474 / 1223369 bytes in src (14.915696%)
You have 55 of 293 Trophies and completed 7 of 51 Event Matches.
Code bytes to go for next trophy: 10956

b0d2f6a (directly after):

Progress:
    Code sections: 724977 / 3882272 bytes in src (18.674039%)
    Data sections: 182393 / 1223369 bytes in src (14.909075%)
You have 54 of 293 Trophies and completed 7 of 51 Event Matches.
Code bytes to go for next trophy: 3778

Come up with a way to train the source permuter for logically equivalent code

This is the source permuter we usually use for helping us finish decompilations. The idea is that we have C code that is logically equivalent to the solution -- however, there are optimizations that the compiler will do or heuristics to change the output assembly in a way that is hard to guess every time. The permuter just does random operations and hopes the score will go down. I think that this is actually a good use case for ML if we're able to express the problem correctly. Working on expressing the problem -- once we do that, we can train on the corpus of this repo and self-generated variations via the permuter :).

Prune `static` declarations from headers

Ideally also remove "private" module functions from the "public" headers and use __module_name.h for those instead.

In particular at the time of writing:

  • ftpikachu.h
  • ftzelda.h

Match `func_80031640`

https://decomp.me/scratch/5YZak

In cm/cmsnap.s

void func_80031640(HSD_GObj* arg0, s32 arg1) {
    switch (lbl_80453060[0]) {
        case 1:
            func_800122C8(&lbl_80453060[1], 0, 0, 0);
            lbl_80453060[0] = 2;
            return;
        case 2:
        case 3:
        case 4:
            lbl_80453060[0] += 1;
        case 0:
        default:
            return;
    }
}

Port remaining identified/matched symbols from SMB

Support manually including `asm` functions in `calcprogress`

I'm thinking something like

// calcprogress force
asm static void __init_registers(void)
{ // clang-format off
	nofralloc

	lis r1,  _stack_addr@h
	ori r1, r1,  _stack_addr@l
	lis r2, _SDA2_BASE_@h
	ori r2, r2, _SDA2_BASE_@l
	lis r13, _SDA_BASE_@h
	ori r13, r13, _SDA_BASE_@l
	blr
} // clang-format on
// calcprogress restore

Questions about project status

Hi, this is a really great start. I have a couple questions, though.

  1. Is this still being worked on?
  2. Would you accept contributions which just add comments/pseudocode to assembly, or which rename symbols. to make the code more readable?
  3. Is there any consideration for porting parts of the code to C, like UnclePunch has been doing for his own modifications?

Address remaining issues with `MSL/math`

Every function of math has been fully matched and decompiled except for func_803265A8. (which I'll do very soon, unless one of you wants to pick it up for themselves)

The currently linked math.o file is from the asm so this has to be changed as well as soon as func_803265A8 is matched.

  • Match func_803265A8
  • Rename variables to what they do
  • Reformat function bodies/Remove comments
  • Rename functions to what they do
  • Link math.o from "src"

Originally posted by @FluentCoding in #235 (comment)

Standardize member offset comments

The reason it's mixed usage is because of me copy-pasting from structs in FRAY, which I think was done here. It's been something I've tried to cleanup as I actually decompile files themselves.

I was using this style because of Intellisense at the time and changed to match how other projects handle it with /* 0xA */, but we should settle on which needs to be done if that's the case.

Originally posted by @PsiLupan in #556 (comment)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.