summaryrefslogtreecommitdiff
path: root/core/bind
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2014-05-24 01:35:47 -0300
committerJuan Linietsky <reduzio@gmail.com>2014-05-24 01:35:47 -0300
commit1cad087969efefa401a11051343cd0689f660770 (patch)
tree1595dd049bdb7289752012dca4398b2251fb08fa /core/bind
parentf9ff086235cd4ff406b136f62fff77b85c0873f9 (diff)
Making Godot Easier to Use..
-=-=-=-=-=-=-=-=-=-=-=-=-=-= -Auto indenter in code editor, this makes it much easier to paste external code. -Zoom in 2D viewport now uses the mouse pointer as reference. -Obscure hack to see where code/line of GDScript in C++ backtrace. -Fixed a bug where keys would get stuck on X11 if pressed simultaneously -Added Api on IP singleton to request local IPs. -Premultiplied alpha support when importing texture, editing PNGs and as a blend mode.
Diffstat (limited to 'core/bind')
-rw-r--r--core/bind/core_bind.cpp7
-rw-r--r--core/bind/core_bind.h10
2 files changed, 17 insertions, 0 deletions
diff --git a/core/bind/core_bind.cpp b/core/bind/core_bind.cpp
index ec159da00f..960cdbac20 100644
--- a/core/bind/core_bind.cpp
+++ b/core/bind/core_bind.cpp
@@ -98,6 +98,13 @@ void _ResourceSaver::_bind_methods() {
ObjectTypeDB::bind_method(_MD("save","path","resource:Resource"),&_ResourceSaver::save, DEFVAL(0));
ObjectTypeDB::bind_method(_MD("get_recognized_extensions","type"),&_ResourceSaver::get_recognized_extensions);
+
+ BIND_CONSTANT(FLAG_RELATIVE_PATHS);
+ BIND_CONSTANT(FLAG_BUNDLE_RESOURCES);
+ BIND_CONSTANT(FLAG_CHANGE_PATH);
+ BIND_CONSTANT(FLAG_OMIT_EDITOR_PROPERTIES);
+ BIND_CONSTANT(FLAG_SAVE_BIG_ENDIAN);
+ BIND_CONSTANT(FLAG_COMPRESS);
}
_ResourceSaver::_ResourceSaver() {
diff --git a/core/bind/core_bind.h b/core/bind/core_bind.h
index 18eb594760..bb68bbaad8 100644
--- a/core/bind/core_bind.h
+++ b/core/bind/core_bind.h
@@ -39,6 +39,16 @@ protected:
static _ResourceSaver *singleton;
public:
+ enum SaverFlags {
+
+ FLAG_RELATIVE_PATHS=1,
+ FLAG_BUNDLE_RESOURCES=2,
+ FLAG_CHANGE_PATH=4,
+ FLAG_OMIT_EDITOR_PROPERTIES=8,
+ FLAG_SAVE_BIG_ENDIAN=16,
+ FLAG_COMPRESS=32,
+ };
+
static _ResourceSaver *get_singleton() { return singleton; }
Error save(const String &p_path,const RES& p_resource, uint32_t p_flags);