Andrew Chin
2e34507568
Use FileReplacer to manage the uuid cache file
2016-02-01 09:32:35 -05:00
Andrew Chin
270741eb8f
genpoi UUID improvements
...
* When reading the cache, catch some errors on load, instead of crashing
* When writing to cache, write to tmp file, then move it into place.
This should be more robust if a ctrl+c is recieved while writing the
cache
Addresses #1266
2015-12-27 14:59:03 -05:00
Andrew Chin
0ba0c60ed2
Catch TypeErrors as well when loading player dat files
2015-10-06 17:38:49 -04:00
Andrew Chin
afc1c4f924
Don't call save_cache if running with --skip-players
2015-08-14 08:47:52 -04:00
Mark Fickett
f839068f27
Convert filter generator to list before passing to handleEntities to fix repeated iteration. Fixes #1220 .
2015-03-18 23:33:54 -04:00
Aaron Griffith
4a9d808bb2
Merge pull request #1219 from MasterofJOKers/player_poi_fix
...
[genPOI] Fix generation of multiple players
2015-03-12 13:00:24 -04:00
Aaron Griffith
0c7441f93d
equality != assignment...
2015-03-12 12:25:41 -04:00
Aaron Griffith
88de7b1567
get genpoi multiprocessing working on windows
2015-03-12 12:21:39 -04:00
MasterofJOKers
803d8d7933
[genPOI] sort list of imports
...
Easier to see if an import is already there.
2015-03-12 15:56:48 +01:00
MasterofJOKers
adcf105778
[genPOI] fix generation of multiple players
...
The same problem as in bd8f3577 is also present for players. The filters
were given as iterator, but iterated through once per player.
2015-03-12 15:54:48 +01:00
MasterofJOKers
5764183e00
[genPOI] remove unnecessary second import of json
2015-03-09 09:37:10 +01:00
MasterofJOKers
bd8f357787
[genPOI] pass filters as list to handleManualPOI
...
It was accidently passed as an iterator, so it was only iterable once,
which lead to only the first manual poi being displayed.
2015-03-09 09:34:44 +01:00
Nicolas F
b35f848855
[genPOI] Work around utter plebbery
2015-03-08 17:03:43 +01:00
Nicolas F
b5ecf8a7f4
[genPOI] Work around JSON signs
...
lol Mojang
2015-03-07 18:16:32 +01:00
Jamie Bliss
3cd2afb0c4
genPOI: don't ignore invalid polyline point
...
There is no point in ignoring an invalid point, because without an error
message the user might wonder, why it's poyline doesn't look the way it
should.
2015-02-23 21:39:03 +01:00
Jamie Bliss
7229fcc3df
genPOI: use more pythonic ways ...
...
One should use isinstance instead of `type(A) ==` because of
inheritance.
There should be an exception if a list of `elif`s don't match.
Make Polyline not only accept tuples, but any iterable.
2015-02-23 21:39:03 +01:00
Jamie Bliss
b08e34b064
genPOI: add icon and createInfoWindow support for filters
...
The defaults for "icon" and "createInfoWindow" are read from the POI,
but can be overridden by a filter function returning an appripriate
dict.
2015-02-23 21:19:17 +01:00
MasterofJOKers
4b9d0a5c87
Merge branch 'master' into my_genpoi
...
Conflicts:
overviewer_core/aux_files/genPOI.py
2015-02-08 14:19:21 +01:00
Gizmokid2005
77c4d24660
Skip missing dimensions in genPOI
...
This fixes overviewer/Minecraft-Overviewer #1202 for genPOI renders.
2015-02-05 13:54:01 -05:00
Koza
f1af25799e
Fixed rendering regions. genPOI.py: add new line to baseMakers.js; views.js: add polygons, with all the features that Google provides, polylines work fine; regions.js: example of usage
2014-12-13 17:17:11 +01:00
MasterofJOKers
9cbeffc721
Merge branch 'master' into my_genpoi
2014-10-30 12:47:55 +01:00
MasterofJOKers
9d1eb35643
Merge branch 'master' into my_genpoi
...
This just updates the code to the current master, so it can be merged
easily.
Conflicts:
overviewer_core/aux_files/genPOI.py
2014-10-28 22:15:58 +01:00
Nicolas F
dfe6f08ee9
genPOI: Resolve UUIDs for player spawns too
2014-10-24 13:57:06 +02:00
Andrew Chin
322922b8e6
Implement a UUID lookup cache, to avoid hitting the mojang server so much
...
The cache is a gzip'd JSON file. Soon we will have a small script to
help manage the cache
See #1090 and #1117
2014-08-19 22:08:15 -04:00
Andrew Chin
59d277a131
Change ctime to localtime.
...
See discussion in #1082
2014-08-19 21:28:25 -04:00
Andrew Chin
8257220657
Merge PR# 1082
2014-08-19 21:17:57 -04:00
MasterofJOKers
2271f628ef
genPOI: use filter functions on the fly
...
Instead of reading all Players and especially Entities and TileEntities
into RAM and than applying the filter functions onto them, filter
functions are used after each parsed chunk to get only the markers of
this chunk and not all Entities.
This reduced the RAM usage dramatically:
On a 233 MB map over 200 MB of RAM was used before.
Using these changes (and only having two filter functions for signs) not
more than 36 MB of RAM was used.
2014-08-03 23:26:23 +02:00
MasterofJOKers
eccad401ca
genPOI: generate marker's internal name only once
...
Why should it be duplicated anyway?
2014-08-03 23:26:23 +02:00
MasterofJOKers
e2b6474b28
genPOI: use a defaultdict for markers
...
This is a little faster and make the code a little shorter.
2014-08-03 23:26:23 +02:00
MasterofJOKers
6c14d47650
genPOI: unite for-loops with itertools
...
Since all the POIs are created from different lists, multiple for loops
were used. With itertools.chain these lists can be looped over with only
one for loop thus removing doubled code.
2014-08-03 23:26:23 +02:00
MasterofJOKers
d7aa4fd4c2
genPOI: function for doubled code for marker creation
...
The code creating the actual marker dict out of the entity and the
result of the filter function was almost the same for every set of
entities. Thus it is now a function.
2014-08-03 23:26:23 +02:00
MasterofJOKers
61339b1c42
genPOI: add option --skip-players
...
If one simply wants to add some manual POIs, no player files have to be
parsed.
2014-08-03 23:26:23 +02:00
Nicolas F
792b049dd5
FIx genPOI dimension parsing
...
Fixes Issue #1130
2014-07-18 20:08:34 +02:00
Nicolas F.
a77f4aa5f4
Fix warning for unresolvable UUID
...
Exception while catching an exception. Try to make an inception joke of that.
2014-06-20 19:53:34 +02:00
Nicolas F
8053eaca72
Lazily get names from UUIDs
...
Instead of doing the UUID->name resolution for all players in every
case, only do it when EntityId is accessed and the name hasn't been
retrieved this run already. This makes genPOI usable for people who
have many players on their servers but don't wish to use player POI
while still using other genPOI features.
To do this, a PlayerDict has been created, which contains a dirty
hack to see if the requested item is EntityId and whether it hasn't
been set already.
2014-05-30 10:16:28 +02:00
Andrew Chin
8e5944d5c3
Catch some additional UUID lookup errors from urllib2
2014-04-10 19:52:50 -04:00
kiyote
a5b7c9617f
Added ['time'] attribute to Players POI
...
It's nice that we can see where a player was at logout, but now we can see when that logout was.
2014-03-29 09:17:59 -05:00
Luc Ritchie
0e1bd4369a
Use Mojang's session API to get usernames from UUIDs
2014-03-09 16:23:32 -04:00
Luc Ritchie
1cf131a8fc
Handle UUID player files semi-nicely in POIgen (14w10a+, 1.7.6+)
2014-03-09 00:56:27 -05:00
Andrew Chin
d68c792c41
Allow --genpoi to use -c to specify a config file
...
Closes #1033
2013-12-26 23:45:07 -05:00
Aaron Griffith
1a1022fa2f
multiprocessing-based POI generator no longer crashes on python 2.6
...
fixes Issue #1041
2013-12-24 12:10:05 -05:00
Andrew Chin
cc4261aea5
Ignore corrupt chunks from .get_chunks() in genpoi
...
See #1038
2013-12-13 20:34:54 -05:00
Aaron Griffith
df732bfa25
Revert "Merge remote-tracking branch 'exhuma/master', PR #963 "
...
This reverts commit e26727943f , reversing
changes made to 7bbb077704 .
2013-12-02 07:40:00 -05:00
Aaron Griffith
a8a2a191b8
Revert "used LOG instead of logging on a few stragglers"
...
This reverts commit 144cff18e3 .
2013-12-02 07:35:10 -05:00
Aaron Griffith
144cff18e3
used LOG instead of logging on a few stragglers
2013-12-01 16:39:45 -05:00
Aaron Griffith
e26727943f
Merge remote-tracking branch 'exhuma/master', PR #963
...
Conflicts:
overviewer.py
overviewer_core/aux_files/genPOI.py
overviewer_core/textures.py
2013-12-01 16:35:28 -05:00
Aaron Griffith
af3554b18a
Merge remote-tracking branch 'pibm/poi_changes', PR #999
...
Conflicts:
overviewer_core/aux_files/genPOI.py
2013-12-01 16:26:51 -05:00
Steven Dwy
366e6db8e3
Fix #993
2013-10-29 12:47:05 -07:00
Patrick-Emmanuel Boulanger-Nadeau
55f7183c4d
Cleanup even more
2013-10-01 13:13:14 -04:00
Patrick-Emmanuel Boulanger-Nadeau
f90b1ae6a4
Update the genPOI to uses multiple processes
2013-09-30 18:07:02 -04:00