861 Commits

Author SHA1 Message Date
David Vierra
208069beed Fix lag between moving mouse and view updating.
On mouse move, redraw view after calling view actions, not before.
2015-06-04 02:31:55 -10:00
David Vierra
65a17d93d9 Add a comment in geometry.py 2015-06-04 02:31:07 -10:00
David Vierra
8207d12570 Fix "jitter" when moving cursor across block edges.
Use the maximum depth buffer value when converting from a screen position to a 3D ray to increase precision.

Not sure why it wasn't the maximum before.
2015-06-04 02:30:47 -10:00
David Vierra
817d42b522 Add basic workplane control.
Only Y-axis right now. In the future, maybe a tool for creating one workplane for each axis?
2015-06-03 23:15:46 -10:00
David Vierra
4a54d0f5a4 Fix chunk loading origin not updating after changing dimensions
Offscreen views were being added to chunkLoader clients and controlling the load order...
2015-06-03 22:51:55 -10:00
David Vierra
0c897f397c Fix moving left/right while looking down being very slow.
Needed to normalize the 'left' vector.
2015-06-03 21:17:13 -10:00
David Vierra
0d956c691d Add ParabolicDome brush shape 2015-06-02 20:27:32 -10:00
David Vierra
814a40b993 Brush's "Hover" option is now implemented.
TODO: Button to switch hover to half of object height, or half of object size along axis given by face under cursor
2015-06-02 20:27:21 -10:00
David Vierra
4e284e64c6 Rework brush shapes a bit
ShapedSelection -> ShapeFuncSelection
BrushShape now has createShapedSelection in addition to shapeFunc
createShapedSelection  is called instead of ShapeFuncSelection
createOptionsWidget added to BrushShape but not yet used...
Move shapeFuncs from mceditlib.selection to brush.shapes
Fix Diamond shape (recenters coordinates)
Remove Box shapeFunc - return box from createShapedSelection.
2015-06-02 15:26:43 -10:00
David Vierra
a0bac1c4a3 Add cylinder shape.
Todo: axis setting
2015-06-02 13:57:37 -10:00
David Vierra
b511ce945a Fix bug in modelmesh causing negative y coordinates to roll over 2015-06-01 23:01:22 -10:00
David Vierra
b12d4ff50e Rework createSelectionMask
Move createSelectionMask into ShapedSelection.box_mask
Remove "hollow" and "chance" args - use composed selections for this instead
Don't recenter coordinates in box_mask
Recenter coordinates in SphereShape instead
DiamondShape is now broken.
2015-06-01 22:51:37 -10:00
David Vierra
563559732f xxx show wireframe box around brush cursor 2015-06-01 15:45:19 -10:00
David Vierra
251c999742 Allow brush shapes to have no icon. 2015-06-01 15:42:59 -10:00
David Vierra
49e55338e4 Add some comments and notes 2015-06-01 15:41:02 -10:00
David Vierra
8500d6a2f0 Main chunk loading timer can now idle again.
ChunkLoader.next now reraises StopIteration to signal caller that all chunks are loaded.
2015-05-31 18:49:32 -10:00
David Vierra
b482e8d952 Pull masklevel.py, modes.py, shapes.py out of brush/__init__.py
Move shapes out of shapewidget.py, too.
2015-05-31 18:04:09 -10:00
David Vierra
b420e29613 Add Alek to supporters list 2015-05-31 14:59:21 -10:00
David Vierra
c53528c10a Minimap viewing outline now uses a ray cast to determine the height at which to slice the frustum.
The outline now grows and shrinks according to how far away the object in the center of the screen is.
2015-05-30 21:13:40 -10:00
David Vierra
3772d5dfb3 Fix minimap's viewing area outline.
Check for intersection with eight of the frustum's edges, not just four.
2015-05-30 21:08:26 -10:00
David Vierra
c5836353c6 Use exhaust() in some preview loaders to exhaust iterators. 2015-05-29 11:41:35 -10:00
David Vierra
d74ebcf932 Add progress bars to world save and undo revision close.
Tempted to write a progress manager type class the next time this comes up.

