Massassi Forums Logo

This is the static archive of the Massassi Forums. The forums are closed indefinitely. Thanks for all the memories!

You can also download Super Old Archived Message Boards from when Massassi first started.

"View" counts are as of the day the forums were archived, and will no longer increase.

ForumsJedi Knight and Mysteries of the Sith Editing Forum → help
help
2001-06-24, 2:31 PM #1
I need help making the raildet shoot more than one grenade liek maybe 6 or 7 help please....

------------------
If You Unlesh My Power I Will Destroy You.
2001-06-24, 3:04 PM #2
Just copy its fire projectile line and paste it under the original one.
Gravity isn't MY fault--I voted for velcro.
2001-06-24, 3:08 PM #3
Okay thanks umm like this
projectile=+grenade2
projectile=+grenade2
projectile=+grenade2

or is it diff

------------------
If You Unlesh My Power I Will Destroy You.
2001-06-24, 3:25 PM #4
Not the one in the symbols section. The one in the Fire section of the code.
Gravity isn't MY fault--I voted for velcro.
2001-06-24, 3:35 PM #5
okay i don't understand could you write a cog for me on here so i can see it...if so thanks if not htanks for trying to help me i learnt something hopefully

------------------
If You Unlesh My Power I Will Destroy You.
2001-06-24, 3:50 PM #6
Open up the weap_raildet cog and do a search for this line,

Code:
rail = FireProjectile(player, projectile[mode], fireSound, 18, '0.0214 0.15 0.00', '0 0 0', 1.0, 0x20, autoAimFOV, autoAimFOV*2);


When you find it, simply copy it and paste it under the original line

[This message has been edited by Boba Rhett (edited June 24, 2001).]
Gravity isn't MY fault--I voted for velcro.
2001-06-24, 9:00 PM #7
Here ...

for(i=0; i=<7; i=i+1)
{
FireProjectile(bla bla);
}
2001-06-25, 4:29 AM #8
HERE copy and Past this over your entire rail det script.. open it up and just past this over the entire thing....

# Jedi Knight Cog Script
#
#Number 7 Auto-Grenade Launcher
#Requested By Xyloid
#Here You GO!
#
# [YB & CYW]
#
# (C) 2001 Spawn All Rights Reserved


symbols

model povModel=rldv.3do local
model weaponMesh=rldg.3do local
sound mountSound=RailChargeArm01.WAV local
sound dismountSound=PutWeaponAway01.wav local
sound fireSound=concuss5.WAV local
sound outSound=RailChargeEmpty01.WAV local

thing player local

keyframe mountAnim=RldVmnt.key local
keyframe dismountAnim=RldVdis.key local
keyframe povfireAnim=RldVpst1.key local
keyframe holsterAnim=kyhlstr.key local

template projectile=+grenade1 local
template projectile2=+grenade2 local
template flash=+whitecloud local

thing rail local

flex fireWait=0.5 local
flex powerBoost local
flex autoAimFOV=25 local
flex autoAimMaxDist=5 local
flex holsterWait local

keyframe railAnim=rld0anim.key local

int trackID=-1 local
int mode local
int holsterTrack local

int selectMode=1 local

message activated
message deactivated
message selected
message deselected
#message newplayer
message autoselect
message fire
message timer

end

# ========================================================================================

code

fire:
player = GetSourceRef();
mode = GetSenderRef();

// Check that the player is still alive.
if(GetThingHealth(player) <= 0)
{
Return;
}

// Check Ammo - If we are out, autoselect best weapon.
if(GetInv(player, 15) < 1.0)
{
PlaySoundThing(outSound, player, 1.0, -1, -1, 0x80);
if(GetAutoSwitch() & 1)
SelectWeapon(player, AutoSelectWeapon(player, 1));
Return;
}

jkPlayPOVKey(player, povfireAnim, 1, 0x38);
SetPOVShake('0.0 -.01 0.0', '4.0 0.0 0.0', .05, 80.0);
randVec1 = VectorSet((Rand()-0.5)*5, (Rand()-0.5)*5, 0.0);
randVec2 = VectorSet((Rand()-0.5)*5, (Rand()-0.5)*5, 0.0);
randVec3 = VectorSet((Rand()-0.5)*5, (Rand()-0.5)*5, 0.0);
randVec4 = VectorSet((Rand()-0.5)*5, (Rand()-0.5)*5, 0.0);
randVec5 = VectorSet((Rand()-0.5)*5, (Rand()-0.5)*5, 0.0);
randVec5 = VectorSet((Rand()-0.5)*5, (Rand()-0.5)*5, 0.0);
randVec7 = VectorSet((Rand()-0.5)*5, (Rand()-0.5)*5, 0.0);
randVec8 = VectorSet((Rand()-0.5)*5, (Rand()-0.5)*5, 0.0);
randVec9 = VectorSet((Rand()-0.5)*5, (Rand()-0.5)*5, 0.0);
randVec10 = VectorSet((Rand()-0.5)*5, (Rand()-0.5)*5, 0.0);
dummy = FireProjectile(player, projectile, firesound, 18, '0.02 0.15 0.0', randVec1, 1.0, 0x20, autoAimFOV, autoAimMaxDist);
dummy = FireProjectile(player, projectile, -1, 18, '0.02 0.15 0.0', randVec2, 1.0, 0x20, autoAimFOV, autoAimMaxDist);
dummy = FireProjectile(player, projectile, -1, 18, '0.02 0.15 0.0', randVec2, 1.0, 0x20, autoAimFOV, autoAimMaxDist);
dummy = FireProjectile(player, projectile, -1, 18, '0.02 0.15 0.0', randVec3, 1.0, 0x20, autoAimFOV, autoAimMaxDist);
dummy = FireProjectile(player, projectile, -1, 18, '0.02 0.15 0.0', randVec4, 1.0, 0x20, autoAimFOV, autoAimMaxDist);
dummy = FireProjectile(player, projectile, -1, 18, '0.02 0.15 0.0', randVec5, 1.0, 0x20, autoAimFOV, autoAimMaxDist);
dummy = FireProjectile(player, projectile, -1, 18, '0.02 0.15 0.0', randVec2, 1.0, 0x20, autoAimFOV, autoAimMaxDist);
dummy = FireProjectile(player, projectile, -1, 18, '0.02 0.15 0.0', randVec3, 1.0, 0x20, autoAimFOV, autoAimMaxDist);
dummy = FireProjectile(player, projectile, -1, 18, '0.02 0.15 0.0', randVec4, 1.0, 0x20, autoAimFOV, autoAimMaxDist);
dummy = FireProjectile(player, projectile, -1, 18, '0.02 0.15 0.0', randVec5, 1.0, 0x20, autoAimFOV, autoAimMaxDist);
if((mode == 1) && (rail != -1))
{
PlayKey(rail, railAnim, 1, 20);
}

