summaryrefslogtreecommitdiff
path: root/core/io
diff options
context:
space:
mode:
authorJuan Linietsky <reduzio@gmail.com>2014-06-11 10:41:43 -0300
committerJuan Linietsky <reduzio@gmail.com>2014-06-11 10:41:43 -0300
commit64e83bfd1404ea593f0c79b478d196a3fcde42a8 (patch)
treec18c61da239443532a94fb9fa54df702df12a90b /core/io
parent9b8696d3dd92e2ed6f310ad0f0bf3c2182c9c6ae (diff)
parent5f5cd5e6d1508f85ac1bffa44e122b4dc0e2bb1d (diff)
Merge branch 'master' of https://github.com/okamstudio/godot
Diffstat (limited to 'core/io')
-rw-r--r--core/io/file_access_pack.cpp5
-rw-r--r--core/io/file_access_pack.h1
-rw-r--r--core/io/packet_peer.cpp1
3 files changed, 7 insertions, 0 deletions
diff --git a/core/io/file_access_pack.cpp b/core/io/file_access_pack.cpp
index 6a28fa9dae..e2cb300ebc 100644
--- a/core/io/file_access_pack.cpp
+++ b/core/io/file_access_pack.cpp
@@ -443,6 +443,11 @@ bool DirAccessPack::file_exists(String p_file){
return current->files.has(p_file);
}
+bool DirAccessPack::dir_exists(String p_dir) {
+
+ return current->subdirs.has(p_dir);
+}
+
Error DirAccessPack::make_dir(String p_dir){
return ERR_UNAVAILABLE;
diff --git a/core/io/file_access_pack.h b/core/io/file_access_pack.h
index 07ce8cbaf8..a4c750bf3c 100644
--- a/core/io/file_access_pack.h
+++ b/core/io/file_access_pack.h
@@ -190,6 +190,7 @@ public:
virtual bool file_exists(String p_file);
+ virtual bool dir_exists(String p_dir);
virtual Error make_dir(String p_dir);
diff --git a/core/io/packet_peer.cpp b/core/io/packet_peer.cpp
index f67a10df2e..37fc9c4a0a 100644
--- a/core/io/packet_peer.cpp
+++ b/core/io/packet_peer.cpp
@@ -112,6 +112,7 @@ void PacketPeer::_bind_methods() {
ObjectTypeDB::bind_method(_MD("get_var"),&PacketPeer::_bnd_get_var);
ObjectTypeDB::bind_method(_MD("put_var", "var:Variant"),&PacketPeer::put_var);
+ ObjectTypeDB::bind_method(_MD("get_available_packet_count"),&PacketPeer::get_available_packet_count);
};
/***************/