GithubHelp home page GithubHelp logo

endebert / squadmc Goto Github PK

View Code? Open in Web Editor NEW
121.0 11.0 34.0 2.72 MB

Map-based mortar calculator for Squad

Home Page: https://squadmc.ende.pro

License: MIT License

JavaScript 45.70% HTML 0.97% Vue 53.33%

squadmc's Introduction

SquadMC - The map-based mortar calculator for Squad

SquadMC is a map-based mortar elevation and bearing calculator for the game Squad.

IPhone 5 Screenshot

Links

Features

  • highly accurate elevation and bearing calculation, using heightmaps and mortar shell trajectory function
  • optimized for mobile
  • quick placement and dragging of mortar, target, and FOB markers
  • supports multiple mortar, target, and FOB markers, and allows switching between them
  • min & max mortar range indication
  • max build range and min distance to next FOB indication
  • keypad grid (toggleable)
  • keypad coordinates calculation
  • location markers (toggleable)
  • visible heightmap (toggleable)

Changelog

installation

Installation Prerequisites

  • you need a recent NodeJS version installed on your machine. Get it here.
  • install yarn for a faster installation:
    npm install -g yarn
    

Cloning repository & installing dependencies

git clone https://github.com/Endebert/squadmc.git
cd squadmc
yarn install

Running development mode

For development mode with hot-reload, execute:

yarn run serve

Building production version

For an optimized build ready for deployment, execute:

yarn run build

The build will be contained in the /dist folder.

Code of Conduct

Contributors

Attributions

squadmc's People

Contributors

ansarto avatar dependabot[bot] avatar ekzyis avatar endebert avatar kalliser avatar topmak avatar trikolon avatar ufonius avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

squadmc's Issues

Fire mission for each mortar to appear in footer.

Inspired by issue #45

Use case: Managing 2+ mortars with separate fire missions.

I am aware that we can select another icon from within the footer. This is easy enough if the 2 mortars are firing on the same target line/area.

But where I would like them to have different targets I may need to change up to 3 icons and mission step. This is tedious, mistake introducing, and much harder if I need to repeat coordinates to squadmate.

Solution is to track multiple fire missions on the footer.

  • Can step through each individually.
  • Both are displayed on screen, no switching required.
  • If they share an icon in their fire mission (e.g. blue icon is end of line for both red and green) then dragging icon would update both fire missions.

Use case screenshot mockup: two morters tracking 2 different fire mission lines

Screenshot from 2020-02-05 12-50-12

New Map

A new map is out called "Best" Is there any eta and is there anything I can do to help?

New ranges in Post Scriptum

Hi Endebert. Your mortar calculator is really perfect!
We have new mortar ranges in Post Scriptum. And a new faction - the French. Fortunately, they use the same mortars as the British Faction. And two new maps Dinant and Stonne. So far I haven't been able to get you a high-resolution PNG of maps. New ranges:

const gerTable = [
[100, 1536],
[150, 1519],
[200, 1502],
[250, 1485],
[300, 1467],
[350, 1450],
[400, 1432],
[450, 1415],
[500, 1397],
[550, 1378],
[600, 1360],
[650, 1341],
[700, 1322],
[750, 1302],
[800, 1282],
[850, 1262],
[900, 1241],
[950, 1219],
[1000, 1196],
[1050, 1172],
[1100, 1147],
[1150, 1121],
[1200, 1092],
[1250, 1062],
[1300, 1027],
[1350, 988],
[1400, 939],
];

const br4inchTable = [
[200, 1535],
[300, 1517],
[400, 1500],
[500, 1482],
[600, 1464],
[700, 1446],
[800, 1428],
[900, 1409],
[1000, 1391],
[1100, 1372],
[1200, 1353],
[1300, 1333],
[1400, 1313],
[1500, 1293],
[1600, 1272],
[1700, 1250],
[1800, 1228],
[1900, 1205],
[2000, 1181],
[2100, 1155],
[2200, 1128],
[2300, 1100],
[2400, 1069],
[2500, 1034],
];

const br3inchTable = [
[100, 1536],
[150, 1519],
[200, 1502],
[250, 1485],
[300, 1467],
[350, 1450],
[400, 1432],
[450, 1415],
[500, 1397],
[550, 1378],
[600, 1360],
[650, 1341],
[700, 1322],
[750, 1302],
[800, 1282],
[850, 1262],
[900, 1241],
[950, 1219],
[1000, 1196],
[1050, 1172],
[1100, 1147],
[1150, 1121],
[1200, 1092],
[1250, 1062],
[1300, 1027],
[1350, 988],
[1400, 939],
];

