Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Local storage and Activity test #19

Open
wants to merge 5 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 13 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,20 @@
# Upcoming

# 0.6.0
* Include advanced tactics in calculated attack and defense bonus
* Show tooltips for resources in plunder screen in local (server) language ([#12](https://github.com/veger/foei/issues/12))
* Use localized names for the units ([#12](https://github.com/veger/foei/issues/12))
* Use localized names for the buildings ([#12](https://github.com/veger/foei/issues/12))
* Show unit images instead of unit names
* Make (previous) battle information closable

# 0.5.0
* The Crow's Nest cannot be plundered
* Show 'not available' or 'closed' if the last change info of a GB is not available ([#10](https://github.com/veger/foei/issues/10))
* Show if battle was 'automatic'
* Sort GvG units for clarity
* Show images of goods in plunder tab ([#13](https://github.com/veger/foei/issues/13) thanks djmichaelsaler)
* `last_spend` is not available, so resort to other means of tracking activity of other players ([#10](https://github.com/veger/foei/issues/10))
* More building and unit IDs

# 0.4.0
* Add GvG tab (showing sector army details)
Expand Down
6 changes: 3 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ Nonetheless, I take no responsibility for lost accounts or any other loss that m
FoEI has been tested by a select few players for a couple of months running on different servers, showing it works and it is great aid.
Now it is time to present it to the public and polish it some more:

* I made some quick & dirty UI...
* Lacking much experience I also made a quick & dirty Javascript implementation
* ~~I made some quick & dirty UI...~~ I like it good enough
* ~~Lacking much experience I also made a quick & dirty Javascript implementation~~ Meh... it works, who casres :stuck_out_tongue:
* **Fix MacOS support**, for some reason intercepting the incoming traffic does not seem to work..?? (can people confirm/deny in [issue #7](https://github.com/veger/foei/issues/7)?)
* more...

Expand All @@ -50,6 +50,6 @@ I do this because of my personal interest/hobby, so my goal is not to make a pro

[![Donate with PayPal](https://www.paypalobjects.com/en_US/NL/i/btn/btn_donateCC_LG.gif)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=2EYSNR29PEPDC&source=url)

(Note that I cannot accept game diamonds directly, as I wish to be anonymous and not get banned.)
(Note that I cannot accept game diamonds, strategy points or any other donations in-game, as I wish to be anonymous and not get banned.)

On this notice, please don't bother players with a same/similar (account)name to ask questions or support, it is not me :stuck_out_tongue:.
14 changes: 12 additions & 2 deletions ajax_inspect.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,20 @@
}
}
if (jsonRequest || jsonResponse) {
let payload = { 'jsonRequest': jsonRequest, 'jsonResponse': jsonResponse }
let payload = { jsonRequest: jsonRequest, jsonResponse: jsonResponse, metadata: {} }
if (this._url.includes('forgeofempires.com')) {
let urlObj = new URL(this._url)
payload.hostname = urlObj.hostname
let match = RegExp('^[^\\.]*').exec(urlObj.hostname)
payload.metadata.type = 'game'
payload.metadata.world = match[0]
} else if (this._url.includes('metadata')) {
let match = RegExp('https://foe([^\\.]*).innogamescdn.com/start/metadata\\?id=([^-]*)-(.*)').exec(this._url)
if (match !== null) {
payload.metadata.type = 'meta'
payload.metadata.lang = match[1]
payload.metadata.id = match[2]
payload.metadata.hash = match[3]
}
}

chrome.runtime.sendMessage(extensionID, payload)
Expand Down
Loading