N00b question: How to make animated weapon changing

EDIT: Just did it with PYTHON!!!

I would like something to change weapons with an animation, not a simple replace mesh, but how do I do so that, when I press a key, the current weapon lowers and the weapon assigned to the key I pressed appears?

make all of the weapon meshes a child of an armature, and make the armature animate, or give the main mesh that always gets replaced with weapons a falling and raising ipo.

Yes, but I would need 81 animations for 9 weapons… But with an ipo it could be a visual effect, that it lowers in one frame and raises in three, in a total of 25… I’ll play around with that. Thanks anyway.

Now even Replace Mesh doesn’t work for me… The model doesn’t display property. Both object centers are on the handle,

why dont you upload it and ill see if i can clean it up and tell you some stuff 'cause it just too hard. id need so much info from you from the forum to help u it would be really frustrating

Alright. Here it is. The model is on the 2nd layer in the “Caracas” scene.
Thank you.

k ill get back to u thx

EDIT: hey yeah, this communism topic game thingo i remember… coolness!

ill go along in this thread and post things i want to tell u about eh… k awesome…?

1st things 1st, just in case u didnt know, the debug properties shown option turned on sets u back about 5 frames per second, especially with the amount that uve got running, so dont be fooled by the frame rate when ur editing.

2ndly, the mouse script that ur using (and their are a few repeated unneccesary scripts that uve got in the blend file, why do ya?) doesnt stop the camera from rotating after uve finished moving the mouse. isnt that annoying!?! so, do this, so it TURNS OFF when the mouse isnt being moved.

if mouse.isPositive():
    if own.x >= -0.9 and own.x <= 0.9:
        leftRight.setDRot( 0.0, 0.0, rotLeftRight, False)   
        upDown.setDRot( rotUpDown, 0.0, 0.0, True)
        GameLogic.addActiveActuator(leftRight, True)
        GameLogic.addActiveActuator(upDown, True)
        GameLogic.addActiveActuator(leftRight, 0)
        GameLogic.addActiveActuator(upDown, 0)
    GameLogic.addActiveActuator(leftRight, 0)
    GameLogic.addActiveActuator(upDown, 0)

lastly for now, the weapon is waaaaaay too high poly… max 250 or so for a weapon dude! instead of having that whole corrugated handle grip section, you could and should have that as a 12 or so vert cylinder.

ill get back to u with more stuff to tell. so far the game looks really cool!

by god man, if the chuze script is the walking script, then there is alot of cleaning to do!

EDIT, also, the empty below the box is the “player.” it should be the other way around, and when you’ve copied the logic bricks from the empty to the box (which u should call “PLAYER”) u should delete the empty

also, the environment is like a bajillion zillion verts…

i decimated it a few times

ya know, i will re-post the file when im done “cleansing” it. I ll do my best for u.
anyway soz for all of the posts just trying my best to help :slight_smile:

also, make the camera settings this:

start: 0.10
end: 500.00

now u can see your machine gun

Thank you.
I had a gun like 1000 polys before. I remodeled it.
And I was using a template. But that was some time ago. So I had less experience.
The “smrtjed” or whatever script, I don’t need it. It’s an AI script that the chickens don’t use.
Of logic bricks or python, which takes less fps?
If the answer is logic bricks, we would just delete the walking script, and add controllers and actuators.

If replace mesh isn’t working, make sure you put the name of the MESH, not the OBJECT in the logic brick slot/thingy.

Yeah, I did. But the mesh didn’t appear well. But, can an object can have multiple meshes?

The weapons I want to use:
Better a Desert Eagle
Shotgun ( I have the model now )
Remington 700 Sniper Rifle with functional scope
Rocket Launcher
M249 SAW Machinegun
Laser gun ( The one that the rooster soldiers use )
Inciendiary, Frag and Smoke grenades in a single button.

I need blueprints for all of these. Althrought I would prefer the Tango 51 ( rather than the Remington 700 ), I searched for blueprints for modeling but I didn’t find them.

Of course! you can just link objects to another scene, so that when it changes, the other in the other scene also does! I’ll start makin’ new levels, with better AI.

How low poly can I make an M4a1…
There are games that run models with 50000 faces smoothly! Such as Morrowind! I used to mod it.

Now I understand why walking scripts are requiered. The cube object is a mesh without verticles, edges or faces! The walking script it’s so the player doesn’t fall to the infinity.

Nope, the problem is not in the camera.