Add a complete new weapon to a team -1 reply

Please wait...

Guest

I didn't make it!

0 XP

 
#1 7 years ago

ยด Hi everyone,

this is my 1st post (lol^^) cuz I'm interested in modding since the last day. However, my questions is how I add a complete new weapon to e.g. the german team. I already read the thread about adding lee enfield to the american team and trying to manage it using these methods, I wanted to add a new shotgun (with other settings) to the axis side.

As everybody know, axis have 6 weapons (mp40, kar, g43, scope, shotgun,mp44). Now I want to add a 7th slot for another shotgun (shotgun2), but the problem is that I want to have it available via "openscriptmenu weapon_german shotgun2_mp" but I do not want it to show on the menu. With other words, its only able to reach the weapon over the openscriptmenu command.

What I've done so far:

- created a new shotgun2 file with cod2 weapon editor and put it into iw13.iwd/weapons/mp/ - opened the _weapon.gsc and added the "shotgun2_mp" to precaching - opened scriptmenu.menu for axis and added

itemDef { name "button_shotgun[COLOR=Red]2[/COLOR]" visible 1 rect 0 0 128 24 origin ORIGIN_CHOICE[COLOR=Red]7[/COLOR] forecolor GLOBAL_UNFOCUSED_COLOR type ITEM_TYPE_BUTTON text "[COLOR=Red]@7. Shotgun2[/COLOR]" textfont UI_FONT_NORMAL textscale GLOBAL_TEXT_SIZE textstyle ITEM_TEXTSTYLE_SHADOWED textaligny 20 dvartest "ui_allow_shotgun[COLOR=Red]2[/COLOR]" showDvar { "1" } action { play "mouse_click"; scriptMenuResponse "shotgun[COLOR=Red]2[/COLOR]_mp"; } onFocus { hide kar98k_info; hide g43_info; hide mp40_info; hide enfield_info; hide kar98ksniper_info; hide mp44_info; play "mouse_over"; show shotgun_info; show weapon_propertiestext; } } itemDef { name "button_shotgun[COLOR=Red]2[/COLOR]" visible 1 rect 0 0 128 24 origin ORIGIN_CHOICE[COLOR=Red]7[/COLOR] forecolor GLOBAL_DISABLED_COLOR type ITEM_TYPE_BUTTON text "[COLOR=Red]@7. Shotgun2[/COLOR]" textfont UI_FONT_NORMAL textscale GLOBAL_TEXT_SIZE textstyle ITEM_TEXTSTYLE_SHADOWED textaligny 20 dvartest "ui_allow_shotgun[COLOR=Red]2[/COLOR]" showDvar { "2" } onFocus { hide kar98k_info; hide g43_info; hide mp40_info; hide kar98ksniper_info; hide mp44_info; play "mouse_over"; show shotgun_info; show weapon_propertiestext; } }

Nothing worked so far, any ideas?

Thanks in advance