const usa6cmTable = [
[100, 1536],
[150, 1519],
[200, 1502],
[250, 1485],
[300, 1467],
[350, 1450],
[400, 1432],
[450, 1415],
[500, 1397],
[550, 1378],
[600, 1360],
[650, 1341],
[700, 1322],
[750, 1302],
[800, 1282],
[850, 1262],
[900, 1241],
[950, 1219],
[1000, 1196],
[1050, 1172],
[1100, 1147],
[1150, 1121],
[1200, 1092],
[1250, 1062],
[1300, 1027],
[1350, 988],
[1400, 939],
];

Bad performance (esp. on mobile devices)

Current version of SquadMC runs @5-10fps when mortar + target is placed and one of them is dragging:

performance_mobile

Stripping template of most vuetify components (not using v-app, removing toolbar + navigation drawer, using div instead of v-content, etc.) gets me to ~20fps, but that's still far from ideal.

If there is anyone who knows how to fix this, or in general improve performance with Vue and/or Vuetify, please let me know.

This could also be related to leaflet, as the dragging handler for a marker sets everything in motion (updates PinHolder.pos, which triggers watcher, which calculates new bearing, etc.)

Toggle feature for including assets in height maps

Have a toggle feature for including assets in height maps.

These assets could include:

  • Bridges
  • Dams
  • Buildings
  • Bunker Roofs etc
    I am not sure how the initial height maps were created so not sure how easy this would be to implement in the raw height map files.

Use case:

  • Striking 1st volley onto roof of occupied apartment building on Al-Basrah.

Update maps?

Could you please update the maps to the newest maps, Canadian pack, etc.

New Mil Values in PS 4.21

Hello - It appears that the developers changed the mortar MIL values in a recent patch. So when using your (awesome!) tool it displays the incorrect MIL value.

I took a screenshot of the new values in-game.
USA 6CM Mortars
USA6CM

Brit 4"
Brit4
Brit 3"
Brit3

Ger 8CM"
Germ_8CM

Feature Request: Squad Rocket Technical support

As of the current Alpha 13 public test branch rocket technicals display elevation to the gunner and allow for (very) limited turret traverse for fine-tuning purposes. This makes them much more feasible to use despite their imprecision, especially given their remarkable range at full elevation.
However, squadcalc.com (the only calculator supporting rocket technicals that I know of) is horrifically out of date on that front, and the developer has stated that for various reasons he is in no position to update it.

Therefore I request adding rocket technical support to this calculator.

PostScriptumMC incorrect

On the 3rd December 2019 the Mortar system in Post Scriptum was changed and the calculator is now inaccurate and uses the old values
Example:
PS: 100m 1536mil - PSMC: 100m 1563mil
PS: 1000m 1196mil - PSMC: 1000m 1186mil

I'm not sure what changed but to quote the patchnotes:
"Fixed mortar aim being off by 100-200 meters."
The Calculator worked fine before this change however.

I looked inside the MortarCalc Code and found out that the new values are already in place, yet it displays the old values.
I would be ready to help with as much research as needed within the limits of the Game, however I'm not much of a Coder or Mathematician.

UpdateUI

Use this calc quite a bit. There some room on the left side panel. Could there be a list of Coords and Mils is you have it set up to shoot a line or an area? Breaks up the flow when you shoot, Alt Tab to other screen, click the arrow, alt tab back, adjust and shoot. I dont use that great feature cause it takes too long and breaks up the fire missions.

Usability: Improve side navigation visibility

I think new users won't notice that there is a side navigation with advanced options. The 'logo button' on the top left doesn't really look like it's a button. Maybe this could be improved?

Additionally: On desktop (or wide screen sizes) the navigation could be auto expanded?

Yehorivka Map not up to date

Hello, it looks like the map's out of date.

https://squadmaps.com/full/Yehorivka_AAS_v1.jpg
the lower part of the airfield is missing.
or the Yehorivka v12card is missing in the menu selection.

Edit:

Looks like a browser problem on the pc. I have tested 3 Browsers ( Opera , Firefox , Edge ).
Yehorivka v12 is not displayed.But I can see v12 via my mobile phone...

