Author Topic: Weapon wont show :(  (Read 2128 times)

Ok i need help with 2 types of animation:
Weapon Animation
Bot Animation

I need to know the joints.
I need to know how to export the animation.
I need to know how to add animations in the script.


Most of my Add-ons have been delayed due to the fact that i cant animate.


Now that that is fixed.


I now need help with my weapon i scripted it, animated it, tested it.
But when i tested it it did show up with all the weapons.

I know i enabled it.
I need to find this out.
« Last Edit: December 18, 2009, 06:40:36 PM by aware14 »

Damnit, now I need help with this. D:

My 4th quick tip video discusses this.
http://www.youtube.com/watch?v=Prait-PfOOs

It covers simple animation using two blocks.
I made this a while ago.

I need to redo those, It hurts my soul watching them again.

My 4th quick tip video discusses this.
http://www.youtube.com/watch?v=Prait-PfOOs

It covers simple animation using two blocks.
I made this a while ago.

I need to redo those, It hurts my soul watching them again.

thanks but 1 question. do i export the animation seperate?

thanks but 1 question. do i export the animation seperate?
If it's a weapon.
You'll want the animation with the dts.

If it's a player model.
Then you'll want to work with dsqs.
(Which are hard to understand at first)

I suggest working with weapon animation.

If it's a weapon.
You'll want the animation with the dts.

If it's a player model.
Then you'll want to work with dsqs.
(Which are hard to understand at first)

I suggest working with weapon animation.

Thanks!  :cookieMonster:

Ung...
It wont show on the weapon list now...

« Last Edit: December 18, 2009, 06:54:27 PM by Plasmus »


This is a help topic.
Not for trolls.
Who said i was a troll?




script?
No! The code for your models! Of course your script!


[/fake rage]

No! The code for your models! Of course your script!


[/fake rage]

I was just checking.

Code: [Select]
//BambooSword.cs



//projectile
AddDamageType("BambooSword",   '<bitmap:add-ons/Weapon_BambooSword/CI_BambooSword> %1',    '%2 <bitmap:add-ons/Weapon_BambooSword/CI_BambooSword> %1',0.75,1);
datablock ProjectileData(BambooSwordProjectile)
{
   directDamage        = 35;
   directDamageType  = $DamageType::BambooSword;
   radiusDamageType  = $DamageType::BambooSword;
   explosion           = SwordExplosion;
   //particleEmitter     = as;

   muzzleVelocity      = 50;
   velInheritFactor    = 1;

   armingDelay         = 0;
   lifetime            = 150;
   fadeDelay           = 70;
   bounceElasticity    = 0;
   bounceFriction      = 0;
   isBallistic         = false;
   gravityMod = 0.0;

   hasLight    = false;
   lightRadius = 3.0;
   lightColor  = "0 0 0.5";

   uiName = "BambooSword Slice";
};


//////////
// item //
//////////
datablock ItemData(BambooSwordItem)
{
category = "Weapon";  // Mission editor category
className = "Weapon"; // For inventory system

// Basic Item Properties
shapeFile = "./BambooSword.dts";
mass = 1;
density = 0.2;
elasticity = 0.2;
friction = 0.6;
emap = true;

//gui stuff
uiName = "BambooSword Sword";
iconName = "./icon_BambooSword";
doColorShift = true;
colorShiftColor = "0.471 0.471 0.471 1.000";

// Dynamic properties defined by the scripts
image = BambooSwordImage;
canDrop = true;
};

////////////////
//weapon image//
////////////////
datablock ShapeBaseImageData(BambooSwordImage)
{
   // Basic Item properties
   shapeFile = "./BambooSword.dts";
   emap = true;

   // Specify mount point & offset for 3rd person, and eye offset
   // for first person rendering.
   mountPoint = 0;
   offset = "0 0 0";

   // When firing from a point offset from the eye, muzzle correction
   // will adjust the muzzle vector to point to the eye LOS point.
   // Since this weapon doesn't actually fire from the muzzle point,
   // we need to turn this off. 
   correctMuzzleVector = false;

   eyeOffset = "0.0 1.7 -0.25";

   // Add the WeaponImage namespace as a parent, WeaponImage namespace
   // provides some hooks into the inventory system.
   className = "WeaponImage";

   // Projectile && Ammo.
   item = BambooSwordItem;
   ammo = " ";
   projectile = BambooSwordProjectile;
   projectileType = Projectile;

   //melee particles shoot from eye node for consistancy
   melee = true;
   doRetraction = false;
   //raise your arm up or not
   armReady = true;

   //casing = " ";
   doColorShift = true;
   colorShiftColor = "0.471 0.471 0.471 1.000";

   // Images have a state system which controls how the animations
   // are run, which sounds are played, script callbacks, etc. This
   // state system is downloaded to the client so that clients can
   // predict state changes and animate accordingly.  The following
   // system supports basic ready->fire->reload transitions as
   // well as a no-ammo->dryfire idle state.

   // Initial start up state
stateName[0]                     = "Activate";
stateTimeoutValue[0]             = 0.5;
stateTransitionOnTimeout[0]      = "Ready";
stateSound[0]                    = SwordDrawSound;

stateName[1]                     = "Ready";
stateTransitionOnTriggerDown[1]  = "PreFire";
stateAllowImageChange[1]         = true;

stateName[2] = "PreFire";
stateScript[2]                  = "onPreFire";
stateAllowImageChange[2]        = false;
stateTimeoutValue[2]            = 0.3;
stateTransitionOnTimeout[2]     = "Fire";

stateName[3]                    = "Fire";
stateTransitionOnTimeout[3]     = "CheckFire";
stateTimeoutValue[3]            = 0.6;
stateFire[3]                    = true;
stateAllowImageChange[3]        = false;
stateSequence[3]                = "Slash";
stateScript[3]                  = "onFire";
stateWaitForTimeout[3] = true;

stateName[4] = "CheckFire";
stateTransitionOnTriggerUp[4] = "StopFire";
stateTransitionOnTriggerDown[4] = "Fire";


stateName[5]                    = "StopFire";
stateTransitionOnTimeout[5]     = "Ready";
stateTimeoutValue[5]            = 0.2;
stateAllowImageChange[5]        = false;
stateWaitForTimeout[5] = true;
stateSequence[5]                = "StopFire";
stateScript[5]                  = "onStopFire";


};

function BambooSwordImage::onMount(%this, %obj, %slot)
{
%obj.hidenode("RHand");
        %obj.hidenode("LHand");
}


function BambooSwordImage::onUnMount(%this, %obj, %slot)
{
%obj.unhidenode("RHand");
        %obj.unhidenode("LHand");
}