#DLL mod help Elden Ring

120 messages · Page 1 of 1 (latest)

slate zenith
#

hello, im quite new to eldenring modding/modding in general and wondering if i can get some help

I've followed a couple guides on smithbox and dlls
and came to the conclusion that the mod i want to build is probably going to work best with a dll

but im not sure how to get started - I have visual studio and the fromsoftware-rs (followed and built the examples) but don't know how to start implementing my own mod
currently stuck at trying to "hook" and find the right function that closes the inventory after an item is used??

drifting onyx
#

Use this for hooking the function and implementing your own desired logic

#

There might be better solutions depending on exactly what you want to do

#

But for the hooking you just need the rva & function signasture of the function you want to hook

slate zenith
#

Ok Cool, I'll give it a shot

slate zenith
#

so i've looked at it for a while and i don't know what to do XD
i have no idea how to hook in the first place

any sort of guides i can follow for this?

still bane
#

You have visual Studio code right?

#

Cuz you said visual Studio

#

Pretty sure visual Studio doesnt have rust support

#

So what you gotta do is find the function youre searching for in ghidra

#

Get the image base offset of that function

#

Then you can hook that address using a dll with me3

#

For hooking you need imagebase offset and the function signature

slate zenith
# still bane You have visual Studio code right?

yes! i have visual studio 2022 community
i was following a guide here: https://phrygian-crayfish-097.notion.site/Elden-Ring-Dll-modding-1-28cf4d242f3f80dd99a6c50ab1d48997 - which did include downloading the fromsoftware-rs (i can build successfully with it)

but it doesn't explain how to do advanced stuff
ill look into ghidra

phrygian-crayfish-097 on Notion

Elden Ring Dll Modding (Getting a seamless coop style setting system in your mod)

still bane
#

the guide tells you to get VS Code though

#

Visual studio is only for the build tools

#

so its required

#

can I ask how much expierience you have in programming in Rust?

slate zenith
#

I have programming experience in other languages (namely ruby), but none in rust
I'm trying to learn as I go

still bane
#

Dont start with hooking and low level stuff

#

I did do that and it wasn't fun

#

Learning about references, ownership, borrowing, lifetimes and all the rust stuff is difficult, especially when you only know about ruby

#

Also youd really benefit if you know the basics of how a computer works

slate zenith
#

are you referring to assembly?

still bane
#

Assembly, stack, heap, etc

#

Not necessarily needed but itd help

slate zenith
#

yeah fair

still bane
#

But trust me when i say that jumping straight into hooking etc is hella frustrating

slate zenith
#

completely trust you on that, i have been trying to understand it for a while now, but im not quite there yet :P

still bane
#

If you want we could do a call and i can try explaining some stuff

#

Tomorrow

slate zenith
#

ok im down for that - depends on the timing as i have work in the morning PST

still bane
#

What timezone?

slate zenith
#

pacific

still bane
#

That's cooked

slate zenith
#

oof

still bane
#

Its 7 hours difference

slate zenith
#

dang that sucks =[

still bane
#

Ig on weekends

slate zenith
#

ok sounds good

still bane
#

Try to get familiar with basic rust

slate zenith
#

ok that'll be my goal this week

still bane
#

Also download vs code

#

(i personally prefer rust rover tho)

slate zenith
#

oh vs code is already in my arsenal :P

alpine edge
# still bane Dont start with hooking and low level stuff

The problem with all of that is....if you want to get into it you don't know where to start.
I tried and got "somewhere" meaning finding a specific function I needed with x64dbg and also looked into Ghidra, learned some assembly and stuff but I didn't get so far as to make a working dll (skill issue as I am not a dev but can only script and barely code).
But you can't even look for tutorials since you don't know what to search for. Do you know some good tutorials?

still bane
#

no the best tutorial is finding someone who explains how the stuff works

#

cuz you could search a random youtube video which shows the code but doesnt fully explain it

#

its hella complicated to do low level rust if you dont even know high level rust

alpine edge
#

Do you mind if I join on the weekend maybe saturday? based in UTC+2 so late evening would work for me

slate zenith
#

i don't mind at all as long as moitt also doesn't mind :D

still bane
#

yeah im okay with that

olive gyro
still bane
#

C++ and rust

#

(rust is better)

olive gyro
#

Okay so I wasn't going crazy, was almost certain fromsoft games themselves are primairly C++ but everytime I ask what to use for modding I get like 6 different languages.

olive gyro
still bane
#

Uhm there are only C++ and Rust

still bane
#

Do you mean dll modding or file modding

olive gyro
olive gyro
still bane
#

File modding can only change the files like params msbs emevd esd etc

#

Dll modding allows literally everything

olive gyro
#

Oh, so you wouldn't even need to use Python and Java and such if you just use Rust or C++?

still bane
#

What kind of modding?

olive gyro
#

Ig lua would be needed for AI but I think thats the only other one.

olive gyro
# still bane What kind of modding?

Was wanting to mod Nightreign, as far as I know things like fully Custom Nightfarers (being able to select them from character select and not from the skins menu) are currently impossible, I would want to work on things like that to make them possible.

still bane
#

There are libraries for file modding in C#, python and Rust

For dll modding theres C++ and Rust(rust is better)

still bane
#

And genuinely really difficult

olive gyro
#

I've heard, I heard from another modder that to do what I have described I would need to sell my soul 😭

still bane
#

That requires reverse engineering, low level rust programming, hooking, knowledge of assembly etc

#

If you aren't a person like chain or axi you wont be able to do it without selling your soul

olive gyro
#

I have a lot of free time, which is the only reason I'm comitted to this, so I think I'll be able to sell my soul.

olive gyro
#

I knew about the reverse engineering part and such, assembly is new to me.

still bane
#

Did you do stuff with cheat engine before

#

Hook functions

#

Dll mod games

olive gyro
#

Are you asking for my experience?

still bane
#

Yeah

#

Cuz if you ain't go no expierience youre basically screwed

olive gyro
#

Very little in terms of modding, currently learning C# and was learning C++.

olive gyro
still bane
#

So ill do a call with jenova and rock lee this week where ill explain some stuff, i think you could join us

#

Im open to explain stuff on call but not in text cuz i wont write a wall of text

olive gyro
#

Okie dokie.

still bane
#

(i enjoy teaching)

#

What timezone you in?

olive gyro
#

EST.

still bane
#

Kk

#

Are you free friday at 17 o clock where you live?

olive gyro
#

Yeah that works.

still bane
#

Learn some rust till then. Thats the most important

olive gyro
#

Okie dokie.

olive gyro
still bane
#

A lot of reasons, rust prevents many errors from happening like race conditions, use after free, etc

#

Rust has a lot of meta-programming features, (tbh idk about C++ macros but i think they suck)

#

I love my rust enums

#

The standard library is much better than C++'s

#

(these are all personal preferences)

still bane
olive gyro
#

I lowkey forgot to learn past what I did and just now started to learn more Rust 😭.

still bane
#

we did but i assumed that you wont come since you didnt accept the friend request

#

if you want i could explain the stuff in a sec to you

olive gyro
#

I had only seen you sent it earlier.

#

Wait did the whole thing alr happen? 😭

still bane
#

yeah

olive gyro
#

Oh, whoops.

still bane
#

i mean i could explain it to you seperatly tho if you want

olive gyro
#

I don't even know what I would want to have explained first.

still bane
#

okay, if you want to have anything explained lemme knwo

olive gyro
still bane
#

basics

olive gyro
#

What would you consider the basics?

still bane
#

references, ownership, functions, structs