Severely needs update

We're in alpha 15 and many new features/map have been added. :) just a user love it on the maps (mestia brutal murder of crucible alpha) i can use it. Have no idea how to code.

New maps!

Hello!

Since squad now are in V1 and it's growing more then never before i think it would be nice to get the new maps and uppdate the old ones.
Can say that i use Squad MC daily since i play comp etc.

only 1 range circle at a time

Hello.

When placing down mortars it shows the range circle fine on the first, then when you place another one in another color the circle switches to the new placed mark.

To get the first range shown again you need to change the size of the icons.

(happends on squad and PS if they are unconnected)

Lashkar Valley

any chance lashkar valley can be added to the calculator, tournaments are beginning to include the map into their rotations and it would really help teams out. thanks in advance

yehorivka

Grids are wrong. EX F06-5-5 in game map is E05-5-7 in calc map

Allow placement of the same marker multiple times

I.E., When placing down a blue mortar marking, and then placing down a blue fire mission marker, allow placing multiple of a marker with an auto-incrementing numeric ID. This would work by showing no number if only one of a marker exists, and then showing a small "1" on the first marker and a small "2" on the second marker placed, on so on.

This would allow mocking up a more real-use case map where the color of the markers indicates teams, squads, order of targets, etc,. You could, for example, use blue or green markers for one team, placing multiple HAB markers or mortar markers and use red for the opposing team.

Map Kohat not accurate

For map Kohat, grid shown on calculator map is not the same as grid in-game.
For example, J11-X-X in-game is I10-X-X on the webpage.

Question - How are markers made?

How do you make the markers for the cap zones shown on the squad calc?
I want to provide the same for Post Scriptum, but since you don't have the game I could help and make the marks, if I knew how they are formated.

That way you can simply copy + paste :)

PWA Support

  • Offline use + improved caching
  • "Add to homescreen" functionality

Need update!

Need update of the name and locations of the cities.

Height difference

Code related steps to get this feature completed:

  • create function to calculate elevation without the need of the mortar table
  • enhance function so that height difference is taken into consideration
  • load heightmap data
  • calculate height based on pixel value and scaling factor

The hard part is done, now all that is needed is the heightmaps for each level.

  • Al Basrah
  • Belaya
  • Chora Valley
  • Fool's Road
  • Operation First Light (Forest)
  • Gorodok
  • Jensen's Range
  • Kohat Toi River Valley
  • Kokan
  • Logar Valley
  • Mestia
  • Narva
  • Sumari Bala
  • Yehorivka

For each map, we need 4 things:

  1. exported heightmap as 16bit PNG
  2. Landscape Transform
    screenshot 3
  3. NW Minimap CornerMarker Transform
    screenshot 1
  4. SE Minimap CornerMarker Transform
    screenshot 2

With that information, I can double-check the map sizes and crop the heightmap to fit the minimap.

Area Attack

I just found the project 20 min ago and shot some solutions. But is it possible to display all the area solution at the same time. When I have it open on the second monitor, the need to tab out every time is really time-consuming.
At the moment:
atm
Maybe better:
better

Add Router

Would be nice to have a router so the shown map is also reflected in the url bar. This would also enable users to use the browser navigation buttons to navigate map history.

Example:
https://squadmc.ende.pro/#/belaya => Belaya map is shown

Adding other Icon

I would like to contribute and help. I think a good thing to add is an Icon for a fob, radio, and generating the range/distance A to B is for optimal placement of stuff. Let me know what you think

Gravity and Milli-Radian Percision

export const GRAVITY = 9.81;
The actual value of gravity in Squad is 9.80 m/s², which can be found in the SDK.

It would also be awesome to see milli-radians displayed to the tenth's or hundredth's place, instead of rounding off into whole numbers. I know it's small, but the small increments can really make a difference, especially when your target is near a wall.

Thank you very much for this mortar calculator. It's hands down the best I've seen yet, and it implements a lot of things I was never able to completely figure out.

Synced views

I think it would be a really nice feature that would set the app apart from others if we had the option to create "multiplayer" rooms where multiple users could view or edit the same calculations in real time.

Request to add SPM OP First Light

This is a frequent map that is played during competitions. It would really help out the teams if this was added. Thanks you are the best!

Hypoxic

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.