Author Topic: String/Name for new weapon not showing  (Read 1165 times)

0 Members and 1 Guest are viewing this topic.

Offline tisi

  • 21
String/Name for new weapon not showing
Hello

I was put off by the existence of the clan srm 6 without a corrosponding is srm 6 (even though is srm 6 ammo already exists!), so I tried to bring it into the game.
After some tinkering I came up with this line for the compbas.csv

Code: [Select]
127,MissileWeapon,SRM 6,2,5,3,3,2.5,241,2416,short,Yes,Yes,Yes,Yes,Yes,Yes,Yes,Yes,SRM,0,8,224,MCL_MC_clanSRM6Pack.tga,MCL_MC_clanSRM6,32127,34127,1,1,1,150
So far so good, the weapon works, it can be bought and used in the mechlab, it even works ingame.

The only problem? It shows up on a mech in a mission as "undefined" (followed by the proper ammo amount left). I tried to edit the corrosponding string 32127 in mc2res.dll (read somewhere on this forum about implementing new mechs/mechwarriors and about a DescIndex linking to that file), but it still shows as "undefined". Is there another place I need to edit a string for make it show up as "SRM 6 Pack"?

Best Regards

P.S.: Before my edit #127 in compbas.csv looked like this:

Code: [Select]
127,undefined,undefined,0,na,na,0,na,0,0,0,0,0,0,0,0,0,0,0,na,0,0,0,0,0,32129,34129,,,,

 

Offline magic

  • Moderator
  • 211
Re: String/Name for new weapon not showing
You did OK in the csv file.

As for the undefined you need to change data value in the project file in 32127 position (Type SRM6 instead of Undefined - resource.h or something) then generate new mc2res.dll.

You can also use some hex editor to change mc2res.dll but you cant change the string length. You can only retype over undefined, exactly the same number of characters including space.

 

Offline zzc

  • 26
Re: String/Name for new weapon not showing
There are actually 4 values to edit in the mc2res.dll for each item.

Here's what I noted after adding several crazy components;

String Index(start32000(shortname-start33000)),Mechlipidia String(start34000(shortinfo-start46000))

Use resource hacker to easily edit dll files, you can change the string length with that, better than hex editor.