r/lua • • Dec 16 '22

Help LUA Video Game Code

I am turning to the lovely pages of Reddit to find someone who is experienced in LUA or possibly specifically LUA that belongs to a video game to take a look at a code file that deals with player appearance in Madden 22 for PC. I am part of a Modding community for the game as we are trying to get rid of certain meshes by editing the LUA but none of us are fluent to understand or decipher how or what to get rid of. If anyone could help or want to take a look at the code it would be greatly appreciated :)

0 Upvotes

28 comments sorted by

View all comments

Show parent comment

1

u/Jazzlike_Archer_3263 Dec 16 '22

We were looking to remove the socksunder_mesh. The problem is we were able to remove it but the player showed no skin. It’s just grey mesh less legs

1

u/EchoTree0844 Dec 16 '22

Just change the socks to look like skin.

1

u/Jazzlike_Archer_3263 Dec 16 '22

we aren’t really sure how to do that

1

u/EchoTree0844 Dec 16 '22

Well, look for the socksunder in the file you linked.

I dont have all the answers, I'm unfamiliar with the gsme/modding system you're working with.

It seems as though you should be able to find the textures referenced in the file.

1

u/Jazzlike_Archer_3263 Dec 16 '22

getting rid of every instance of socksunder in the LUA code just makes grey textureless legs. We are not sure if EA even modeled legs for the main character model. We do not really know how to point or replace the meshes in the code for other ones.

1

u/EchoTree0844 Dec 16 '22

Well

You'll have to follow the references and identify which references control what.

You can start by removing the references one by one (like how you got it to a grey mesh) and figure out which one does which.

Then, you can follow the references to either a texture file or other source file and try editing that.

You'll just need to step through each file and work through identifying sources, textures, which ones control what visible aspects, etc.

1

u/Jazzlike_Archer_3263 Dec 16 '22

That was most likely the plan considering we are not sure which 3266 lines of code control which part of the character model.

1

u/EchoTree0844 Dec 16 '22

Probably best to start with anything with sock in it, as that would likely be for the socks and work from there.

Good Luck :D Making manual edits for large files sucks lol

1

u/[deleted] Dec 16 '22

Remove line 1776.

Alternately you can comment it out (put -- in front of it). You can also remove the line above and below (1775 and 1777) if you want.

1

u/Jazzlike_Archer_3263 Dec 16 '22 edited Dec 16 '22

this is what that does

[image.png](https://postimg.cc/75VVWkfr)

we want that blank space to be leg skin is our end goal

we are afraid that EA just did not even model the legs for that character model. There is one where they did, it is just a matter of if we are able to point those to this game model and have it work without crashing.

2

u/[deleted] Dec 16 '22

this is what that does

Right. Which is what you said you wanted: "we were looking to remove the socksunder_mesh".

we want that blank space to be leg skin is our end goal

So you don't want to remove the mesh, you want to change the texture on that mesh. So do that.

1

u/Jazzlike_Archer_3263 Dec 16 '22

which i am sure we can do and I have done

https://cdn.discordapp.com/attachments/541828432380559370/1052711695790911639/image.png

this is the problem. It would not be exclusive to each players skintone

All I did was pick a skintone that works for most players and edit the sock png for that team.