Commit Graph

107 Commits

Author SHA1 Message Date
7a2a2d4ca6 Renamed some tests and changed amount tested. 2020-04-28 17:18:36 -05:00
b49f50f728 Increased chunk count to 6000. 2020-04-28 17:13:11 -05:00
61a6bbaa4f Cleaned up cache tests. 2020-04-28 17:12:36 -05:00
ca1e1c0975 Changed import to latest JUnit import. 2020-04-28 16:57:09 -05:00
b30d689183 Reworked thread safe cache solution.
Also performed refactoring.

And added some threaded tests.
2020-04-28 16:53:23 -05:00
7c073cdc6e Preventing flooder from checking same node.
Added another flooder test.
2020-04-27 23:17:54 -05:00
85ec44a4d7 Flood algorithm added and (basic) tests performed. 2020-04-27 21:10:55 -05:00
2a0f26f8bc Reworked operation order for DFS. 2020-04-27 20:35:32 -05:00
250334e348 Fixed cache locks as they were swapped.
Must've been real tired or something while writing that.
2020-04-27 17:06:10 -05:00
3675074d00 Tested generator system. 2020-04-27 16:06:01 -05:00
49f26f7901 Fixed conversion from world to chunk coords.
Added test that catches this case.
2020-04-27 15:14:33 -05:00
26ebf7af33 Fixed test case. 2020-04-27 14:25:10 -05:00
1e8dc8019a Current iteration of work.
Attempted at fixing the coordinate converter again.

Added more applicable tests for them.

Changing to a more stateless design for biome generator.

Refactored correcting package name to fit conventions.
2020-04-27 14:23:57 -05:00
59d78c9754 Fixed toString() format. 2020-04-27 13:58:39 -05:00
3efc6acf0b Fixed the utilities world to local non perfect positive case. 2020-04-27 13:53:29 -05:00
ec27a9bc10 Fixed perfect chunk coordinates in utilities.
Added respective tests to ensure this doesn't break.
2020-04-27 13:44:49 -05:00
39381f07f9 Fixed incorrect method call.
Added tests to make sure that this doesn't happen.
2020-04-27 13:21:04 -05:00
6ac686b86c Refactoring with different heavy changes to biome generator.
Attempt at making it my async compatible.
2020-04-26 23:07:25 -05:00
0886412cfb Point2 can now overrides toString(). 2020-04-26 20:56:44 -05:00
4f411c42fb Added conversion from world coordinates to utilities.
Respective tests also added.
2020-04-26 20:56:10 -05:00
16618ef439 Added chunk load listener. 2020-04-26 18:23:20 -05:00
b63c39b380 Changed biome cache to cache biomes instead of arrays. 2020-04-26 17:40:18 -05:00
df10a2c298 DFS can now take Point2 as parameters for its searches. 2020-04-26 17:28:57 -05:00
e8340bfc91 DFS's should now run locally on each thread. 2020-04-26 16:47:22 -05:00
faa2cfd79f Changed order of operations. 2020-04-26 16:29:03 -05:00
b492017ef2 Changed to using the constants. 2020-04-26 16:06:26 -05:00
ed4996ff9f Tuned cache values. 2020-04-26 16:05:52 -05:00
b769c83be1 Increased cache size. 2020-04-26 15:42:22 -05:00
2b05dfe4cc Changed to use of read and write locks in cache.
Also added specifics to constructor for the hash map.
2020-04-26 15:42:02 -05:00
02f7de56ed Minor changes to alternator. 2020-04-26 15:09:13 -05:00
60217e4672 World height shader should now be less abrupt. 2020-04-26 15:03:34 -05:00
925296f326 Minor improvement to cache by reducing area under lock. 2020-04-26 02:04:29 -05:00
98e4265db7 Attempted at making all things world gen thread proof.
Specifically, caching is tested thread proof.
2020-04-26 01:28:45 -05:00
f20515fd45 Reworked cache, this time with less hashmap accesses. 2020-04-25 22:32:25 -05:00
dcec9fd7e7 Made sure occurrences are properly tracked. 2020-04-25 18:16:18 -05:00
4b6cfacc47 Fixed clear cache method.
Alternator currently uses threads as identifier (TEMPORARY).
2020-04-25 17:59:30 -05:00
1e0d63e562 Added a magnitiude addition helper function. 2020-04-25 17:54:40 -05:00
629660c8fc Revamped caching again, this time, without sorting.
Implemented cache changes.
2020-04-25 17:54:25 -05:00
91644f9ba0 New cache system.
Caching itself is tested.

Implemented into classes (untested).
2020-04-25 12:06:41 -05:00
1c5baf8762 Removed unnessecary hashmap retrieval from cache. 2020-04-25 02:23:48 -05:00
a7db7d289a Caching now has a fresh importance factor. 2020-04-25 01:32:01 -05:00
28b9a8005c Gave newly cached items usage greater than the lowest. 2020-04-25 01:15:38 -05:00
a412986044 New iteration of biome generator.
Untested.
2020-04-25 00:18:53 -05:00
e93f61c055 Added convenience constructor. 2020-04-25 00:18:29 -05:00
34ccc1e7de Semi-functioning biome generator.
It's faster now, but sometimes hangs, and is still pretty slow.
2020-04-24 22:11:52 -05:00
d0facd268a Fixed world generator not saving generated values. 2020-04-24 22:10:59 -05:00
c5e3c08546 Refactoring. 2020-04-24 17:50:18 -05:00
8517a20f9f Reworked biome per island generator. 2020-04-24 15:15:44 -05:00
60ab555c57 Added caching solution to temperature map generator. 2020-04-24 15:15:44 -05:00
6c8389d60e Lowered amount of octaves. 2020-04-24 15:15:44 -05:00