Game Development Community

Weapon on Vehicle

by fiveforty · in Torque Game Engine · 10/27/2005 (10:22 am) · 4 replies

Does anybody know how to implament this www.codesampler.com/source/trq_weapons.zip onto a vehicle. I've used it on a FPS and really liked it, and want to use it on a vehicle if possible


To make it work in FPS you have to enter it in the player.cs

function PlayerShape::onAdd(%this,%obj)
{
    parent::onAdd( %this, %obj );
    %obj.mountImage( RocketLauncherImage, 0 );
    %obj.setImageAmmo( 0, 1 );
}

I've tried doing the same in the car.cs but to no avail
can someone help me??

#1
10/27/2005 (11:40 am)
Have you looked at this:
http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=2601
#2
10/27/2005 (3:34 pm)
Yea I've tried using it but not had much luck in getting the weapons to fire
guess I'll just have to keep hammering away until I can get it to work
#3
10/27/2005 (4:43 pm)
Does the car a have a mount point for the weapon?
#4
10/28/2005 (5:33 am)
Yeap I've got a mount point on the vehicle for the weapon