Commit Graph

71 Commits

Author SHA1 Message Date
philippe lhardy
338dc3dd6b add a .xpm file as background / first TEST /
- add a special cat image in background
- now ready for a pixel art phase ...
- very quick&dirty implementation of xpm parser...

- xpm generated with gimp using posterize. Thanks gimp !
2020-12-13 22:44:09 +01:00
philippe lhardy
56585712c8 prepare for some colors - greyed background
- background is not greyed depending on surrouding walls
- MazeColorMap to prepare for color edition
2020-12-13 18:05:02 +01:00
philippe lhardy
9b4f035d0f GUI separate layer from resize control, and import osm default zoom
- use a bigger zoom for import since export in worldeidt will use meter as cubic size
- separate resize from layer control
  - no need to specify BorderLayout.XXX for BoxLayout.
2020-12-12 12:17:06 +01:00
philippe lhardy
71a1715094 osm import (long,lat) <-> (x,y)
- previously was (long,lat) <-> (y,x), this one makes more sens
2020-12-12 12:13:46 +01:00
philippe lhardy
99d9aeb242 add weird obfuscated code for fun 2020-12-12 12:12:26 +01:00
philippe lhardy
3ff4a22045 cleanup not used 2020-12-12 12:11:45 +01:00
philippe lhardy
81441d7f17 Add reverse that allow to switch interior/exterior of a labyrinth
- invert create a new labyrinth walls are path of previous.
  - grow then new labrynth is bigger, else shrink.
2020-12-09 23:02:29 +01:00
philippe lhardy
6c9800047c load .we with layers
- and fix some bug : max is within range ( perhaps not as many as those added ...)
- quick hack in CharProvider to skip spaces ... ( bad it applies to strings too ...)
2020-11-05 21:31:28 +01:00
philippe lhardy
bf918333bf wall half closure control + layers
- add onewaywall option to create a wall if there is not step back
- add layers of maze
- load minetest scheme .we with onewall option
2020-11-05 19:50:42 +01:00
philippe lhardy
52a2d3f1e3 read a .we minetest schema
- use ground has maze walls
2020-11-04 22:12:17 +01:00
philippe lhardy
6402766371 wrap lua object into java object
- to ease handling wrap lua object to java object
2020-11-04 13:39:04 +01:00
philippe lhardy
9355fd8b6d WIP minetest <-> laby import/export
- currently possible to export a laby into minetest
- start of a lua content parser to import .we into lab
2020-11-03 23:21:29 +01:00
philippe lhardy
41067707bc generate .we maze
- export maze as .we ( still hlf boundaries missing )
2020-11-03 17:49:58 +01:00
philippe lhardy
8211147b28 minetest worledit .we format export
- harcoded generation of lua content of .we export
- export something, but not yet correct ( walls are points ... )
2020-11-03 17:33:25 +01:00
philippe lhardy
94b4a0ce66 read osm format longitude and latitude bounds, separate ways and buildings
- read longitude and lattude boundaries
- separate ways ( open ways ) from buildings ( closed )
- save as .imc and .drawing ( raw format ) [ since .imc seems buggy )
- read uncompressed drawing format
2020-11-01 12:44:05 +01:00
philippe lhardy
8af19bdb59 first .osm format import
- import osm convert it to Drawing and use it as resolved path.
- Not ready , first test over lab/valbonne_oct_2020.osm
2020-10-31 15:44:23 +01:00
philippe lhardy
99716e57d3 don't redrawn each cell when loading and by redraw at end
- hide status update
- don't redraw each point during file loading
2020-10-21 14:03:25 +02:00
philippe lhardy
3690482728 add drawing imc import as a path that will be openned in maze
- importing an imc will create a open path folowwing the given drawing
( very slow due to addStatus string notification ? )
2020-10-20 10:24:08 +02:00
philippe lhardy
1a7e64c139 When drawing a path within maze, restart a newline after 200ms delay
- 200 ms is hardcoded for gragTimeout
- when drawing a line and wanting to start a new line, it is enough to wait dragDelay wihout move
2020-10-19 21:58:05 +02:00
philippe lhardy
c69d068caf add Save Text support and rework package
- move maze within package maze
2020-10-17 21:08:16 +02:00
philippe lhardy
c3410838e1 Merge branch 'pi' of www4.artisanlogiciel.net:artisanlogiciel/code/laby 2020-10-17 13:01:57 +02:00
philippe lhardy
dae5e763e9 add a slider to set maze width/height
- from 1 to 100.
2020-10-16 10:55:32 +02:00
philippe lhardy
8376aabaf0 Merge branch 'pi' of 192.168.1.28:artisanlogiciel/code/laby
# Conflicts:
#	build.xml
#	mybuild.xml
2020-10-15 17:33:19 +02:00
philippe lhardy
6dfcea5647 add load menu and a status line
- don't print to console but add a status line
- add a load menu to load raw
2020-10-14 22:21:46 +02:00
philippe lhardy
046a7767a8 Settings for stl export
- set cells size and wall thickness
- set reverse for path :
  when reverse is set then resolved path is higher ground
  else (default) it is lower ground.
