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

3

u/KerbalSpark Dec 16 '22

Man, could you at least give a link to this thing.

1

u/Jazzlike_Archer_3263 Dec 16 '22

3

u/TomatoCo Dec 16 '22

"Sorry, the file you have requested does not exist."

Your link is broken because you posted it from new Reddit, which mangles URLs with underscores.

1

u/Jazzlike_Archer_3263 Dec 16 '22

is it still broken ? not sure how to paste a link that won’t be broken

1

u/[deleted] Dec 16 '22

Post it anywhere else. There are hundreds of sites that let you post text/code.

1

u/TomatoCo Dec 16 '22

Post it from old reddit. Or, don't post it as a link.

1

u/fatboychummy Dec 16 '22
https://drive.google.com/file/d/1Z7dM9GtLtP3CLB9bOSm_ZUrXKd-TtSfY/view?usp=share_link

You will need to copy it manually, but this works fine for me. Just removed the backslashes.

edit: dear god its 3266 lines

1

u/Jazzlike_Archer_3263 Dec 16 '22

yes there is a lot unfornately

2

u/[deleted] Dec 16 '22

here is a lot unfornately

It literally doesn't matter.

0

u/Jazzlike_Archer_3263 Dec 16 '22

sure can one sec

0

u/Jazzlike_Archer_3263 Dec 16 '22

it’s pretty complicated and there is a lot of code

9

u/[deleted] Dec 16 '22

a Modding community for the game

A modding community for a game that uses Lua doesn't have anyone that knows Lua?

Reads a bit like "I'm a part of a community of race car drivers, but we don't know those pedals inside the car are for. Can someone help?"

Anyway... post some code.

1

u/EchoTree0844 Dec 16 '22

Codes been posted.

1

u/Jazzlike_Archer_3263 Dec 16 '22

i mean sure we could edit the texture png file for certain teams to add a skin bar on the sock and move the texture down but it would have to be the same skin tone for every player. Which means whiter players would have darker legs

1

u/EchoTree0844 Dec 16 '22

What Meshes are you looking to remove?

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.