Author Topic: Weapon Normals  (Read 1252 times)

Offline 09090901

  • competitive irl
  • *
  • Posts: 1742
  • Rep: 22
  • anti-boomer super soldier
    • View Profile
    • Awards
Weapon Normals
« on: February 27, 2020, 05:08:18 AM »
Quick breakdown since I don't think there's an actual guide anywhere on how they work.


Basics:
- Normal determine what part of of a component deals damage
- Normals are set in the txt and not the .gmf
- Components without normals will deal damage in all directions

How they work:

Normals are determined by 3 numbers in the .txt that represent  coordinates on the X, Y, and Z axis. These coordinates lead to a point that determines which side of a component will deal damage based upon which way it deviate from the origin. As for true/false, true means that a component will also deal damage in the opposite direction across the same axis, and as you can probably guess, false is the opposite and it means that components will only deal damage in one direction.

Going back to the icepick, -1 0 0 means that it will deal damage facing towards the -X axis, and false means that it will only deal damage in one direction, and not on the positive X axis.

as for the double-sided icepick:

While the X value is now on the positive axis, having it set to true will cause it to deal damage in both directions.

Other:
- Normals can also bet set at a 45 degree angle. For instance:

normal = false 0.7071 0.7071 0

would be a point at a 45 degree originating from the center. Do note that your values have to be +/-0.7071 for things such as this


- Weapons can have normals set in more than one direction by adding another set of XYZ coords. The typhoon tooth for instance has a value of:

normal = false -1 0 0  -0.7071 0.7071 0

meaning that it will deal damage facing towards the negative x axis, and also the up to the left at a 45% angle with the second point (pretty sure this is what click meant by 1.5 normals)

- If you want to create a disk type weapon such as a saw, a value of normal = true 1 0 0  0 0 1 should be used

true 1 0 0 means that it will deal damage across both sides of the Z axis, and true 0 0 1 means that it will also deal damage across the positive and negative Z axis. While at a glance it may seem that it would only deal damage in an + shape, there's a fairly decent margin of error in how the game calculates the damaging zone. A third value of 0 1 0 can also be added if one wishes to make the top/bottom deal damage (although at this point there's no reason to for a weapon to have normals)

Hopefully this was fairly easy to understand, even if RA2 modding is fairly dead and the average builder cant even reskin a panel  heck
DSL-IRL is the libtard’s meta. Go drink more soylent, retard! #BLUELIVESMATTER

Offline kix

  • RR2 dev
  • *
  • Posts: 3452
  • Rep: -3
  • H
    • View Profile
    • Awards
Re: Weapon Normals
« Reply #1 on: February 27, 2020, 05:48:27 AM »
Lets theoretically say that you are making a part, what would be the easiest way to figure out where is normal oriented?

Offline 09090901

  • competitive irl
  • *
  • Posts: 1742
  • Rep: 22
  • anti-boomer super soldier
    • View Profile
    • Awards
Re: Weapon Normals
« Reply #2 on: February 27, 2020, 02:51:12 PM »
Lets theoretically say that you are making a part, what would be the easiest way to figure out where is normal oriented?
the component window on the bottom right
DSL-IRL is the libtard’s meta. Go drink more soylent, retard! #BLUELIVESMATTER

Offline Bildschirm

  • Makes RA2 Arenas from scratch and some Tournaments.
  • *
  • Posts: 450
  • Rep: 6
  • Has a Fetish for Vertical Spinners
  • Awards BOTM Winner Donated money for site hosting 2021
    • View Profile
    • Awards
Re: Weapon Normals
« Reply #3 on: March 08, 2020, 01:20:12 PM »
Thats cool and all but i guess when i do a completly custom weapon, it would get rejected in no time. Also I've seen this on the woke Beetle site but yours is easier to understand :P
I have a showcase! :3
Also some moments... xD