From 4ae2140178ca369a2e6fd84a4cc000adeb203ecc Mon Sep 17 00:00:00 2001 From: Alex Williams Date: Sun, 24 Nov 2024 18:51:22 +0000 Subject: [PATCH 1/4] Adding functionality to pull the 'description' field from specials and show a tooltip, describing what the special does. --- src/app/utils/BlueprintFunctions.js | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/src/app/utils/BlueprintFunctions.js b/src/app/utils/BlueprintFunctions.js index 03d62584..169acd2e 100644 --- a/src/app/utils/BlueprintFunctions.js +++ b/src/app/utils/BlueprintFunctions.js @@ -12,6 +12,7 @@ import { STATS_FORMATTING } from '../shipyard/StatsFormatting'; * @returns {Object} The react components */ export function specialToolTip(translate, blueprint, grp, m, specialName) { + const description = []; const effects = []; if (!blueprint || !blueprint.features) { return undefined; @@ -19,6 +20,15 @@ export function specialToolTip(translate, blueprint, grp, m, specialName) { if (m) { // We also add in any benefits from specials that aren't covered above if (m.blueprint) { + if (specialName) { + if (Modifications.specials[specialName].description) { + description.push( +
+ {Modifications.specials[specialName].description} +
+ ); + } + } for (const feature in Modifications.modifierActions[specialName]) { // if (!blueprint.features[feature] && !m.mods.feature) { const featureDef = Modifications.modifications[feature]; @@ -53,6 +63,7 @@ export function specialToolTip(translate, blueprint, grp, m, specialName) { return (
+ {description} {effects} From 22b73b9b0cf51c4ee84159cc4ae5dab8da95157d Mon Sep 17 00:00:00 2001 From: Alex Williams Date: Sun, 24 Nov 2024 20:23:02 +0000 Subject: [PATCH 2/4] Updating the about page, removing erroneous link to edshipyard, adding current info, etc. --- src/app/pages/AboutPage.jsx | 29 ++++++++++++++++------------- 1 file changed, 16 insertions(+), 13 deletions(-) diff --git a/src/app/pages/AboutPage.jsx b/src/app/pages/AboutPage.jsx index b5a01afa..bf75a110 100644 --- a/src/app/pages/AboutPage.jsx +++ b/src/app/pages/AboutPage.jsx @@ -33,24 +33,27 @@ export default class AboutPage extends Page {

- This is a clone of the Coriolis project, whose original author is - currently unable to maintain it. This clone is maintained by the{' '} + This is now the only active version of the Coriolis project. The original author has handed over the maintenance of the project to the {' '} EDCD community.

+

Expectations

- To recover your builds, go to{' '} - - https://coriolis.io/ - - , backup your builds (Settings / Backup), copy the text, return here - and import (Settings / Import). + Although every attempt is made to update the data as soon as possible, following the release of new modules and ships, there may be a delay, of up-to a few days, before the data is available. Wherever possible, the current maintainers aim to keep this delay to a minimum. Please be aware that the project maintainers are volunteers and have real lives to attend to, so please be patient. If you would like to help with the maintenance of the project, please see the link to the EDCD Discord Server below, where you can get involved.

- The Coriolis project was inspired by{' '} - - E:D Shipyard - {' '} - and, of course,{' '} + There are, some missing modules from the time where the project was essentially not being maintained. These modules are gradually being added to the Coriolis database as and when the maintainers have the time to do so. +

+

+ Please check the {' '} Github Issues List for any specific modules you cannot find and see if there is an open request for them. If not, please feel free to open a new issue, however, please note that there is an existing issue open for the addition of pre-engineered modules, so please do not open a new issue for these. +

+

Donations

+

+ If you would like to donate to the project, in order to help with the costs of hosting and maintainence, please see the link to the {' '} + Current Maintainers version of the Git Repository and use the 'Sponsor' button at the top of the page. +

+

History

+

+ The Coriolis project was inspired by 'E:D Shipyard' (Now Defunct) and, of course,{' '} Elite Dangerous From 6a1eae8e9e81e64b7a78901bda093cc5e50de705 Mon Sep 17 00:00:00 2001 From: Alex Williams Date: Sun, 24 Nov 2024 21:35:33 +0000 Subject: [PATCH 3/4] Checks to see if the URL is over 2083 characters and if it is, presents this as the most likely error with an import. --- src/app/Coriolis.jsx | 10 ++++- src/app/pages/ErrorDetails.jsx | 73 ++++++++++++++++++++++++++++------ src/less/error.less | 6 +++ 3 files changed, 76 insertions(+), 13 deletions(-) diff --git a/src/app/Coriolis.jsx b/src/app/Coriolis.jsx index 4292d0ea..a6ac8075 100644 --- a/src/app/Coriolis.jsx +++ b/src/app/Coriolis.jsx @@ -123,7 +123,15 @@ export default class Coriolis extends React.Component { this._showModal(); } } catch (err) { - this._onError('Failed to import ship', r.path, 0, 0, err); + const fullUrl = window.location.href; + + if (fullUrl.length >= 2083) { + err = 'URL Length = ' + fullUrl.length; + this._onError('Failed to import ship - Potential URL Length issue', r.path, 0, 0, err); + } + else { + this._onError('Failed to import ship - Unknown Reason', r.path, 0, 0, err); + } } } diff --git a/src/app/pages/ErrorDetails.jsx b/src/app/pages/ErrorDetails.jsx index 4d96f93e..d6d8c8ef 100644 --- a/src/app/pages/ErrorDetails.jsx +++ b/src/app/pages/ErrorDetails.jsx @@ -33,7 +33,7 @@ export default class ErrorDetails extends React.Component {

Browser: {window.navigator.userAgent}
Path: {this.context.route.canonicalPath}
-
Error: {error.type || 'Unknown'}
+
Error: {ed["error"] || 'Unknown'}
Details:
{typeof ed == 'object' ? Object.keys(ed).map((e) => `${e}: ${ed[e]}\n`) : ed}
@@ -42,18 +42,67 @@ export default class ErrorDetails extends React.Component { const importerror = ed && ed.scriptUrl && ed.scriptUrl.indexOf('/import') != -1; - return
-

Jameson, we have a problem..

-

{error.message}

- Import Error handling has been improved, but still isn't perfect.
MOST Import failures are a result of missing modules in Coriolis,
OR incorrect import strings generated by third party apps. If you're seeing this page, we may have failed to handle the errors in your import correctly. Please see the data output below, specifically the 'scriptUrl:' section if it's there and then if you feel confident enough, please check the github issues page linked below and see if there is a similar issue already logged. If not, please create a new issue with the data below. If you're not confident, please ask for help on the Coriolis Channel of the EDCD Discord server. + if (ed['error'].match(/URL Length/i)) { + return
+

Jameson, we have a problem..

+

{error.message}

+ It looks as though you've encountered a URL Length issue for your browser. + +

+ + This is a known issue with Internet Explorer and Edge, as well as Google Chrome, all of which only support 2083 characters and your URL is: + +

+ + {ed["error"]} characters. + +

+ + Please try using another browser first, before reporting an issue, such as Firefox which supports 65,536 characters or Safari, which supports 80,000 characters. + +

+ + Don't copy the URL from Explorer, Edge or Chrome, as they will have truncated it and the data string will be incorrect. You'll need to change your default browser settings, so that when you click the link, it opens in the browser you want to use. +

+ If you're already using Firefox, which supports up to 65,536 characters or Safari, which supports up to 80,000 characters, please see the data output below. +

+

Data Output

+ {content} +
; + } + else { + return
+

Jameson, we have a problem..

+

{error.message}

+ Import Error handling has been improved, but still isn't perfect. + +

+ + If you're seeing this page, we may have failed to handle the errors in your import correctly. Please check the common import failures list and then the data output below, specifically the 'scriptUrl:' section if it's there and then if you feel confident enough, please check the github issues page linked below and see if there is a similar issue already logged. If not, please create a new issue with the data below. If you're not confident, please ask for help on the Coriolis Channel of the EDCD Discord server. + +

+

Common Import Failures

+ +
    +
  • + Previously, most failures were a result of missing modules in Coriolis, although this is rarer now since the import system was improved. If you're using a module in game and you know it isn't in Coriolis, this could be the problem, please check the data output section below. +
  • +
  • + Incorrect import strings generated by third party apps do still occur, please check the data output below and if the import was from something like EDMC, please check you're using the latest version. +
  • +
  • + You've hit a 'maximum URL Length' for your browser. This is a known issue with Internet Explorer and Edge, as well as Google Chrome, all of which only support 2083 characters. Please try using another browser first, before reporting an issue, such as Firefox which supports 65,536 characters or Safari, which supports 80,000 characters. Don't copy the URL from Explorer, Edge or Chrome, as they will have truncated it and the data string will be incorrect. You'll need to change your default browser settings, so that when you click the link, it opens in the browser you want to use. +
  • +
  • + {importerror ?
    If you are attempting to import a ship from EDDI or EDMC and are seeing a 'Z_BUF_ERROR' it means that the URL has not been understood correctly by the browser. This is a common problem when using Microsoft Internet Explorer or Microsoft Edge, and you should use another browser instead.
    : null } +
  • +

+
Please note that this site uses Google Analytics to track performance and usage. If you are blocking cookies, for example using Ghostery, please disable blocking for this site and try again.

-
- {importerror ?
If you are attempting to import a ship from EDDI or EDMC and are seeing a 'Z_BUF_ERROR' it means that the URL has not been provided correctly. This is a common problem when using Microsoft Internet Explorer or Microsoft Edge, and you should use another browser instead.
: null } -
-
Please note that this site uses Google Analytics to track performance and usage. If you are blocking cookies, for example using Ghostery, please disable blocking for this site and try again.
-
- {content} -
; +

Data Output

+ {content} +
; + } } } diff --git a/src/less/error.less b/src/less/error.less index 82b1b9a1..90522609 100755 --- a/src/less/error.less +++ b/src/less/error.less @@ -9,6 +9,12 @@ } } +ul { + padding: 0; + margin: 0; + text-align: left; +} + pre { white-space: pre-wrap; white-space: -moz-pre-wrap; From b365faed0ac1861edefe737207b683641145f666 Mon Sep 17 00:00:00 2001 From: Alex Williams Date: Sun, 24 Nov 2024 23:53:15 +0000 Subject: [PATCH 4/4] Adding 'charge' time into calculation of RoF, as RailGuns have a 'charge' time as well as a reload time. --- src/app/shipyard/Module.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/app/shipyard/Module.js b/src/app/shipyard/Module.js index 7df7f44e..4559f54b 100755 --- a/src/app/shipyard/Module.js +++ b/src/app/shipyard/Module.js @@ -927,8 +927,9 @@ export default class Module { const burst = this.get('burst', modified) || 1; const burstRoF = this.get('burstrof', modified) || 1; const intRoF = this.get('rof', modified); + const charge = this.get('charge', modified) || 0; - return burst / (((burst - 1) / burstRoF) + 1 / intRoF); + return burst / (((burst - 1) / burstRoF) + 1 / intRoF + charge); } /**