Sven Eberhardt
1f3e457ec2
Qt Editor: Fix enum child delegate value setting if a Set path is defined on the parent proplist
2016-07-23 01:40:51 -04:00
Sven Eberhardt
14d01cd5cd
Qt Editor: Add EmptyName option for def property to rename the "nil" entry
2016-07-22 00:28:01 -04:00
Sven Eberhardt
4fad947980
Qt Editor: Add Set function options SetGlobal and SetRoot
2016-07-21 00:24:53 -04:00
Lukas Werling
513d51384f
Fix nullptr -> bool conversion in return value
...
GCC does not like this, although both MSVC and clang accept it.
2016-07-19 17:21:23 +02:00
Sven Eberhardt
42e142b4d7
Qt Editor: Fix shape delegates as parameters to enum delegates
2016-07-18 19:24:53 -04:00
Sven Eberhardt
68358c0f87
Qt Editor: Improve display of object delegate
2016-07-14 00:45:18 -04:00
Sven Eberhardt
d605bab0be
Qt Editor: Move EditorActions from EditorAction_* to a proplist EditorAction.*
2016-07-14 00:17:53 -04:00
Sven Eberhardt
5a9e608f55
Qt Editor: Do not show properties of dead effects
2016-07-13 22:14:28 -04:00
Sven Eberhardt
59712bcea0
Qt Editor: Fix display of effect properties
2016-07-13 22:02:18 -04:00
Sven Eberhardt
28d2172b78
Qt Editor: Move editor props from EditorProp_* to an EditorProp proplist
2016-07-13 17:18:08 -04:00
Sven Eberhardt
dfb709df6b
Qt Editor: Do not reset value to default parameter when re-selecting an already selected index
2016-07-12 23:28:51 -04:00
Sven Eberhardt
3c84f9e6f8
Qt Editor: Fix evaluation of ValueKey in enum option when changing child delegate value
2016-07-12 22:29:24 -04:00
Sven Eberhardt
0206e9a74a
Qt Editor: Add HideInCreator DefCore setting
...
Hides internal definitions, libraries, etc. from the object creator in the editor.
2016-07-10 21:55:56 -04:00
Sven Eberhardt
85c5deb099
Qt Editor: Add option to auto-select objects created by an EditorAction
...
To be used by the dialogue so you can press a button on the clonk to add and immediately configure a dialogue.
2016-07-07 01:36:58 -04:00
Sven Eberhardt
990b6ea8f1
Qt Editor: Add option to descend directly into a subpath from array and sequence property delegates
2016-07-06 00:56:08 -04:00
Sven Eberhardt
8bc5e1911d
Qt Editor: When descending into array delegates, use the parent name as header.
2016-07-05 23:27:55 -04:00
Sven Eberhardt
343658db96
Fix MSVC build
...
Not sure why this builds elsewhere.
2016-07-05 22:54:19 -04:00
Sven Eberhardt
63c9bd78e7
Qt Editor: Fix crash and prop list/array display problems when switching prop lists.
...
Storing the pointer in QModelIndex could sometimes keep invalid memory on the persistent model indices. Because re-organizing these memory locations would be a nightmare and we only go two levels deep anyway, just store the parent index in the internal pointer and look up the actual property on the fly.
2016-07-05 22:53:41 -04:00
Sven Eberhardt
162a7cb331
Qt Editor: Resolve child delegates when evaluating proplist delegate display value
2016-07-04 13:21:31 -04:00
Sven Eberhardt
62c1f4bda5
Qt Editor: Add callback support for dynamic enum values in Enum delegates
2016-07-04 13:21:30 -04:00
Sven Eberhardt
cfca3be7e2
Qt Editor: Fix log output widget settings
...
Make text non-editable, etc.
2016-07-04 13:21:29 -04:00
Lukas Werling
8ab5d35550
Fix crash due to invalid QApplication arguments
...
It would trigger on Linux when opening menus.
2016-06-30 22:23:21 +02:00
Sven Eberhardt
ed368e128b
Qt Editor: Ensure duplicated objects are moved to the cursor without extra mouse movement
2016-06-22 01:46:13 -04:00
Sven Eberhardt
8158cbf87c
Qt Editor: Allow hotkey (F2) to duplicate selected objects.
...
Also reset cursor pos to center of duplicated objects to ensure they're on screen when duplicating by hotkey.
2016-06-22 01:04:14 -04:00
Sven Eberhardt
a7aa89f168
Merge branch 'master' into qteditor
...
Conflicts:
planet/Objects.ocd/Structures.ocd/StoneDoor.ocd/SpinWheel.ocd/Script.c
src/platform/C4WindowSDL.cpp
src/script/C4AulParse.cpp
src/script/C4Effect.cpp
2016-06-20 22:27:03 -04:00
Sven Eberhardt
9d9db0d9d5
Qt Editor: Fix grouped item selection in enum property delegate
2016-06-20 19:48:02 -04:00
Sven Eberhardt
e97491940f
Qt Editor: Fix possible crash if am object is deleted while the object selection delegate combo box is open
2016-06-20 19:13:50 -04:00
Sven Eberhardt
b6526d2f65
Qt Editor: Always duplicate contents with objects
...
Even if they are not selected, this is probably what the user expects.
2016-06-20 15:50:35 -04:00
Lukas Werling
b853f99b28
Fix -Wc++11-narrowing error in clang
2016-06-20 16:08:37 +02:00
Sven Eberhardt
44d94d5043
Improve editor duplicate function to duplicate properties and object connections.
...
It serializes objects using a selective SaveScenarioObjects script callback and then just executes the generated script. This automatically saves important properties, connects switches and doors, etc.
This change also solves the problem that duplicating an elevator plus case would create two elevator cases.
If execution fails (e.g. because of script errors or because a non-saveable object was duplicated), the method falls back to the legacy duplication method of creating objects with the same prototypes at the same position.
2016-06-20 01:45:26 -04:00
Sven Eberhardt
e7be7d6acd
Qt Editor: Add viewport context menu
2016-06-19 22:45:12 -04:00
Sven Eberhardt
34289fa18a
Qt Editor: Add EditorActions.
...
Replacing the old EditCursorCommands (which nobody knew). Objects now publish their commands directly on the property viewer.
2016-06-19 00:08:09 -04:00
Sven Eberhardt
08b7980d69
Qt Editor: Fix shape relative default
2016-06-18 10:43:00 -04:00
Sven Eberhardt
a598dee4e1
Qt Editor: Fix shape delegate parent object when delegate is provided by an effect
2016-06-18 10:41:15 -04:00
Sven Eberhardt
0162b4b21f
Qt Editor: Make Relative=true the default for shape delegates.
...
It should be by far the more common setting.
2016-06-18 10:40:24 -04:00
Sven Eberhardt
1b785da271
Fix non-Qt build
2016-06-18 10:33:08 -04:00
Sven Eberhardt
25fa57cabf
Qt Editor: Add "Static Flat" landscape mode
2016-06-17 18:44:59 -04:00
Sven Eberhardt
ec6998e530
Qt Editor: Fix some crashes and errors when switching between object and definition selection
2016-06-17 01:26:38 -04:00
Sven Eberhardt
2e412d1668
Qt Editor: Fix log output position
2016-06-17 00:56:23 -04:00
Sven Eberhardt
b70882d7fa
Editor: Object scaling+rotation
2016-06-17 00:07:49 -04:00
Sven Eberhardt
f913b4d012
Qt Editor: Highlight objects hovered in object selection delegate in viewport
2016-06-16 16:15:15 -04:00
Sven Eberhardt
2f22a3a8fe
Qt Editor: Add property delegate type "object"
2016-06-16 14:59:04 -04:00
Sven Eberhardt
9e4f036fe2
Qt Editor: Focus across columns in property editor
2016-06-16 13:19:35 -04:00
Sven Eberhardt
a52857d073
qt editor: Add string delegate
2016-06-16 00:40:25 -04:00
Sven Eberhardt
2df6fdb52b
qt editor: Improve grouped enum tree navigation
2016-06-16 00:09:53 -04:00
Sven Eberhardt
e5837dc478
Qt Editor: Use definition grouping on "def" property delegate enum
2016-06-15 21:57:59 -04:00
Sven Eberhardt
ad863836b3
Qt Editor: Add groups to enum
2016-06-15 00:15:47 -04:00
Lukas Werling
6b958fe88e
Fix viewports on high-DPI screens
2016-06-11 22:36:48 +02:00
Lukas Werling
60671474a8
Use Qt's event loop instead of polling for events
...
This fixes slow input event handling execution on Linux. Additionally,
it seems to fix some crashes with the menu bar.
2016-06-11 21:52:50 +02:00
Sven Eberhardt
0767fd2616
Qt Editor: Auto-add PlayerStart object to scenarios created via "New..." option.
2016-06-08 22:27:32 -04:00
Sven Eberhardt
0bb910814d
Qt Editor: Fix display and control of enum delegate parameters
2016-06-08 00:37:48 -04:00
Sven Eberhardt
f44cb9fa62
Qt Editor: Fix script errors on empty selection
2016-06-06 23:26:20 -04:00
Sven Eberhardt
16e31098b4
Qt Editor: Improve proplist and array display/editing
...
* Add/Remove element buttons
* Display customization of user delegates
2016-06-06 01:54:05 -04:00
Sven Eberhardt
b10da0629d
Qt Editor: More EditorProps types (string, array) and attributes (EditOnSelection, DefaultEditorProp)
2016-06-03 01:20:43 -04:00
Sven Eberhardt
af2a74b6ec
Qt Editor: Array editing
2016-05-28 09:30:54 -04:00
Sven Eberhardt
d304b17028
Qt Editor: Editing of child proplists
2016-05-24 23:06:00 -04:00
Sven Eberhardt
8a5dbdc73f
Qt Editor: More shape prop storage options
2016-05-23 19:22:49 -04:00
Sven Eberhardt
747077b71b
Qt Editor: Fix effect properties
2016-05-23 19:22:05 -04:00
Sven Eberhardt
881534bee0
Qt Editor: Shape properties
2016-04-25 16:17:10 -04:00
Sven Eberhardt
c0228be4e7
Qt Editor: More editor property types and functionality
2016-04-16 22:05:35 -04:00
Armin Burgmeier
0580132d81
Fix the build on Linux
...
With NULL, the function call was ambiguous. Use nullptr to choose the overload
taking a pointer and not the one taking an integer.
2016-04-10 13:27:16 -07:00
Sven Eberhardt
2a2fc68e3f
Qt Editor: Add user properties
2016-04-09 14:29:02 -04:00
Sven Eberhardt
879d501592
Merge remote-tracking branch 'remotes/origin/qteditor' into qteditor
...
Conflicts:
src/editor/C4ConsoleQtPropListViewer.cpp
src/editor/C4ConsoleQtPropListViewer.h
src/script/C4ValueArray.cpp
2016-04-04 19:34:02 -04:00
Nicolas Hake
1e1532ef8a
Darwin: What the hell does "#import" do anyway?
2016-04-04 23:27:50 +02:00
Sven Eberhardt
98c36e5955
Qt Editor: Implement setting of properties
2016-04-03 23:46:58 -04:00
Sven Eberhardt
e8f48fd53e
Qt Editor: Win32 build fixes
2016-04-03 23:46:20 -04:00
Nicolas Hake
9dddf289db
Merge branch 'master' into qteditor
2016-04-03 21:06:32 +02:00
Nicolas Hake
eabca223f5
Update all copyright notices for 2016
2016-04-03 20:24:42 +02:00
Nicolas Hake
493c276126
Rewrite header inclusions to #include "path/to/file.h" style
2016-04-03 20:24:42 +02:00
Nicolas Hake
735f9cc06b
C4Landscape: Pull everything private out of the header
...
Since LTCG is enabled now, we don't have to define every function inside
the headers for ~xXx super speed xXx~, which means we can strip the
headers down to their bare minimum and reduce interdependencies and
therefore recompilation times by a lot.
2016-04-03 13:24:24 +02:00
Sven Eberhardt
370b9cf898
Qt Editor: Disable vsync to avoid laggy viewports
2016-03-28 23:10:10 -04:00
Lukas Werling
a12e485458
Qt Editor: Add scroll bars to the viewports
2016-03-28 22:07:43 +02:00
Sven Eberhardt
9294d8b9dc
Qt Editor: Fix title and icon
...
Using the .ico needs a plugin that is not always loaded.
2016-03-26 23:55:28 -04:00
Lukas Werling
ca88a0a52a
Implement new Linux editor todos
2016-03-26 21:43:37 +01:00
Lukas Werling
6d9aef33c2
Merge branch 'qteditor-sdl' into qteditor
2016-03-26 20:57:10 +01:00
Lukas Werling
f8dc58e0ed
Remove Windows editor rendering hacks (untested)
2016-03-26 20:54:26 +01:00
Lukas Werling
61e97ee87e
Fix zooming not working in the editor
2016-03-26 20:40:09 +01:00
Lukas Werling
f9190cd1ea
Fix keyboard input for Qt editor/SDL
...
The SDL port used to define a separate set of key codes differing from
the usual ones. The SDL codes are now translated to make the Qt input
easy.
This also fixes a broken keycode for the '0' key.
2016-03-26 20:29:07 +01:00
Lukas Werling
30dd360a57
Update the Qt rendering widget periodically
2016-03-26 19:03:16 +01:00
Sven Eberhardt
dc7259bb1e
Qt Editor: Allow opening of user path from welcome page
2016-03-26 14:02:40 -04:00
Sven Eberhardt
f2daa51fa7
Qt Editor: Add "Welcome" dock widget
2016-03-26 01:36:40 -04:00
Armin Burgmeier
56545dc5f3
Fix crash when constructing C4ConsoleQtDefinitionListViewer
2016-03-25 14:16:43 -07:00
Sven Eberhardt
1613885f47
Qt Editor: Use qt resource to set icon
2016-03-23 22:56:17 -04:00
Sven Eberhardt
9690174007
Qt Editor: Fix windows includes
2016-03-23 18:20:23 -04:00
Sven Eberhardt
b1ac208249
Qt Editor: Add "File->New" menu entry
2016-03-22 23:08:05 -04:00
Lukas Werling
4290038909
Move all viewport drawing to QOpenGLWidget::paintGL
...
Unfortunately, this still doesn't fix rendering. Note that the paintGL()
isn't called periodically yet, only when resizing the window.
2016-03-22 16:50:38 +01:00
Lukas Werling
e1eb62a552
Fix warnings about overridden functions
2016-03-20 21:16:52 +01:00
Lukas Werling
75f62e52f2
Make Qt editor work with the SDL engine
...
Viewport rendering doesn't quite work yet, though.
2016-03-20 21:16:52 +01:00
Lukas Werling
08d7c9dcea
Implement GetShiftWParam() with Qt
2016-03-20 21:16:52 +01:00
Sven Eberhardt
a3cdfa3221
Qt Editor: Add shadow to landscape brush circle
...
To be more visible e.g. when drawing snow or in front of a white sky
2016-03-20 11:35:20 -04:00
Sven Eberhardt
3f7d68ff2c
Qt Editor: Sort objects in object creator by name
2016-03-19 14:40:23 -04:00
Sven Eberhardt
ed0647866e
Qt Editor: Add preview for new object placement
2016-03-19 14:40:22 -04:00
Lukas Werling
b64b4e8574
Compilation fixes for Linux
2016-03-18 21:34:21 +01:00
Sven Eberhardt
4f70fdbfc8
Qt Editor landscape drawing fixes and improvements. Add brush size preview.
2016-03-18 00:26:14 -04:00
Sven Eberhardt
645520c7af
Qt Editor: Fix viewport focus and keyboard handling.
2016-03-15 22:58:41 -04:00
Sven Eberhardt
f6ce50e9e7
Qt Editor: Use qt widgets for viewports
2016-03-10 00:07:17 -05:00
Sven Eberhardt
63bbba06bb
Qt Editor: Add missing creator files
2016-03-06 13:17:14 -05:00
Sven Eberhardt
80549ca2cc
Qt Editor: Add object creator
2016-03-06 13:06:29 -05:00
Sven Eberhardt
74b3983f7f
Fix some Qt editor crashes
...
Fix use-after-delete on proplists by item view and crash on recursive execution of message processing.
2016-03-03 00:13:39 -05:00
Sven Eberhardt
771a333e21
Qt Editor: Add effects to object list view + fixes
...
Also remove cache of C4Values and use callbacks on object and effect deletion instead.
2016-02-21 22:23:42 -05:00
Sven Eberhardt
a4d28c383b
Qt Editor: Implement object list view
2016-02-18 00:11:35 -05:00
Sven Eberhardt
e0e09133d6
Qt Editor: Add some string translations.
2016-02-18 00:10:30 -05:00
Sven Eberhardt
2af22ee824
New editor (Qt-based)
...
Work in progress. So far only for Windows.
2016-02-15 08:38:06 -05:00
Nicolas Hake
4fdafbc78a
Move StdColors.h ref from C4Surface.h to files that actually need it
...
C4Surface.h doesn't require anything from StdColors.h, so there's no
reason to reference the latter there.
2016-02-08 02:13:18 +01:00
Günther Brammer
934b519bb4
Update the SDL port to SDL2
...
SDL2 is a much closer match to the other platform code, and
allows the creation of OpenGL 3 core contexts, which is
now required.
2016-02-06 16:48:21 +01:00
Günther Brammer
37fd0a88c6
win32: Rename C4Window::hRenderWindow to renderwnd to match GTK+
2016-01-23 22:02:52 +01:00
Günther Brammer
9210c65e85
gtk: Hide usages of X11 behind #ifdef GDK_WINDOWING_X11
2016-01-23 22:02:51 +01:00
Günther Brammer
11bbeb2a5b
Rename WITH_DEVELOPER_MODE to USE_GTK
...
This mirrors USE_WIN32_WINDOWS, USE_SDL_MAINLOOP and USE_COCOA.
2016-01-23 20:36:33 +01:00
Günther Brammer
8257264415
Avoid a gtk runtime warning on empty statusbar text
...
(openclonk:12546): Gtk-CRITICAL **: gtk_statusbar_push: assertion 'text != NULL' failed
2016-01-17 23:34:29 +01:00
Sven Eberhardt
0a9cf34e77
Win32 editor: Allow resizing of main console window #1601
2016-01-16 21:01:11 -05:00
Sven Eberhardt
f1c4273bb9
Win32 editor: Allow resizing of property window #1601
2016-01-16 19:56:24 -05:00
Günther Brammer
39c2a0e18c
gtk: Use glib-compile-resources instead of gdk-pixbuf-csource
...
Yet another deprecated feature replacement. At least this one makes our
code more concise.
2016-01-11 01:52:49 +01:00
Günther Brammer
c20f98dcf9
gtk editor: Support EditCursorCommands, too
...
Reuse the windows code for this. Both versions had three parts: Enabling
the right menu items, adding the selection-specific ones, and showing the
menu. The second part is now common code, with the platform code in a new
function, since it grew big enough to be worth sharing.
2016-01-11 01:52:49 +01:00
Günther Brammer
7613393359
gtk editor: Exchange cursor and time information
...
The toolbar doesn't have enough space by default, and this way we can use
the GtkStatusbar widget.
2016-01-10 00:19:07 +01:00
Günther Brammer
a185cae264
gtk editor: Simplify landscape preview drawing
...
In earlier versions, DrawPatternedCircle was a fairly complicated function.
Nowadays, it just copies pixels in memory, bounded by a circle. Since we
need to convert our surfaces to a format GTK+ can use anyway, combine that
step with the circle boundaries. Also use a cairo surface instead of a
GdkPixbuf. Cairo uses almost the same pixel format, except for
premultiplied alpha. Ignore this for now.
2016-01-10 00:19:07 +01:00
Günther Brammer
ab7f4f0bbf
gtk editor: Use GTK+ 3 layout widgets
...
Specifically, GtkGrid. For most cases, this is an increase in lines of
code, but the landscape tools dialog can now be done with just three layout
widgets.
While at it, use a toolbar and move the mode buttons into it, too.
2016-01-10 00:19:07 +01:00
Günther Brammer
67bf24f1e1
editor: Always remove previous suggestions before adding new ones
...
9e771ac
moved the Win32 ClearInput implementation into SetInputFunctions,
but broke at least GTK while doing that. 9a7d57c0d2
fixed the assertion
failure in GTK that resulted, but failed to restore the removal of the old
completions.
Fix this by folding ClearInput into SetInputFunctions in all implementations.
2016-01-08 15:22:00 +01:00
Nicolas Hake
24b54211c5
Drop Min, Max, Swap for std::min, std::max, std::swap
...
The C++ standard library comes with perfectly fine implementations of
these functions, so there's no point in reimplementing them just for the
hell of it.
2015-11-15 13:53:01 +01:00
Armin Burgmeier
4d36f43025
gtk editor: keep scroll position when updating property dialog ( #566 )
...
This is still not quite optimal since we need to wait for line validation.
There does not seem to be a way to trigger immediate validation.
2015-11-12 16:04:28 -08:00
Armin Burgmeier
ef4ea2d931
Drop support for GTK+ 2
...
The minimum GTK version is now GTK+ 3.4, which is available since 2012.
It's part of Ubuntu LTS 12.04, and so should be available on any halfway
modern linux distribution.
This should allow getting rid of using deprecated GTK+ API much easier.
2015-10-18 14:45:52 -04:00
Sven Eberhardt
a81249438a
Win32 editor: Fix selection of textures with names included in other texture names (e.g. rock and rock_smooth).
2015-10-09 00:51:07 -04:00
Peter Wortmann
f0030e33e0
Warning fixes
...
Actually pretty sure a few of them were bugs. Hopefully no new
ones were introduced here.
2015-10-03 15:32:39 +01:00
Julius Michaelis
9a7d57c0d2
Fix assertion firing in C4ConsoleGUI::SetInputFunctions introduced by 9e771ac
2015-09-30 14:35:50 +02:00
Sven Eberhardt
9e771acfd1
Editor: Add most recently entered script lines to dropdown list.
...
This also enables easier auto-completion via arrow-down.
2015-09-27 15:28:17 -04:00
Sven Eberhardt
d3ee2fac57
Fix sorting of script and engine functions in dropdown menu in editor.
2015-09-26 20:10:55 -04:00
Sven Eberhardt
15336a7ea8
Allow scenario saving onto same file when launched from an unpacked folder.
2015-09-24 22:36:45 -04:00
Sven Eberhardt
08f4d29d02
Fix memory leak by editor preview surface ( #1405 ).
2015-09-22 22:54:16 -04:00
Sven Eberhardt
26dff21b8a
Fix tool picker on materials with sky background.
...
It selected an invalid texture before.
2015-09-19 22:37:45 -04:00
Armin Burgmeier
fd285f6656
Create mipmaps only for static textures that are expected to be zoomed
...
Hopefully fixes #1403 .
2015-09-18 21:10:39 -04:00
Nicolas Hake
a11135e4ac
Win32: Properly clean up tools dialog after use ( #1377 )
...
When switching dialogs in editor mode, the (paint) tools dialog wouldn't
be properly cleared, instead only destroying the dialog window. Thus,
the next time it would be used, it'd try painting onto a device context
which did no longer correspond to any existing window, which made OpenGL
sad.
2015-09-18 15:02:31 +02:00
Nicolas Hake
51eb389739
Win32: Actually delete all of the landscape dlg bitmaps on close
...
We used to leak a bunch of HBITMAPs when the langscape tools dialog
closed, because for some reason we only destroyed a few instead of all.
2015-09-18 15:02:30 +02:00
Sven Eberhardt
9f4391ff0a
Fix ModeBack initialization on editor startup.
...
It would be set by state and then immediately reset in Default(). This had the effect that if you used the color picker on sky before ever selecting a background material, the wrong background would be used.
2015-09-17 22:25:46 -04:00
Armin Burgmeier
5107e23905
Select sane defaults for background material and texture in editor ( #1402 )
2015-09-17 20:03:53 -04:00
Sven Eberhardt
5b539a5b34
Fix manipulation of multiple objects in editor.
...
It would only do work on the last (and possibly random objects because initialized memory was accessed).
2015-09-15 21:29:26 -04:00
Armin Burgmeier
20eb0615ee
Custom shader for drawing sky
...
Add a C4ShaderCall parameter to tho most important drawing functions, and
make C4DrawGL's CreateSpriteShader public with additional parameters to
specify additional defines and shader slices. C4Sky uses this to compile its
own shader with OC_SKY defined.
2015-09-12 18:15:34 -04:00
Sven Eberhardt
20d3de46cd
Fix some unused variables.
2015-09-03 21:26:49 -04:00
Sven Eberhardt
7d9f7aee02
Fix some unused variables and integer type conversions.
2015-09-01 22:18:39 -04:00
Sven Eberhardt
638ed81608
Implement background material controls in Windows editor.
...
Also removed auto-sort from the material combo boxes (so sky is on top in both) and put true background materials (i.e. sky and tunnel) on top.
2015-08-09 13:36:44 -04:00
Armin Burgmeier
ad57b5a9c9
Fix fill tool in developer mode
2015-08-04 23:15:16 -04:00
Armin Burgmeier
94ce958e4c
editor: sort background textures differently than foreground textures
...
The sort order in the combo boxes depends on the selected material.
2015-08-04 21:39:23 -04:00
Armin Burgmeier
3ec53c2c40
Update GTK+ editor so that one can draw background materials
2015-08-04 21:21:24 -04:00
Armin Burgmeier
006cf68874
Some refactoring, and restore support for Map.bmp
...
The new behaviour that allows 255 mat-tex combinations (once we increased
C4M_MaxTexCount...) is enabled with MapFg.bmp, and then MapBg.bmp can be
used to draw IFT or other fancy things.
2015-08-04 21:21:23 -04:00
Armin Burgmeier
b1e9c3924d
Make the Map field private in C4Landscape
2015-08-04 21:21:23 -04:00
Armin Burgmeier
92f3a3e749
Remove GBackIFT in favor of a lookup in the background surface
2015-08-04 21:21:23 -04:00
Sven Eberhardt
a7ecc86dc4
Hide normal maps from landscape drawing texture list in editor. ( #1255 )
2015-02-14 23:45:16 +01:00
Nicolas Hake
e21a5bdd44
Rename BoundBy to Clamp
...
"BoundBy" sounds like a predicate. "Clamp" is a common function name for
the operation in graphics processing, so it should be familiar to users.
2015-02-12 23:05:55 +01:00
Nicolas Hake
1a1cecadd4
Update license texts
...
Some files, most notably ObjC and test cases, hadn't been updated to use
the new license header. Fix this.
2015-02-08 15:05:11 +01:00
Günther Brammer
5bcedb5bbf
Remove some redundant #includes
2015-01-25 18:53:48 +01:00
Nicolas Hake
2ef2c637a7
Remove several instances of disabled legacy code
2015-01-18 22:59:45 +01:00
Sven Eberhardt
c00d8c7a4d
Add next_selection parameter to EditCursorDeselection.
...
If an object is deselected due to a new object selection, that newly selected object is passed as next_selection.
2015-01-17 20:37:54 +01:00
Armin Burgmeier
338910949d
Fix build with GTK+
2015-01-04 12:13:48 +01:00
Sven Eberhardt
42b9ca4577
Add custom EditCursorCommands available in editor context menu.
...
Example: this.EditCursorCommands = ["Explode(20)"] on an item will offer a menu entry to explode the object. Commands may be either strings or function pointers, but function pointers will always be called by name.
2015-01-03 23:21:36 +01:00
Tobias Zwick
5e188aafb3
Fix setting small ViewOffsets. Refactor neighbouring code, enable a slight MouseAutoScroll by default
...
* make ViewX,ViewY,ViewOffsetX and Y private, add getters and setters that update variables that are dependent on these
2015-01-03 22:53:02 +01:00
Sven Eberhardt
f50e2e9e3a
Fix scroll bars in zoomed editor viewports on Windows.
2014-12-14 16:08:56 +01:00
Sven Eberhardt
8df39d06e4
Fix texture preview in editor tools dialogue on Windows.
2014-12-14 15:20:57 +01:00
Armin Burgmeier
56b19ac065
Fix brush preview in GTK+ developer mode
...
This looks like an artifact from when the alpha channel was inverted.
2014-11-24 16:32:25 -05:00
Martin Plicht
b2fcc2ee32
C4EditCursor: Instead of manual list traversal use iterator
2014-10-25 21:26:06 +02:00
Martin Plicht
03f43f462b
C4ObjectList: Replace trivial cases of manual list traversal with iterator usage
2014-10-25 21:25:52 +02:00
Armin Burgmeier
a597dc28d7
Use PerformMultiLines where appropriate
2014-10-08 18:33:46 -04:00
Armin Burgmeier
05a3e86472
Make C4EditCursor use PerformMultiPix instead of DrawPix for selection frame
2014-10-08 18:33:45 -04:00
Kevin Zheng
6a1a551d01
Clean up deprecated headers and functions
...
"gdk_pixbuf_unref has been deprecated since version 2.0 and should not be
used in newly-written code. Use g_object_unref()."
sys/timeb.h isn't used anymore since 2005.
2014-05-27 00:30:20 +02:00
Günther Brammer
04e1c74c05
Merge Call fix commit
2014-04-19 19:02:27 +02:00
Günther Brammer
22016e075f
Replace some usages of C4ID with C4Def*
...
In particular those that made the c4script shell depend on C4Id.cpp.
2014-04-19 19:02:22 +02:00
Julius Michaelis
2c7d9c0549
Fix a load of warnings (two were actual errors, only in diagnostics though)
2014-04-17 19:24:41 +02:00
Maikel de Vries
db8e639b3e
Fixed some Clonk 4 string occurrences in C4Console
2014-03-20 21:16:27 +01:00
Martin Plicht
3d9c965ebd
mac: C4Particles: glGenVertexArrays fix for Mac OS X
2014-01-23 17:52:19 +01:00
Nicolas Hake
e0dc30c59a
Update copyright notices
...
As discussed in http://forum.openclonk.org/topic_show.pl?tid=2917 , I
have merged all copyright notices into a single file and referenced that
merged file from each source file.
For the updated source files, the timeline has been split into three
parts:
1. Pre-RWD code (before 2001)
2. RWD code (2001 through 2009)
3. OpenClonk code (2009 and later)
All pre-RWD copyright notices have been left intact, as have RWD-era
copyright notices where the file did not have a RedWolf design copyright
notice but only individual author ones. All copyright notices of the
OpenClonk era have been replaced by a single notice ranging from the
first recorded year to the current year (2013). Mape code did not get a
OpenClonk Team copyright notice because it is somewhat separate from the
main OpenClonk codebase and has only been touched by Armin Burgmeier.
2013-12-23 13:03:19 +01:00
Tim Blume
240193ad5a
Remove remains of Direct3D support
...
Direct3D hasn't worked for more than a year now, and there don't seem to
be any efforts to revive it. Remove it and concentrate on better OpenGL
support.
2013-11-02 21:39:34 +01:00
Martin Plicht
7ba5333f8b
mac: C4ConsoleGUI: Implement SetInputFunctions
2013-10-05 13:19:59 +02:00
Nicolas Hake
5254302547
Win32/Editor: Use StdCopyStrBuf for Common Dialog buffers ( #975 )
...
Change StdStrBuf usage to StdCopyStrBuf because FileSelect tries to
get a non-const pointer to its data, which correctly asserts when called
on a StdStrBuf that references const data.
Closes #975 .
2013-09-14 21:09:04 +02:00
Nicolas Hake
7e260aa9de
Remove C4ControlScript::fInternal
...
fInternal basically acted as a reverse "evil bit" as in RFC 3514: when
set, the engine would not do any checks on the script contained in the
control packet, nor log the script (visibly in game; the packet log
would of course contain the packet). A malicious game client thus would
be able to inject arbitrary script without people (immediately) noticing
anything was amiss.
As of this patch, only the host is able to execute arbitrary scripts,
and those will be shown in the message board for all players to see.
This privilege can be irrevocably disabled in network games by any
client by using the "/nodebug" message board command.
Closes #936 .
2013-09-04 20:18:06 +02:00
Nicolas Hake
ef9f79d815
Fix GTK build
2013-09-04 19:57:26 +02:00
Nicolas Hake
7e70554a04
Use control packet for more editor mode actions
...
Actions changed include dropping definitions, (de-)selecting objects,
player elimination. This removes some more pre-assembled C4Script code
going across the network unchecked.
Part of #936 .
2013-09-04 17:51:55 +02:00
Günther Brammer
9506c5ad97
Merge branch 'scancodes'
2013-05-24 17:47:59 +02:00
Günther Brammer
71d9e3c9e3
editor: Recognize pressing shift and alt in viewport again
2013-03-24 22:10:11 +01:00
Günther Brammer
346842470d
Clean up some superfluous includes
2013-03-24 18:33:01 +01:00
Sven Eberhardt
c64afb8626
Win32: Fix broken "Save as..." dialog in editor mode when engine is started with forward slashes in scenario path
2013-03-19 00:36:05 +01:00
Günther Brammer
2a9d63cb2a
gtk: Use higher-resolution logo as window icon
...
Metacity started to display bigger icons in the window list, so the higher
resolution is now actually useful for me. While at it, use gdk-pixbuf-csource
to generate the .h at build time from the .ico instead of duplicating the
data in the repository.
2013-02-12 01:08:02 +01:00
Sven Eberhardt
06e70b7b74
Synchronized EditCursor(De)selection, so you can edit scenarios in network mode and/or record it.
2013-01-15 23:30:23 +01:00
Sven Eberhardt
f51a085592
Added object callbacks EditCursorSelection and EditCursorDeselection. Useful to show or hide developer stuff in the editor.
2013-01-15 23:10:25 +01:00
Günther Brammer
864c5c7ea8
copyright notices update 2012
2013-01-12 16:31:40 +01:00
Günther Brammer
95de10f6a8
editor: Fix USE_CONSOLE
2012-11-16 00:05:58 +01:00
Sven Eberhardt
41cff7ad92
Editor: Fix handling of erronous map indices by material picker
2012-10-28 15:23:45 +01:00
Martin Plicht
4f8effcd10
mac: Fix editor window
2012-10-14 19:45:39 +02:00
Sven Eberhardt
db84b849b1
/sound reenabled. Sound-creating client now shown in client list box (F4). No sounds played when client is ignored.
2012-10-13 13:37:59 +02:00
Sven Eberhardt
8bdd761027
PlayerControls: Allow usage of keyboard scan codes instead of virtual key names using $%x format (Win32 only)
...
Also re-resolves keys if the keyboard layout changed at runtime.
2012-10-09 00:54:34 +02:00
Martin Plicht
b264612b10
mac: Move C4EditorWindowController from platform to editor
2012-09-02 20:57:49 +02:00
Martin Plicht
562565f865
mac: Move C4OpenGLView.mm/h to graphics/C4DrawGLMac.mm/h and move some C4AbstractApp functions to C4AppMac.mm to better match implementations for the other platforms
2012-09-02 20:51:43 +02:00
Martin Plicht
10a328d5ba
mac: Change prefix of Objective-C classes/filenames from Clonk to C4, give xib files names that make more sense
2012-09-02 15:39:29 +02:00
Martin Plicht
f6825d073e
mac: Compile with Automatic Reference Counting enabled
2012-09-02 13:56:53 +02:00
Günther Brammer
5a2831a1e7
editor: Increase default viewport size to 800x500
...
This should allow one to place four viewports plus the console and the
property/tool window on a 1920x1080 screen.
2012-08-19 21:01:54 +02:00
Günther Brammer
2fded23a1b
Editor: Get function autocomplete names from proplists instead of scripts
2012-05-18 17:49:38 +02:00
Martin Plicht
daabc5be16
mac: Fix compilation
2012-05-01 15:05:43 +02:00
Günther Brammer
1995b59adc
win32: C4Window::SetSize calls AdjustWindowRectEx, GUI::Dialog doesn't need to
2012-04-28 15:09:35 +02:00
Günther Brammer
1a29f8625d
Reorder engine source file organization a bit
...
This mostly consists of flattening the hierarchy, splitting the
graphics stuff out of platform, and a few smaller cleanups.
2012-04-27 19:04:43 +02:00
Armin Burgmeier
e11e9845d1
Fix Windows build
2012-04-23 21:45:01 +02:00
Armin Burgmeier
206f90adbc
Pass through key state handling from event callbacks ( #745 )
...
This gets rid of Application.IsAltDown() and friends which was used for
this purpose in C4MouseControl and C4EditCursor. In case non-event
callbacks need to access the state of the modifier keys the state is
now cached in these classes (if it wasn't already).
This new solution is supposed to be more robust, since the key modifier
state comes always directly from the input event. This fixes #745 , where
Application.IsAltDown was stuck for some reason.
I updated the Windows and Mac code as well, but wasn't able to test it,
it might not compile and/or not work, in which case please someone fix it :)
2012-04-22 22:09:06 +02:00
Günther Brammer
7632c823fe
gtk: Drop compatibility with GTK versions older than 2.18
2012-04-18 00:37:31 +02:00
Günther Brammer
bc5e77d9d0
Simplify C4Game::FindObject
...
It isn't exposed to script anymore, and the internal users don't use most
features. This might even speed up lava-in-oil a bit.
2012-04-15 23:32:37 +02:00
Nicolas Hake
cbbcf200cf
win32: Build fix
2012-04-15 13:22:58 +02:00