Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
Offline thetimn8er  
#1 Posted : Wednesday, July 10, 2013 8:10:03 PM(UTC)
thetimn8er
Private
Joined: 8/2/2012(UTC)
Posts: 38
United States
Location: Los Angeles

Thanks: 13 times
Was thanked: 4 time(s) in 3 post(s)
Hi, when editing my weapon, I noticed a problem that occurs when the vehicle is at a downwards angle in front of a hill. The weapon fires and is blocked by the terrain in front of it, so fires the object in the space the vehicle sits on.

UserPostedImage
As you can see, the cannons are firing ahead, but the weaponobject is being detonated at the AA gun. Also, the AA gun takes no damage for unknown reasons.

The weapon object:
Code:

Object Blank

  ; *** ART Parameters ***
  Draw = W3DModelDraw ModuleTag_01
    DefaultConditionState
      Model = AVTankShel
    End
  End

  ; ***DESIGN parameters ***
  DisplayName       = OBJECT:TankShell
  EditorSorting     = SYSTEM
  ArmorSet
    Armor = ProjectileArmor
  End
  VisionRange = 0.0  

  ; *** ENGINEERING Parameters ***
  KindOf = PROJECTILE
  Body = ActiveBody ModuleTag_02
    MaxHealth       = 100.0
    InitialHealth   = 100.0
  End

  Behavior = DestroyDie ModuleTag_03
    ;nothing
  End
    
  Behavior = DumbProjectileBehavior ModuleTag_04
    ; To tweak a Bezier path, please see GS
    FirstHeight = 10  ; Height of Bezier control points above highest intervening terrain
    SecondHeight = 10
    FirstPercentIndent = 50% ; Percentage of shot distance control points are placed
    SecondPercentIndent = 90%
    FlightPathAdjustDistPerSecond   = 100 ; Can allow a max speed this can attempt to follow a target. Units are their velocity we can tag.
  End

  Behavior = PhysicsBehavior ModuleTag_05
    Mass = 0.01   ; we can't have a zero mass, but we want it pretty tiny...
  End

  Geometry = Sphere
  GeometryIsSmall = Yes
  GeometryMajorRadius = 1.0

  Scale = 0.1

End
Sponsor
Offline Annihilationzh  
#2 Posted : Thursday, July 11, 2013 5:19:32 PM(UTC)
Annihilationzh
General
Joined: 8/2/2008(UTC)
Posts: 1,779
United Kingdom

Thanks: 26 times
Was thanked: 475 time(s) in 331 post(s)
Are they firing from the correct bone? This usually happens because the projectiles don't have enough height.

Quote:
Also, the AA gun takes no damage for unknown reasons.

Weapons don't damage the user unless SELF SUICIDE is specified in the radiusdamageeffects.
If you need help, post in the forum. You'll get help a lot faster than if you send me a PM.

I reject all buddy requests. I don't think 'buddy' needs to be made official. It's not like you're marrying me.
thanks 2 users thanked Annihilationzh for this useful post.
CommieDog on 7/11/2013(UTC), thetimn8er on 7/11/2013(UTC)
Offline thetimn8er  
#3 Posted : Thursday, July 11, 2013 7:29:27 PM(UTC)
thetimn8er
Private
Joined: 8/2/2012(UTC)
Posts: 38
United States
Location: Los Angeles

Thanks: 13 times
Was thanked: 4 time(s) in 3 post(s)
Originally Posted by: Annihilationzh Go to Quoted Post
Are they firing from the correct bone? This usually happens because the projectiles don't have enough height.


I'm a bit of a noob, but from what I see in the model, there are four things called MUZZLEFX01, MUZZLEFX02, MUZZLE01, and MUZZLE02. In the code it uses
Code:
WeaponFireFXBone  = PRIMARY MUZZLE
WeaponMuzzleFlash = PRIMARY MUZZLEFX


This is confusing to me, as there are no bones in the model called MUZZLE, or MUZZLEFX...
Offline CommieDog  
#4 Posted : Thursday, July 11, 2013 8:18:45 PM(UTC)
CommieDog
Administrator
C&C Labs Staff: Labs Staff MemberThe Forgotten Staff: The Forgotten StaffRed Alert Staff: Red Alert Staff MemberAll Stars Staff: All Stars Staff
Joined: 8/3/2003(UTC)
Posts: 3,086
United States

Thanks: 445 times
Was thanked: 186 time(s) in 130 post(s)
That's because the code automatically alternates between MUZZLE01 and MUZZLE02.

But in order to fix the problem, you need to add WeaponLaunchBone = PRIMARY MUZZLE.
UserPostedImage
CommieDog: Because someone has to do your dirty work for you
thanks 1 user thanked CommieDog for this useful post.
thetimn8er on 7/11/2013(UTC)
Offline thetimn8er  
#5 Posted : Thursday, July 11, 2013 8:48:45 PM(UTC)
thetimn8er
Private
Joined: 8/2/2012(UTC)
Posts: 38
United States
Location: Los Angeles

Thanks: 13 times
Was thanked: 4 time(s) in 3 post(s)
Originally Posted by: CommieDog Go to Quoted Post
That's because the code automatically alternates between MUZZLE01 and MUZZLE02.

But in order to fix the problem, you need to add WeaponLaunchBone = PRIMARY MUZZLE.


Ah, is it because the weapon uses a projectile object? It works perfectly now, thank you!
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.