Progress counts are a little bit off.
2015-05-29 11:41:02 -10:00
David Vierra
3861f7f5d2 Add __len__ to lru_cache_object 2015-05-29 11:25:55 -10:00
David Vierra
d1a51ecef4 Region repair: Don't put overlapping chunks in lost and found.
They are probably unreadable anyway.
2015-05-29 11:18:29 -10:00
David Vierra
4deae441a7 Fix AttributeError in RegionFile.repair after renaming writeChunk to writeChunkBytes 2015-05-27 10:13:30 -10:00
David Vierra
51babcd9f4 Change assert VERSION_ANVIL to a LevelFormatError
LFE can be caught by world list, etc. Having it as an assert just caused the app to exit.
2015-05-27 09:21:58 -10:00
David Vierra
ac856a0581 Fix crash when switching back to Koch Snowflake plugin
Options widget was being recreated. When the previous widget is deleted, it deletes all of its children, including self.iterationsSlider.

Maybe make sure getOptionsWidget is only called once and cache its result in GeneratePlugin
2015-05-25 05:39:00 -10:00
David Vierra
1045da3556 Remove debug print from mcedit2.spec 2015-05-24 08:55:40 -10:00
David Vierra
2244705dfc Correctly remove pluginModule from sys.modules, as it is a dict and not a list. 2015-05-24 08:01:11 -10:00
David Vierra
87c6f45017 Close session panels before setting worldEditor to None
Panels expect worldEditor to not be None and this was spamming exceptions from one of the list models.
2015-05-24 08:00:52 -10:00
David Vierra
9d7adf134e EditorSession.WorldInfoPanel -> worldInfoPanel
oops...
2015-05-24 07:58:37 -10:00
David Vierra
9496914e9a Add every pyfile under src/mcedit2 and src/mceditlib to the pyi build.
This brings in synth.l_system even though it isn't imported, and brings in anything else that's only provided for plugins and isn't found by modulefinder.
2015-05-24 06:01:27 -10:00
David Vierra
6a8d95b3a6 Move run_regression_test.py into mceditlib/test 2015-05-24 05:40:22 -10:00
David Vierra
72c85ef125 Remove unused mcedit2/util/scanmodules.py 2015-05-24 05:37:31 -10:00
David Vierra
9599097772 Remove unused mcedit2/util/geometry.py 2015-05-24 05:37:03 -10:00
David Vierra
bed69d95b4 Remove unused files in mcedit2/prefs 2015-05-24 05:36:21 -10:00
David Vierra
3d536c6d47 Remove __init__.py from mcedit2/ui (not a package) 2015-05-24 05:34:42 -10:00
David Vierra
519b21329a GenerateTool doesn't call boundsChanged if no currentGenerator 2015-05-24 04:45:55 -10:00
David Vierra
15cb5e03d7 Update guidelines with new error log locations 2015-05-24 04:26:10 -10:00
David Vierra
580af9bc18 Add a note about not reading the guidelines to the issue guidelines. 2015-05-24 04:23:45 -10:00
David Vierra
2438efdbd0 Use a more sensible default view distance 2015-05-24 04:23:22 -10:00
David Vierra
23fe46ca7b Koch Snowflake plugin now uses boundsChanged to limit the max iterations, and uses glColor to color the lines 2015-05-24 03:55:40 -10:00
David Vierra
11ac62fa24 Line's GL color can now be specified 2015-05-24 03:55:06 -10:00
David Vierra
60b13618f5 Add a boundsChanged method to GeneratePlugin 2015-05-24 03:54:51 -10:00
David Vierra
cc06555d5c Actually reselect the previous generator plugin after it was reloaded. 2015-05-24 03:54:37 -10:00
David Vierra
f78039f1fd Need to use iteritems to iterate registered classes 2015-05-24 03:10:28 -10:00
David Vierra
3a8453a47b Generate tool now responds to plugin classes being loaded and unloaded.
Adds/removes the plugin class to/from the generator type box
Chooses a different generator type when the current type is unloaded
Switches back to the unloaded generator type if the plugin is loaded again
2015-05-24 03:04:02 -10:00
David Vierra
dfa172e85e For automatic unregistration, key plugin classes by the module fullpath.
Can't key them by the module itself because once the module is loaded, classes may already be registered.

Also, checkTimestamps now returns the correct answer.
2015-05-24 01:33:35 -10:00
David Vierra
b5c8b41e1f When in developer mode, reload modified plugins when app is brought to foreground 2015-05-23 14:54:20 -10:00
David Vierra
d2cd7976e7 Add "Developer Mode" toggle to Options menu, remove -debug argument 2015-05-23 14:53:32 -10:00