new weapon problem


(Paul_88) #1

Hello,
I try to add a new weapon in W:ET. I modified WP_, MOD_, WS_… stuff in source code, created models with tag_weapon and tag_flash, created .weap file, modified human_base.script etc. But in a game I can’t see weapon model from first and third person, only pickup_model. When I changed model in .weap file of existing weapon, I could see that model. Everything else seems to be working. I haven’t any ideas how to solve it.

Thanks for help


(Elite) #2

It is animated and placed in an area that is viewable?


(Paul_88) #3

I used panzerfaust’s animation. I made simple animation and modified weapon.cfg too. Viewable area? How can I do that?


(Elite) #4

What happens when u kill urself ingame? You see the weapon pop out?


(Paul_88) #5

Yes, I see that. The weapon has its textures too.


(PAV) #6

I had the same problem. U must add your weapon into almost all cg_files.c / .h and bg_files.c / .h and g_weapons.c (for bullet) and g_clients.c (to add in first person). U must create your WP_MYWEAP WS_MYWEAP MOD_MYWEAP …

Open all CG_files.c /.h BG_files.c / .h search by example THOMPSON or
STEN or PANZERFAUST and add your weapon like it. U must also, after add your weapon into human_base.script

It is a big work to do it.


(Paul_88) #7

Thaks, but I have already done these things.

I regulary added new weapon like you said before. I did it according to WP_PANZERFAUST, WS_PANZERFAUST, MOD_PANZERFAUST, because my weapon is firing something like rocket. Its working perfectly, doing damage, method of death messages, stats, etc. I have even added new weapon image to limbomenu. :slight_smile: The problem is, that I cannot see the weapon, only shots from it.

I have just found out that the problem is in weapon model and animation file - I replaced model and animation by original m1_garant model and animation and it is worked.

Then could you help me, where is cause for my problem? I imported original model (.md3) into Autodesk VIZ (it is something like light version of 3ds MAX, I think) and merged with my model, original deleted except tag_flash and tag_weapon. Then I exported to .md3 by md3 exporter for MAX 6.


(PAV) #8

If all your code is well, another possibility.
It is your weapon or a weapon taken in another mod ? if it is a weapon taken in another mod
look at the weapon.weap, there is can be lines that ET does not understand, look at in console if there is only one error message like “scaleWeapon unknow” “both {” etc…
if there is only one line which is not understood, you’ll sont see your weapon.

If your weapon.weap is well, the problem is your code. you forgot something.
I add bazooka weapon into my mod, I looked at all the files so that this weapon runs.


(Paul_88) #9

Sorry, my bad. When I was exporting model to .md3, I chose frame 1 instead frame 0 :lol: . That is all, it is working now.

Thanks for help anyway