Weapon Master VR Support Thread

So I want to take a moment to explain to yall how zeroing will work in Weapon Master VR in version 1.1. For all intents and purposes, zeroing in weapon master will work identically to real world zeroing which brings about some issues that I will get into later. First let me explain to you how zeroing works.

For the most part video games either don’t zero correctly or do it kind of half *****. AFAIK, battlefield, pubg, cod and others use one point zeroing only which isn’t how firearms work. It can get confusing, and I do often get confused myself, but let me explain to you how its supposed to be done.
8b07dadf094262934cf3f83a675520f50c4ceac9.jpeg

The top image in the above picture is how zeroing actually works and the bottom is how a lot games do it (which is wrong). May seem like a small issue but for VR it becomes I giant problem. By using correct zeroing (the top image) we also have another problem, Hitscan weapons are essentially worthless at range. This is unfortunately true, and something I am not going to attempt to fix. If you are making any modern shooter that involves long range shooting then you need to be using projectiles or a projectile asset to get correct bullet drop. Hitscan is an archaic method and only really viable in corridor shooters or arcade games.

Moving on we need to talk about zero ranges and double zeros. If you want to read an in depth look into zeroing 101 check out this great page https://www.ammoland.com/2014/06/how-to-zero-your-ar-15-rifle/#axzz4pwEXBMwE .

First off a “Double Zero”, also called convergence, is achieved when a gun has such a short initial zero that the bullet actually crosses the line of sight twice. The image below illustrates this.

Popular double zeros are (First Zero/Second Zero)

25/400
36/300
50/200

This double zero means you will be dead on accurate at two different distances as long as you are using correct bullet drop.

e9ea1063513b165d5966dccee9d6a02f3a71acb4.jpeg

Longer zeros, like 100 do not really go over the line of sight so they effectively only have 1 zero.

So what zeroes will we have in weapon master?

Pistols: 25 yard zero
Shotguns: 25 yard zero (note: shotgun trajectory is different than rifle but uses the same logic)
Rifle 1x and Ironsight: 50/200 yard zero
Rifle Acog Fixed: 50/200 yard zero
Rifle Scope Variable: 100, 50/200, 36/300, 25/400 yard zero

For example, with the Tavor AR and the Acog your shot will be dead on at 50 and 200ish yards, 6 inches low at 300 yards, 1.5 inches high at 100 yards, and 1.5 inches low at 25 yards.

So that’s great Brad but it seems super complicated, how will I be able to set up my own zeroes, and how will I get my sight angled correctly?

The answer to that is, for scopes and sights, we will angle the camera or hololense towards the first convergence point (zero point). For iron sights we will have to manually adjust the front or rear sight to get it to align corrently.

So how do we get the angle? Well to do that we will use some geometry.

40f30529b94c3d78d973b1c2a734c623.jpg

The formula we will use to get the angle we need is tan(d) = a/b. In order to get a and b we need to get calculate the difference in height from the muzzle to the center of the sight. I will do this by using sockets and get locations of them. After that I will take the known distance we want to shoot for and add half the difference between the horizontal position of the muzzle and the sight.

So it will look like tan(d) = (abs(muzzlelocation.z - sightlocation.z))/ ((abs(muzzlelocation.x - sightlocation.x)/2) + initial zero distance(ex. 4572cm (aka 50 yards)). Then we will solve for d and angle the camera/hololense using it.

All you will really have to provide is the correct socket points and the distance you want to zero at. The script itself will reangle the sight in real time.

That will give us a good first zero point, from there it will be up to your bullet trajectory logic to make sure the second zero point (for this example 200) is correct. If you are using hitscan your weapon will be virtually useless after 100 yards using this example.

For hitscan users I recommend zeroing at 100 for the flattest trajectory but be aware you are going to be over your target and 300 to 400 yards.

The other option I am mulling around is getting a point a distance in front of the muzzle (like 50 yards (4572cm)) and then forcing the camera, or lens to rotate to face this point. This actually might be easier.

Btw, for those of you now worried that you don’t have a projectile ballistics plugin, if you can wait I will be doing my own projectile ballistics logic for version 1.2 of Weapon Master. This will replace the current basic projectile logic. :smiley:

Right on thank you very much! I am planing on adding hit animations and the death animations! And do have a problem and a couple of questions for you.

-First off concerning the bow it doesn’t attach to the attach point I have tried in many of times and it don’t work. Is there a fix for that or could I just change it so it attaches to the secondary holster is that possible?

  • I know you have been working on loading and saving. So what if I just wanted to save points from every around forever lol have you figured that out yet? That will get me by until the full system is released lol

-Then also is there a way to convert the AI in the game to use pawn sensing (onpawnsee) function? Because id like to control what AI spawn where with in the level. I tried creating different game modes for each level but that ended up not working and was a waste of time lol

This probably isn’t the place to put this, but for those interested here is a super buggy version of the game I’ve working on using this assest.

The game is called “End of Days”

http://lifeartstudios.net/update/early-demo-release-v0-1-0/

I could really use some feedback. I’ll be creating a forums page shortly.

Episode 2 of Weapon Master VR Basics going live!

Does anyone else have problems closing the hand menu? I click the button on, but clicking it again never turns it off. That is how it’s supposed to work right? Or is it all reliant on the save and close button?

Also when I use two hand stabilization on the shotgun, the bullets collide internally with the gun at the very back???

click on the save and close button in the in game menu

My menu has several pages and I would like to be able to close it by pressing the menu button again.

Its reliant on save and close, I will be adding the option to close it by button press as well.

You have changed the menu correct? Make sure your new menu windows cannot be shot by bullets. I had this bug too before I turned off bullet traces and set collision channels to ignore on the menu.

I forgot to post this on monday but here is episode 2 of Weapon Master Basics.

Is this still working for everyone?

Did you ever do the movement video for the Expansions Plugin? I can’t seem to see it anywhere. :slight_smile:

I bought the pack today and would like the two to play nicely if possible.

It’s still your menu, I didn’t change it, just added pages to the blueprint. It also doesn’t collide when using the AK47 I made, just the shotgun.

Totally unrelated, I made this css theme for the unreal docs page because staring at it forever made my eyes hurt. Here if anyone wants it -> Website Themes & Skins by Stylish | Userstyles.org

Probably going to make one for the forums too, still too bright.

Is your shotgun hitscan or projectile?

Haven’t yet. I haven’t had time with such heavy dev going into 1.1. I plan to do it after 1.2. It’s going to be a massive tutorial. I expecting at least 10 go 20 hours of dev time just to figure it out and likely a 3-4 hour tutorial. It’s not an easy thing to do.

It’s exactly the same as your shotgun from the physical firearm. Just changed the models. Same skeleton too.

I am about to do this myself. Anyway I can ease this transition? Maybe a copy of the updated code? I also just migrated the whole thing to 4.17, which btw has increased fps for some reason.

Thanks for the quick reply. I understand, thats a lot of work. I’ve got plenty to keep me busy in the meantime with all the stuff in the pack anyway!

Believe me, it is something I want to do. Our game, that uses weapon master, will also be using 's Open VR Expansion Plugin. So its going to happen, I just have to figure out how to do it so that all of the features of both assets work together.