// Provide a kick backwards
ApplyForce(player, VectorScale(GetThingLVec(player), -40));

ChangeInv(player, 15, -1.0);

powerBoost = GetInv(player, 63);
ChangeFireRate(player, fireWait/powerBoost);

Return;

# ........................................................................................

activated:
player = GetSourceRef();
mode = GetSenderRef();
jkSetWaggle(player, '0.0 0.0 0.0', 0);
powerBoost = GetInv(player, 63);
ActivateWeapon( player, fireWait/powerBoost, mode );
Return;

# ........................................................................................

deactivated:
player = GetSourceRef();
mode = GetSenderRef();
jkSetWaggle(player, '10.0 7.0 0.0', 350);
DeactivateWeapon( player, mode );
Return;

# ........................................................................................

selected:
print("Auto-Grenade Launcher!,Better Not Stand To Close!");
player = GetSourceRef();

PlayMode(player, 41);
PlaySoundThing(mountSound, player, 1.0, -1, -1, 0x80);
jkSetPOVModel(player, povModel);
SetArmedMode(player, 1);
jkSetWeaponMesh(player, weaponMesh);
jkSetWaggle(player, '10.0 7.0 0.0', 350);

trackID = jkPlayPOVKey(player, mountAnim, 0, 20);
SetMountWait(player, GetKeyLen(mountAnim));
jkClearFlags(player, 0x5);
SetCurWeapon(player, 7);

// Check Ammo - If we are out, autoselect best weapon.
if(GetInv( player, 15 ) < 1.0)
{
PlaySoundThing(outSound, player, 1.0, -1, -1, 0x80);
if(GetAutoSwitch() & 1)
SelectWeapon(player, AutoSelectWeapon(player, 1));
}

Return;

# ........................................................................................

deselected:
player = GetSourceRef();

PlaySoundThing(dismountSound, player, 1.0, -1, -1, 0x80);
jkPlayPOVKey( player, dismountAnim, 0, 18 );

holsterWait = GetKeyLen(holsterAnim);
SetMountWait(player, holsterWait);
holsterTrack = PlayKey(player, holsterAnim, 1, 0x4);
SetTimerEx(holsterWait, 2, 0.0, 0.0);
if (trackID != -1)
{
jkStopPOVKey( player, trackID, 0 );
trackID = -1;
}
jkSetWaggle(player, '0.0 0.0 0.0', 0);

Return;

# ........................................................................................

//newplayer:
// player = GetSourceRef();
//
// // Make sure that if the player is respawning, the old mount isn't playing anymore.
// if (trackID != -1)
// jkStopPOVKey(player, trackID, 0);
//
// Return;

# ........................................................................................

autoselect:
selectMode = GetSenderRef();
player = GetSourceRef();

// If the player has the weapon
if(GetInv(player, 7) != 0.0)
{
// If the player has ammo
if(GetInv(player, 15) != 0.0)
{

// query for ammo
if(selectMode == -1)
{
ReturnEx(900.0);
Return;
}

if((selectMode == 0) && !(GetAutoPickup() & 2))
{
ReturnEx(900.0);
Return;
}

if((selectMode == 1) && !(GetAutoSwitch() & 2))
{
ReturnEx(900.0);
Return;
}

if((selectMode == 2) && !(GetAutoPickup() & 2))
{
ReturnEx(900.0);
Return;
}

ReturnEx(-2.0);
Return;

}
else
{
ReturnEx(-1.0);
Return;
}
}
else
{
ReturnEx(-1.0);
}

Return;

# ........................................................................................

timer:
StopKey(player, holsterTrack, 0.0);
Return;

end

#################################

There you go...


------------------
"I Am The Prince Of All Saiyans Once Again!"
"I Am The Prince Of All Saiyans Once Again!"

↑ Up to the top!