diff --git a/package.json b/package.json index 6955def..d18125c 100644 --- a/package.json +++ b/package.json @@ -9,8 +9,10 @@ }, "dependencies": { "@popperjs/core": "^2.10.2", + "axios": "^0.22.0", "bootstrap": "^5.1.1", "core-js": "^3.6.5", + "luxon": "^2.0.2", "vue": "^3.0.0", "vue-router": "^4.0.0-0", "vuex": "^4.0.0-0" @@ -25,6 +27,8 @@ "babel-eslint": "^10.1.0", "eslint": "^6.7.2", "eslint-plugin-vue": "^7.0.0", - "sass-loader": "^12.1.0" + "sass": "^1.42.1", + "sass-loader": "^10.2.0", + "string-sanitizer": "^2.0.2" } } diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml index 4b8eb0b..85cd028 100644 --- a/pnpm-lock.yaml +++ b/pnpm-lock.yaml @@ -8,20 +8,26 @@ specifiers: '@vue/cli-plugin-vuex': ~4.5.0 '@vue/cli-service': ~4.5.0 '@vue/compiler-sfc': ^3.0.0 + axios: ^0.22.0 babel-eslint: ^10.1.0 bootstrap: ^5.1.1 core-js: ^3.6.5 eslint: ^6.7.2 eslint-plugin-vue: ^7.0.0 - sass-loader: ^12.1.0 + luxon: ^2.0.2 + sass: ^1.42.1 + sass-loader: ^10.2.0 + string-sanitizer: ^2.0.2 vue: ^3.0.0 vue-router: ^4.0.0-0 vuex: ^4.0.0-0 dependencies: '@popperjs/core': 2.10.2 + axios: 0.22.0 bootstrap: 5.1.1_@popperjs+core@2.10.2 core-js: 3.18.1 + luxon: 2.0.2 vue: 3.2.19 vue-router: 4.0.11_vue@3.2.19 vuex: 4.0.2_vue@3.2.19 @@ -31,12 +37,14 @@ devDependencies: '@vue/cli-plugin-eslint': 4.5.13_a58cf9e4d577795b8c257bee96d49483 '@vue/cli-plugin-router': 4.5.13_@vue+cli-service@4.5.13 '@vue/cli-plugin-vuex': 4.5.13_@vue+cli-service@4.5.13 - '@vue/cli-service': 4.5.13_0c7cfb9d6b60c37eed7038267d6bc444 + '@vue/cli-service': 4.5.13_14d4d8446413226c330137c0feac1b91 '@vue/compiler-sfc': 3.2.19 babel-eslint: 10.1.0_eslint@6.8.0 eslint: 6.8.0 eslint-plugin-vue: 7.18.0_eslint@6.8.0 - sass-loader: 12.1.0 + sass: 1.42.1 + sass-loader: 10.2.0_sass@1.42.1 + string-sanitizer: 2.0.2 packages: @@ -1565,7 +1573,7 @@ packages: dependencies: '@babel/core': 7.15.5 '@vue/babel-preset-app': 4.5.13_vue@3.2.19 - '@vue/cli-service': 4.5.13_0c7cfb9d6b60c37eed7038267d6bc444 + '@vue/cli-service': 4.5.13_14d4d8446413226c330137c0feac1b91 '@vue/cli-shared-utils': 4.5.13 babel-loader: 8.2.2_99877201e3f6dd5396b321f0a88244ea cache-loader: 4.1.0_webpack@4.46.0 @@ -1584,7 +1592,7 @@ packages: '@vue/cli-service': ^3.0.0 || ^4.0.0-0 eslint: '>= 1.6.0 < 7.0.0' dependencies: - '@vue/cli-service': 4.5.13_0c7cfb9d6b60c37eed7038267d6bc444 + '@vue/cli-service': 4.5.13_14d4d8446413226c330137c0feac1b91 '@vue/cli-shared-utils': 4.5.13 eslint: 6.8.0 eslint-loader: 2.2.1_eslint@6.8.0+webpack@4.46.0 @@ -1602,7 +1610,7 @@ packages: peerDependencies: '@vue/cli-service': ^3.0.0 || ^4.0.0-0 dependencies: - '@vue/cli-service': 4.5.13_0c7cfb9d6b60c37eed7038267d6bc444 + '@vue/cli-service': 4.5.13_14d4d8446413226c330137c0feac1b91 '@vue/cli-shared-utils': 4.5.13 dev: true @@ -1611,10 +1619,10 @@ packages: peerDependencies: '@vue/cli-service': ^3.0.0 || ^4.0.0-0 dependencies: - '@vue/cli-service': 4.5.13_0c7cfb9d6b60c37eed7038267d6bc444 + '@vue/cli-service': 4.5.13_14d4d8446413226c330137c0feac1b91 dev: true - /@vue/cli-service/4.5.13_0c7cfb9d6b60c37eed7038267d6bc444: + /@vue/cli-service/4.5.13_14d4d8446413226c330137c0feac1b91: resolution: {integrity: sha512-CKAZN4iokMMsaUyJRU22oUAz3oS/X9sVBSKAF2/shFBV5xh3jqAlKl8OXZYz4cXGFLA6djNuYrniuLAo7Ku97A==} engines: {node: '>=8'} hasBin: true @@ -1687,7 +1695,7 @@ packages: pnp-webpack-plugin: 1.7.0 portfinder: 1.0.28 postcss-loader: 3.0.0 - sass-loader: 12.1.0 + sass-loader: 10.2.0_sass@1.42.1 ssri: 8.0.1 terser-webpack-plugin: 1.4.5_webpack@4.46.0 thread-loader: 2.1.3_webpack@4.46.0 @@ -2245,6 +2253,14 @@ packages: resolution: {integrity: sha512-xh1Rl34h6Fi1DC2WWKfxUTVqRsNnr6LsKz2+hfwDxQJWmrx8+c7ylaqBMcHfl1U1r2dsifOvKX3LQuLNZ+XSvA==} dev: true + /axios/0.22.0: + resolution: {integrity: sha512-Z0U3uhqQeg1oNcihswf4ZD57O3NrR1+ZXhxaROaWpDmsDTx7T2HNBV2ulBtie2hwJptu8UvgnJoK+BIqdzh/1w==} + dependencies: + follow-redirects: 1.14.4 + transitivePeerDependencies: + - debug + dev: false + /babel-eslint/10.1.0_eslint@6.8.0: resolution: {integrity: sha512-ifWaTHQ0ce+448CYop8AdrQiBsGrnC+bMgfyKFdi6EsPLTAWG+QfyDeM6OH+FmWnKvEq5NnBMLvlBUPKQZoDSg==} engines: {node: '>=6'} @@ -2378,7 +2394,6 @@ packages: resolution: {integrity: sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA==} engines: {node: '>=8'} dev: true - optional: true /bindings/1.5.0: resolution: {integrity: sha512-p2q/t/mhvuOj/UeLlV6566GD/guowlr0hHxClI0W9m7MWYkL1F0hLo+0Aexs9HSPCtR1SXQ0TD3MMKrXZajbiQ==} @@ -2761,7 +2776,6 @@ packages: optionalDependencies: fsevents: 2.3.2 dev: true - optional: true /chownr/1.1.4: resolution: {integrity: sha512-jJ0bqzaylmJtVnNgzTeSOs8DPavpbYgEr/b0YL8/2GO3xJEhInFmhKMUnEJQjZumK7KXGFhUy89PrsJWlakBVg==} @@ -4280,7 +4294,7 @@ packages: readable-stream: 2.3.7 dev: true - /follow-redirects/1.14.4_debug@4.3.2: + /follow-redirects/1.14.4: resolution: {integrity: sha512-zwGkiSXC1MUJG/qmeIFH2HBJx9u0V46QGUe3YR1fXG8bXQxq7fLj0RjLZQ5nubr9qNJUZrH+xUcwXEoXNpfS+g==} engines: {node: '>=4.0'} peerDependencies: @@ -4288,9 +4302,6 @@ packages: peerDependenciesMeta: debug: optional: true - dependencies: - debug: 4.3.2 - dev: true /for-in/1.0.2: resolution: {integrity: sha1-gQaNKVqBQuwKxybG4iAMMPttXoA=} @@ -4807,7 +4818,7 @@ packages: engines: {node: '>=8.0.0'} dependencies: eventemitter3: 4.0.7 - follow-redirects: 1.14.4_debug@4.3.2 + follow-redirects: 1.14.4 requires-port: 1.0.0 transitivePeerDependencies: - debug @@ -5042,7 +5053,6 @@ packages: dependencies: binary-extensions: 2.2.0 dev: true - optional: true /is-boolean-object/1.1.2: resolution: {integrity: sha512-gDYaKHJmnj4aWxyj6YHyXVpdQawtVLHU5cb+eztPGczf6cjuTdwve5ZIEfgXqH4e57An1D1AKf8CZ3kYrQRqYA==} @@ -5535,7 +5545,6 @@ packages: emojis-list: 3.0.0 json5: 2.2.0 dev: true - optional: true /locate-path/3.0.0: resolution: {integrity: sha512-7AO748wWnIhNqAuaty2ZWHkQHRSNfPVIsPIfwEOWO22AmaoVrWavlOcMR5nzTLNYvp36X220/maaRsrec1G65A==} @@ -5613,6 +5622,17 @@ packages: yallist: 3.1.1 dev: true + /lru-cache/6.0.0: + resolution: {integrity: sha512-Jo6dJ04CmSjuznwJSS3pUeWmd/H0ffTlkXXgwZi+eq1UCmqQwCh+eLsYOYCwY991i2Fah4h1BEMCx4qThGbsiA==} + engines: {node: '>=10'} + dependencies: + yallist: 4.0.0 + dev: true + + /luxon/2.0.2: + resolution: {integrity: sha512-ZRioYLCgRHrtTORaZX1mx+jtxKtKuI5ZDvHNAmqpUzGqSrR+tL4FVLn/CUGMA3h0+AKD1MAxGI5GnCqR5txNqg==} + dev: false + /magic-string/0.25.7: resolution: {integrity: sha512-4CrMT5DOHTDk4HYDlzmwu4FVCcIYI8gauveasrdCu2IKIFOJ3f0v/8MDGJCDL9oD2ppz/Av1b0Nj345H9M+XIA==} dependencies: @@ -7078,7 +7098,6 @@ packages: dependencies: picomatch: 2.3.0 dev: true - optional: true /regenerate-unicode-properties/9.0.0: resolution: {integrity: sha512-3E12UeNSPfjrgwjkR81m5J7Aw/T55Tu7nUyZVQYCKEOs+2dkxEY+DpPtZzO4YruuiPb7NkYLVcyJC4+zCbk5pA==} @@ -7334,14 +7353,14 @@ packages: resolution: {integrity: sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg==} dev: true - /sass-loader/12.1.0: - resolution: {integrity: sha512-FVJZ9kxVRYNZTIe2xhw93n3xJNYZADr+q69/s98l9nTCrWASo+DR2Ot0s5xTKQDDEosUkatsGeHxcH4QBp5bSg==} - engines: {node: '>= 12.13.0'} + /sass-loader/10.2.0_sass@1.42.1: + resolution: {integrity: sha512-kUceLzC1gIHz0zNJPpqRsJyisWatGYNFRmv2CKZK2/ngMJgLqxTbXwe/hJ85luyvZkgqU3VlJ33UVF2T/0g6mw==} + engines: {node: '>= 10.13.0'} peerDependencies: fibers: '>= 3.1.0' node-sass: ^4.0.0 || ^5.0.0 || ^6.0.0 sass: ^1.3.0 - webpack: ^5.0.0 + webpack: ^4.36.0 || ^5.0.0 peerDependenciesMeta: fibers: optional: true @@ -7351,7 +7370,19 @@ packages: optional: true dependencies: klona: 2.0.4 + loader-utils: 2.0.0 neo-async: 2.6.2 + sass: 1.42.1 + schema-utils: 3.1.1 + semver: 7.3.5 + dev: true + + /sass/1.42.1: + resolution: {integrity: sha512-/zvGoN8B7dspKc5mC6HlaygyCBRvnyzzgD5khiaCfglWztY99cYoiTUksVx11NlnemrcfH5CEaCpsUKoW0cQqg==} + engines: {node: '>=8.9.0'} + hasBin: true + dependencies: + chokidar: 3.5.2 dev: true /sax/1.2.4: @@ -7376,6 +7407,15 @@ packages: ajv-keywords: 3.5.2_ajv@6.12.6 dev: true + /schema-utils/3.1.1: + resolution: {integrity: sha512-Y5PQxS4ITlC+EahLuXaY86TXfR7Dc5lw294alXOq86JAHCihAIZfqv8nNCWvaEJvaC51uN9hbLGeV0cFBdH+Fw==} + engines: {node: '>= 10.13.0'} + dependencies: + '@types/json-schema': 7.0.9 + ajv: 6.12.6 + ajv-keywords: 3.5.2_ajv@6.12.6 + dev: true + /select-hose/2.0.0: resolution: {integrity: sha1-Yl2GWPhlr0Psliv8N2o3NZpJlMo=} dev: true @@ -7401,6 +7441,14 @@ packages: hasBin: true dev: true + /semver/7.3.5: + resolution: {integrity: sha512-PoeGJYh8HK4BTO/a9Tf6ZG3veo/A7ZVsYrSA6J8ny9nb3B1VrpkuN+z9OE5wfE5p6H4LchYZsegiQgbJD94ZFQ==} + engines: {node: '>=10'} + hasBin: true + dependencies: + lru-cache: 6.0.0 + dev: true + /send/0.17.1: resolution: {integrity: sha512-BsVKsiGcQMFwT8UxypobUKyv7irCNRHk1T0G680vk88yf6LBByGcZJOTJCrTP2xVN6yI+XjPJcNuE3V4fT9sAg==} engines: {node: '>= 0.8.0'} @@ -7792,6 +7840,10 @@ packages: engines: {node: '>=0.10.0'} dev: true + /string-sanitizer/2.0.2: + resolution: {integrity: sha512-zECtWmUawolaVbUOdDRdhAM4jN7wl1sB4indjTmHpUFavzFSeYEDSVF85dZPPyDKoMRTJbrz+Tp0SjPPCWxscA==} + dev: true + /string-width/2.1.1: resolution: {integrity: sha512-nOqH59deCq9SRHlxq1Aw85Jnt4w6KvLKqWVik6oA9ZklXLNIOlqg4F2yrT1MVaTjAqvVwdfeZ7w7aCvJD7ugkw==} engines: {node: '>=4'} diff --git a/scss/custom.scss b/scss/custom.scss new file mode 100644 index 0000000..21d1851 --- /dev/null +++ b/scss/custom.scss @@ -0,0 +1,21 @@ +// Custom.scss +@import url('https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap'); + +// Default variable overrides +$font-family-base: 'Roboto'; +//$primary: #292c34; +//$secondary: #23262d; +//$body-bg: #2e3139; +//$blue: #4a90e2; +$body-color: white; + +$primary: #888f98; +$secondary: #10121a; +$body-bg: #1b2732; +$blue: #5f7892; +$warning: #c3a235; +$info: $blue; +$success: #609926; + +// Bootstrap +@import "../node_modules/bootstrap/scss/bootstrap"; diff --git a/src/App.vue b/src/App.vue index 083049b..5b13065 100644 --- a/src/App.vue +++ b/src/App.vue @@ -1,3 +1,27 @@ + + + + \ No newline at end of file diff --git a/src/components/Footer.vue b/src/components/Footer.vue new file mode 100644 index 0000000..873c30c --- /dev/null +++ b/src/components/Footer.vue @@ -0,0 +1,31 @@ + + + + + \ No newline at end of file diff --git a/src/components/Nav.vue b/src/components/Nav.vue new file mode 100644 index 0000000..0a8263f --- /dev/null +++ b/src/components/Nav.vue @@ -0,0 +1,110 @@ + + + + + \ No newline at end of file diff --git a/src/components/ScoreTeam.vue b/src/components/ScoreTeam.vue new file mode 100644 index 0000000..3cea037 --- /dev/null +++ b/src/components/ScoreTeam.vue @@ -0,0 +1,71 @@ + + + \ No newline at end of file diff --git a/src/components/ScoreTeamPlayer.vue b/src/components/ScoreTeamPlayer.vue new file mode 100644 index 0000000..dc75225 --- /dev/null +++ b/src/components/ScoreTeamPlayer.vue @@ -0,0 +1,130 @@ + + + \ No newline at end of file diff --git a/src/images/icons/gitfork.svg b/src/images/icons/gitfork.svg new file mode 100644 index 0000000..4ed76d5 --- /dev/null +++ b/src/images/icons/gitfork.svg @@ -0,0 +1,3 @@ + + + diff --git a/src/images/maps/de_inferno.png b/src/images/maps/de_inferno.png new file mode 100644 index 0000000..0375144 Binary files /dev/null and b/src/images/maps/de_inferno.png differ diff --git a/src/images/maps/de_mirage.png b/src/images/maps/de_mirage.png new file mode 100644 index 0000000..3fc4fef Binary files /dev/null and b/src/images/maps/de_mirage.png differ diff --git a/src/images/maps/de_overpass.png b/src/images/maps/de_overpass.png new file mode 100644 index 0000000..4ad0f9a Binary files /dev/null and b/src/images/maps/de_overpass.png differ diff --git a/src/images/maps/not_found.png b/src/images/maps/not_found.png new file mode 100644 index 0000000..daa9f5b Binary files /dev/null and b/src/images/maps/not_found.png differ diff --git a/src/images/ranks/0.png b/src/images/ranks/0.png new file mode 100644 index 0000000..a1708f6 Binary files /dev/null and b/src/images/ranks/0.png differ diff --git a/src/images/ranks/1.png b/src/images/ranks/1.png new file mode 100644 index 0000000..5c02d48 Binary files /dev/null and b/src/images/ranks/1.png differ diff --git a/src/images/ranks/10.png b/src/images/ranks/10.png new file mode 100644 index 0000000..4e76fb9 Binary files /dev/null and b/src/images/ranks/10.png differ diff --git a/src/images/ranks/11.png b/src/images/ranks/11.png new file mode 100644 index 0000000..58994c1 Binary files /dev/null and b/src/images/ranks/11.png differ diff --git a/src/images/ranks/12.png b/src/images/ranks/12.png new file mode 100644 index 0000000..c83cb43 Binary files /dev/null and b/src/images/ranks/12.png differ diff --git a/src/images/ranks/13.png b/src/images/ranks/13.png new file mode 100644 index 0000000..b0deb35 Binary files /dev/null and b/src/images/ranks/13.png differ diff --git a/src/images/ranks/14.png b/src/images/ranks/14.png new file mode 100644 index 0000000..0839229 Binary files /dev/null and b/src/images/ranks/14.png differ diff --git a/src/images/ranks/15.png b/src/images/ranks/15.png new file mode 100644 index 0000000..3ed261b Binary files /dev/null and b/src/images/ranks/15.png differ diff --git a/src/images/ranks/16.png b/src/images/ranks/16.png new file mode 100644 index 0000000..64ccdf0 Binary files /dev/null and b/src/images/ranks/16.png differ diff --git a/src/images/ranks/17.png b/src/images/ranks/17.png new file mode 100644 index 0000000..37bea6b Binary files /dev/null and b/src/images/ranks/17.png differ diff --git a/src/images/ranks/18.png b/src/images/ranks/18.png new file mode 100644 index 0000000..43899bd Binary files /dev/null and b/src/images/ranks/18.png differ diff --git a/src/images/ranks/2.png b/src/images/ranks/2.png new file mode 100644 index 0000000..2deede6 Binary files /dev/null and b/src/images/ranks/2.png differ diff --git a/src/images/ranks/3.png b/src/images/ranks/3.png new file mode 100644 index 0000000..b9a06c9 Binary files /dev/null and b/src/images/ranks/3.png differ diff --git a/src/images/ranks/4.png b/src/images/ranks/4.png new file mode 100644 index 0000000..9d6b4fe Binary files /dev/null and b/src/images/ranks/4.png differ diff --git a/src/images/ranks/5.png b/src/images/ranks/5.png new file mode 100644 index 0000000..0d8c275 Binary files /dev/null and b/src/images/ranks/5.png differ diff --git a/src/images/ranks/6.png b/src/images/ranks/6.png new file mode 100644 index 0000000..813aeee Binary files /dev/null and b/src/images/ranks/6.png differ diff --git a/src/images/ranks/7.png b/src/images/ranks/7.png new file mode 100644 index 0000000..c5f8f78 Binary files /dev/null and b/src/images/ranks/7.png differ diff --git a/src/images/ranks/8.png b/src/images/ranks/8.png new file mode 100644 index 0000000..e3c889a Binary files /dev/null and b/src/images/ranks/8.png differ diff --git a/src/images/ranks/9.png b/src/images/ranks/9.png new file mode 100644 index 0000000..91a8650 Binary files /dev/null and b/src/images/ranks/9.png differ diff --git a/src/main.js b/src/main.js index a92f228..890fa23 100644 --- a/src/main.js +++ b/src/main.js @@ -2,5 +2,7 @@ import { createApp } from 'vue' import App from './App.vue' import router from './router' import store from './store' +import 'bootstrap' +import '../scss/custom.scss' createApp(App).use(store).use(router).mount('#app') diff --git a/src/router/index.js b/src/router/index.js index 6c3a727..d19865e 100644 --- a/src/router/index.js +++ b/src/router/index.js @@ -1,12 +1,43 @@ import { createRouter, createWebHistory } from 'vue-router' -import Home from '../views/Home.vue' + +function lazyLoad(view) { + return () => import(`@/views/${view}.vue`) +} const routes = [ { path: '/', name: 'Home', - component: Home + component: lazyLoad('Home') }, + { + path: '/player/:id', + name: 'Player', + component: lazyLoad('Player'), + props: true + }, + { + path: '/player/:id/matches', + name: 'MyMatches', + component: lazyLoad('MyMatches'), + props: true + }, + { + path: '/match/:match_id', + name: 'Match', + component: lazyLoad('Match'), + props: true + }, + { + path: '/explore', + name: 'Explore', + component: lazyLoad('Explore'), + props: true + }, + { + path: '/:pathMatch(.*)*', + redirect: '/' + } ] const router = createRouter({ diff --git a/src/store/index.js b/src/store/index.js index 5f05f19..44ac28c 100644 --- a/src/store/index.js +++ b/src/store/index.js @@ -2,6 +2,8 @@ import { createStore } from 'vuex' export default createStore({ state: { + id64: '', + vanityUrl: '' }, mutations: { }, diff --git a/src/utils/index.js b/src/utils/index.js new file mode 100644 index 0000000..e3f2141 --- /dev/null +++ b/src/utils/index.js @@ -0,0 +1,50 @@ +import {DateTime} from "luxon/build/es6/luxon"; +import router from '@/router' + +export const FormatDuration = (d) => { + const hours = Math.floor(d / 3600) + const num = d % 3600 + const minutes = Math.floor(num % 3600 / 60) + const seconds = Math.floor(num % 3600 % 60) + + if (hours !== 0) + return `${hours}:${minutes < 10 ? '0' + minutes : minutes}:${seconds < 10 ? '0' + seconds : seconds}` + else + return `${minutes < 10 ? '0' + minutes : minutes}:${seconds < 10 ? '0' + seconds : seconds}` +} + +export const FormatDate = (date) => { + const matchDate = DateTime.fromISO(date) + const diff = DateTime.now().diff(matchDate) + + if (diff.as('days') > 10) + return matchDate.toLocaleString({weekday: 'short', day: 'numeric', month: 'numeric', year: 'numeric'}) + else if (diff.as('days') < 1) + if (diff.as('hours') < 1) + return Math.floor(diff.as('minutes')) + ' minutes ago' + else + return Math.floor(diff.as('hours')) + ' hours ago' + else + return Math.floor(diff.as('days')) + ' days ago' +} + +export const GoToMatch = (id) => { + router.push(`/match/${id}`) +} + +export const GoToPlayer = (id) => { + router.push(`/player/${id}`) +} + +export const GetHLTV_1 = (kills = 0, rounds, deaths = 0, k2 = 0, k3 = 0, k4 = 0, k5 = 0) => { + const k1 = kills - k2 - k3 - k4 - k5 + const Weight_KPR = 0.679 // weight kills per round + const Weight_SPR = 0.317 // weight survived rounds per round + const Weight_RMK = 1.277 // weight value calculated from rounds with multiple kills (1k + 4*2k + 9*3k + 16*4k + 25*5k) + + const KillRating = kills / rounds / Weight_KPR + const SurvivalRating = (rounds - deaths) / rounds / Weight_SPR + const RoundsWithMultipleKillsRating = (k1 + 4 * k2 + 9 * k3 + 16 * k4 + 25 * k5) / rounds / Weight_RMK + + return ((KillRating + 0.7 * SurvivalRating + RoundsWithMultipleKillsRating) / 2.7).toFixed(2) +} \ No newline at end of file diff --git a/src/views/Explore.vue b/src/views/Explore.vue new file mode 100644 index 0000000..55dd221 --- /dev/null +++ b/src/views/Explore.vue @@ -0,0 +1,9 @@ + + + \ No newline at end of file diff --git a/src/views/Home.vue b/src/views/Home.vue index c9997f4..de28c8d 100644 --- a/src/views/Home.vue +++ b/src/views/Home.vue @@ -1,3 +1,112 @@ + + + + + \ No newline at end of file diff --git a/src/views/Match.vue b/src/views/Match.vue new file mode 100644 index 0000000..0e2122b --- /dev/null +++ b/src/views/Match.vue @@ -0,0 +1,177 @@ + + + + + diff --git a/src/views/MyMatches.vue b/src/views/MyMatches.vue new file mode 100644 index 0000000..8a359e2 --- /dev/null +++ b/src/views/MyMatches.vue @@ -0,0 +1,12 @@ + + + \ No newline at end of file diff --git a/src/views/Player.vue b/src/views/Player.vue new file mode 100644 index 0000000..29f60f1 --- /dev/null +++ b/src/views/Player.vue @@ -0,0 +1,317 @@ + + + + + \ No newline at end of file