Commit graph

43 commits

Author SHA1 Message Date
Joscha
aca387cf05 Save chunks in db
One of the changes introduced for this is that multiple chunks and
diffs are now represented by dicts, not lists.
2017-04-16 17:02:32 +00:00
Joscha
9e5b5f874a Start work on server-side saving worlds
This commit includes a a few more changes because I'm too lazy to
clean them up:
 - fix chunk modification times
 - improve command line arguments
 - load multiple chunks at once
2017-04-16 13:52:39 +00:00
Joscha
e7f85ff421 Show normal chunks in the visible part of the chunkmap 2017-04-15 22:09:32 +00:00
Joscha
9974c09852 Append logs instead of overwriting old logs 2017-04-15 22:08:59 +00:00
Joscha
e039005877 Add additional key codes for ctrl+arrow combinations 2017-04-15 22:00:49 +00:00
Joscha
18ac634579 Use some of curses' key codes 2017-04-15 21:41:05 +00:00
Joscha
63f879690b Remove accidentally-left-in code for debugging 2017-04-15 21:21:03 +00:00
Joscha
cc31ed6be9 Save changes to logfile if supplied with logfile name 2017-04-15 21:19:07 +00:00
Joscha
4822cab0fc Update chunk logic
Correctly store time of last modification
Use "load" to get a chunk (or load/create one if it isn't loaded)
2017-04-15 11:59:58 +00:00
Joscha
d68d32ff2f Rename "changes" to "diffs" in most places 2017-04-14 11:09:50 +00:00
Joscha
3cb21c02bc Reverse illegitimate changes on server 2017-04-14 09:41:02 +00:00
Joscha
54e09d18cc Adjust chunk caching values 2017-04-14 08:58:22 +00:00
Joscha
58dc82b1d9 Clean up comments 2017-04-14 08:49:55 +00:00
Joscha
243333f4ef Remove debugging messages 2017-04-14 08:42:14 +00:00
Joscha
7a3bf578bc Clean up client code 2017-04-14 08:36:32 +00:00
Joscha
4d81dea41c Add command line parameter support to server 2017-04-14 08:33:11 +00:00
Joscha
7bec555e3b Clean up server code 2017-04-14 08:22:01 +00:00
Joscha
841adfa28f Log connects and disconnects with a little box drawing art 2017-04-14 07:32:51 +00:00
Garmelon
cc0b22cb82 Create License.txt 2017-04-13 21:13:45 +00:00
Joscha
39b0ceee7c Allow for more unicode input 2017-04-13 21:04:26 +00:00
Joscha
04f0b8d9d7 Fix server-side disconnect bug 2017-04-13 21:04:09 +00:00
Joscha
320dd16889 Add server
This is a first try at connecting multiple clients using a server.
The commit includes a lot of debugging messages.
I will hopefully clean up the server and some of the client code.
2017-04-13 18:10:37 +00:00
Joscha
63410fd99e Add web socker server module 2017-04-12 22:09:52 +00:00
Joscha
8c5d5bc2cb Add alternating color mode (F3) 2017-04-10 16:08:12 +00:00
Joscha
e3b599eee1 Handle saving changes separate from cleaning up 2017-04-10 00:04:22 +00:00
Joscha
23da1ea5d9 Implement parts of clientchunkpool and fix softlock in the process 2017-04-09 10:37:57 +00:00
Joscha
c5af7c2480 Unload chunks that fall outside a certain radius 2017-04-08 17:05:09 +00:00
Joscha
c364faf8ff Clean up ChunkPool 2017-04-08 15:48:14 +00:00
Joscha
72cb273849 Remove debugging messages 2017-04-08 15:47:47 +00:00
Joscha
37b5ba162c Ignore normal input besides scrolling when ChunkMap is displayed 2017-04-07 19:39:45 +00:00
Joscha
68c50f894b Add ChunkMap for better debugging 2017-04-07 19:35:05 +00:00
Joscha
42d72422c6 Move down one line when enter is pressed, use ESC to quit 2017-04-06 22:11:39 +00:00
Joscha
704ff9b3d1 Delete characters with backspace 2017-04-06 13:08:18 +00:00
Joscha
38ab48d6f8 Add ability to write on map
Todo:
 - make ChunkDiffs contain deletions
 - inserting a " " counts as deletion on chunk level
 - allow for more unicode characters! ^^ (only harmless ones though - no newline or control characters etc.)
2017-04-06 12:53:20 +00:00
Joscha
7b5458e1d5 Redraw map on key press 2017-04-06 07:35:59 +00:00
Joscha
9f02d63a7d Edit chunks when character is written to map 2017-04-06 07:31:47 +00:00
Joscha
5b4a6a4a83 Add input thread and some map keybindings 2017-04-06 07:20:28 +00:00
Joscha
11a94f982d Implement map scrolling 2017-04-06 07:20:28 +00:00
Joscha
538ea58925 Enable drawing white background instead of . 2017-04-05 19:46:50 +00:00
Joscha
8ea614e22d Add .gitignore 2017-04-05 19:44:43 +00:00
Joscha
7521d7b4ab Make map display empty squares 2017-04-05 19:44:21 +00:00
Joscha
f5166319e1 Move ChunkDB to dbchunkpool.py 2017-04-04 20:24:27 +00:00
Joscha
59c3f6e34e Plan out project structure 2017-04-04 20:20:48 +00:00