2020-10-13 16:49:00 +02:00
philippe lhardy
f07767dcfd fix normals for vertices
- now stl output can be porcessed directly by slic3r without intermediate fix wihtin blender
- created Wall3dStream instead of keeping all within Wall3d
- can save only stl output ( 'Save stl' )
2020-10-11 22:14:10 +02:00
philippe lhardy
0f1a15916c move Display in gui package
- and some code indentation
2020-10-11 15:30:28 +02:00
philippe lhardy
9ec3cf0d01 display seed, create subpackage
- display seed value ( can't be set yet )
- move MazeSetting in gui sub package
2020-10-11 15:07:39 +02:00
philippe lhardy
96c72506fb Add java.util.random seed as initial parameter
- prepare for short save allowing to fully recreate initial lab
having only seed and x,y,depth paramters
2020-10-11 12:44:22 +02:00
philippe lhardy
c26db0e3cb GUI change Save Menu and Create Button
- Save is now a menu and Create/Resolve/Quit buttons
2020-10-11 11:40:49 +02:00
philippe lhardy
fbe4a3e133 LabyModel limit public constructors to
LabyModel(MazeParams params, Random random)
and
 LabyModel(String pFormat, InputStream pIn)

fix unchecked and (java9) deprecated Short(short)
2018-06-14 22:49:39 +02:00
philippe lhardy
2d3f7b01a0 deepest end is really deepest 2018-06-13 20:56:12 +02:00
philippe lhardy
eb6760280f seems some files were missing 2018-03-04 21:46:02 +01:00
philippe lhardy
3cb922455a path is on a lower ground if maze was resolved. 2018-03-04 21:36:03 +01:00
philippe lhardy
8f1b6afee5 add a ground to labyrinth 2018-03-04 18:53:42 +01:00
philippe lhardy
4b324fc2f4 change GUI controls layout
group 'Bar' by activity
2017-12-13 22:10:24 +01:00
philippe lhardy
b2576735b0 Q&D fix Drawing generation ( see it with svg export ). 2017-12-13 08:01:32 +01:00
philippe lhardy
015719b9de add svg save 2017-12-12 22:43:01 +01:00
philippe lhardy
8ec6e2c2cd QnD support .imc saving
use external artgaphics-0.1.0.jar (part of sharedrawweb project )
savec .imc files
2017-12-08 22:10:56 +01:00
philippe lhardy
b360320570 QnD fix for drawing
( seen when joining cells touching only by one point )
2017-12-05 21:52:12 +01:00
philippe lhardy
c5d8503dbb resolved now support multiple path 2017-12-05 19:37:58 +01:00
philippe lhardy
b2c5bc0d97 resolve still to fix 2017-12-05 08:41:21 +01:00
philippe lhardy
a43e1e5a68 one step beyong in resolution, still not finding all alternate path
add showAll button
reset maze size display at maze size change
2017-12-04 22:34:34 +01:00
philippe lhardy
b5d27ed694 try to handle resolution of alternate path
=> to check SOLVED, might be set SOVLED while not fully tested.
2017-12-02 21:54:51 +01:00
philippe lhardy
52d244c758 keys are bound to maze display
and get focus when mous mouse over it
2017-12-02 19:18:17 +01:00
philippe lhardy
3222df4256 left button : open a path
right button : open only this path ( close other ways ).
2017-12-02 18:22:30 +01:00
philippe lhardy
cddbd5f2d6 add reset button + title
default to 20x20 maze
2017-12-02 17:56:59 +01:00
philippe lhardy
378569bc8c one step beyond laby edition
allow to draw pathes before generation
still not working
2017-12-02 17:33:35 +01:00
philippe lhardy
77a06c0061 draw path 2017-12-02 16:45:22 +01:00
philippe lhardy
7deeb203ff prepare for hand drawing with maze. 2017-12-01 22:20:33 +01:00