Melee with rifle

In this forum you will find and post information regarding the modding of Star Wars Battlefront 2. DO NOT POST MOD IDEAS/REQUESTS.

Moderator: Moderators

Post Reply
User avatar
bobfinkl
Rebel Colonel
Rebel Colonel
Posts: 593
Joined: Sun Jul 13, 2008 9:01 am
Projects :: Lots of unreleased stuff
Games I'm Playing :: Life
xbox live or psn: No gamertag set
Location: The quaint little city gametoast.

Melee with rifle

Post by bobfinkl »

Hello there GT, I have an issue that I had once before but being generally ignored my question was unanswered for quite some time, and I have been unable to figure it out since and am absolutely clueless on the subject, so I ask once again. How would I go about making a melee weapon where the player whacks the enemy with the butt of the rifle, and the msh changes depending on the current primary weapon, similar to the one in MetalcoreRancors zombie beta.

Any help appreciated.
myers73
Lieutenant General
Lieutenant General
Posts: 690
Joined: Fri Apr 03, 2009 11:04 pm
Projects :: No Mod project currently.
Games I'm Playing :: I have not listed any games yet
xbox live or psn: No gamertag set
Location: Atlanta, GA xfire=myers73 IngameName=mYers

Re: Melee with rifle

Post by myers73 »

its done through a .combo file as your secondary weapon. first you should go find an animationfor it though, or you wont get anywhere.
User avatar
bobfinkl
Rebel Colonel
Rebel Colonel
Posts: 593
Joined: Sun Jul 13, 2008 9:01 am
Projects :: Lots of unreleased stuff
Games I'm Playing :: Life
xbox live or psn: No gamertag set
Location: The quaint little city gametoast.

Re: Melee with rifle

Post by bobfinkl »

myers73 wrote:first you should go find an animation for it though, or you wont get anywhere.
I know the exact anims I will use for this purpose, Darthmauls first cut for rifles, and Sidious' cut from above.
myers73 wrote:its done through a .combo file as your secondary weapon.
Care to explain how this would be used? I thought it would just use replaced secondary weapon anims.
kinetosimpetus
Imperial Systems Expert
Imperial Systems Expert
Posts: 2381
Joined: Wed Mar 25, 2009 4:15 pm
Projects :: A secret project
Games I'm Playing :: Warframe STO

Re: Melee with rifle

Post by kinetosimpetus »

if you modify force push to use the range and damage you want, you can rename the anims to "rc_rifle_stand_shoot_secondary_full" for example, where rc is the new anim set name.

also, you can use different ones for rifle, pistol, bazooka, and tool. and probably stand and crouch.
User avatar
Fiodis
Master of the Force
Master of the Force
Posts: 4145
Joined: Wed Nov 12, 2008 9:27 pm
Projects :: Rannoch + Tientia + Tools Programming

Re: Melee with rifle

Post by Fiodis »

Borrow and edit the melee weapon from the BFX assets.
MetalcoreRancor
Brigadier General
Brigadier General
Posts: 628
Joined: Thu Jun 07, 2007 11:13 am
Projects :: No Mod project currently.
Games I'm Playing :: swbf origin
xbox live or psn: No gamertag set

Re: Melee with rifle

Post by MetalcoreRancor »

This is by no means an invention of my own. I was inspired to make such a weapon from Maveritchell, and it is simply a replacement of secondary fire anims, to be a melee attack move. It is a short range invisible ordnance set up with class type cannon, and emmitterordnance as the ord.

The chainsaw user uses the same premise.
User avatar
bobfinkl
Rebel Colonel
Rebel Colonel
Posts: 593
Joined: Sun Jul 13, 2008 9:01 am
Projects :: Lots of unreleased stuff
Games I'm Playing :: Life
xbox live or psn: No gamertag set
Location: The quaint little city gametoast.

Re: Melee with rifle

Post by bobfinkl »

Well I got my melee weapon setup and working, but the anims is where I am confused. How would I go about replacing them, and will it override my regular grenades anims?
kinetosimpetus
Imperial Systems Expert
Imperial Systems Expert
Posts: 2381
Joined: Wed Mar 25, 2009 4:15 pm
Projects :: A secret project
Games I'm Playing :: Warframe STO

Re: Melee with rifle

Post by kinetosimpetus »

Darthducks anim assets often have tuts for creating anim sets. If you name it the way i did, it replaces the drop item, not grenade throw anim
AQT
Gametoast Staff
Gametoast Staff
Posts: 4910
Joined: Sat Nov 03, 2007 4:55 pm
Location: SoCal, USA

Re: Melee with rifle

Post by AQT »

The "drop item" anims is human_x_stand_shoot_secondary.msh by default, where x is rifle, bazooka, pistol, or tool. So just rename your replacement animation to y_x_stand_shoot_secondary.msh (y being the name you chose to call your new animation set).
User avatar
bobfinkl
Rebel Colonel
Rebel Colonel
Posts: 593
Joined: Sun Jul 13, 2008 9:01 am
Projects :: Lots of unreleased stuff
Games I'm Playing :: Life
xbox live or psn: No gamertag set
Location: The quaint little city gametoast.

Re: Melee with rifle

Post by bobfinkl »

Ok, well I've managed to munge my anims now, but it still isn't working, I have basepose.msh and rus_stand_shoot_secondary.msh in my rus anim folder, it munged properly and I have in the munged folder of my sides; rus.anims, rus.zaabin and rus.zafbin. Lastly my odf: looks like this:
Hidden/Spoiler:
[WeaponClass]

ClassLabel = "cannon"

[Properties]
AnimationName = "rus"
HUDTag = "hud_force_push"
GeometryName = ""
HighResGeometry = ""

RoundsPerClip = "0"
ReloadTime = "0.3"
HeatRecoverRate = "0.2"
HeatThreshold = "0.0"

OrdnanceName = "rus_weap_inf_mosin_hit_ord"

TriggerSingle = "1"
ShotDelay = "0.3"
HeatPerShot = "0.0"
MaxPressedTime = "0.0"
AnimationName = "rus"

LockOnRange = "64.0"
LockTime = "0.0"
AutoAimSize = "2.0"

SalvoCount = "1"
ShotsPerSalvo = "1"
SalvoDelay = "0.0"
SalvoTime = "0.0"
InitialSalvoDelay = "0.5"

EnergyDrain = 10.0
FireAnim = "2"
InstantPlayFireAnim = "1"
OffhandWeapon = 1

TargetEnemy = "1"
TargetNeutral = "1"
TargetFriendly = "0"

TargetPerson = "1"
TargetAnimal = "1"
TargetDroid = "1"
TargetVehicle = "0"
TargetBuilding = "0"

AITargetPerson = "0"
AITargetAnimal = "0"
AITargetDroid = "0"
AITargetVehicle = "0"
AITargetBuilding = "0"

//SOUND
FireSound = "force_push_fire"
//ReloadSound = ""
WeaponChangeSound = ""
ChangeModeSound = ""
FireEmptySound = ""
ChargeSound = ""
ChargeSoundPitch = "0.05"
OverheatSound = ""
OverheatSoundPitch = "0.5"
OverheatStopSound = ""
If my error log is needed I'll go ahead and get it.
kinetosimpetus
Imperial Systems Expert
Imperial Systems Expert
Posts: 2381
Joined: Wed Mar 25, 2009 4:15 pm
Projects :: A secret project
Games I'm Playing :: Warframe STO

Re: Melee with rifle

Post by kinetosimpetus »

AnimationName goes in the unit odf.
Post Reply