Giter Club home page Giter Club logo

Comments (8)

rlynch-ironnet avatar rlynch-ironnet commented on August 16, 2024

Some sort of initialize function would also need to exist, so as to feed in the Scanner.Module.BaseAddress ptr, so the updated offsets can be calculated.

from ffxivclientstructs.

daemitus avatar daemitus commented on August 16, 2024

ffs. how many times am i going to login and do stuff with my work account. you'd think i'd have noticed.

from ffxivclientstructs.

aers avatar aers commented on August 16, 2024

Can delete it and repost if you want.

from ffxivclientstructs.

aers avatar aers commented on August 16, 2024

Anyway.

vtbl addresses dont need to be in the code. You just read them from the current object. This allows polymorphism to actually work.

Function signatures I haven't really thought about. One option is to store them in a header file as actual C++ function signatures then use something like CppSharp's parser to read them during codegen.

It should be possible to use a static initializer to store the game's base address when the dll loads, unless I'm mistaken.

from ffxivclientstructs.

rlynch-ironnet avatar rlynch-ironnet commented on August 16, 2024

C#9 has [ModuleInitializer]
Prior to that, Fody has ModuleInit
Or the option of a static constructor on something potentially.

from ffxivclientstructs.

daemitus avatar daemitus commented on August 16, 2024

Been thinking, generating and stuffing offsets in code is handy dandy, but requires rebuilding every patch. What if it gets generated, but packs data.yml with the dll. If out of date (since ffxiv.ver is in the file now) reach out to github, pull down a new data, if good, update the offsets. Won't be able to generate anything that's new or not, but at the very least it'll have good offsets.

from ffxivclientstructs.

daemitus avatar daemitus commented on August 16, 2024

proof of concept: https://github.com/daemitus/FFXIVClientStructs/tree/sourcegen
Pretty sure it forces the TFM to netstandard2.0, which should? leave us compatible with net472. Haven't tried loading it into XL though. I can't find it again, but I swear some Msft doc said netstandard2.0 was on par with net45.

from ffxivclientstructs.

daemitus avatar daemitus commented on August 16, 2024

re: Linking original structs to generated data.

  • 1: some stupid getter function on a static class. boo
  • 2: extension class adding a getter to each struct. maybe
  • 3: weave them into each class with something (fody?). My favorite idea, requires adding another thing onto the dependency stack though. Source generators are purely additive, afaik it wouldn't be possible to add to an existing object this way.

from ffxivclientstructs.

Related Issues (20)

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.