Style: Set clang-format Standard to c++14
This commit is contained in:
parent
7e61be3cb0
commit
6e600cb3f0
248 changed files with 841 additions and 842 deletions
|
@ -112,11 +112,10 @@ UseTab: Always
|
|||
---
|
||||
### C++ specific config ###
|
||||
Language: Cpp
|
||||
Standard: Cpp03
|
||||
Standard: c++14
|
||||
---
|
||||
### ObjC specific config ###
|
||||
Language: ObjC
|
||||
Standard: Cpp03
|
||||
ObjCBlockIndentWidth: 4
|
||||
# ObjCSpaceAfterProperty: false
|
||||
# ObjCSpaceBeforeProtocolList: true
|
||||
|
|
|
@ -1025,10 +1025,10 @@ void _OS::print_all_textures_by_size() {
|
|||
List<_OSCoreBindImg> imgs;
|
||||
uint64_t total = 0;
|
||||
{
|
||||
List<Ref<Resource> > rsrc;
|
||||
List<Ref<Resource>> rsrc;
|
||||
ResourceCache::get_cached_resources(&rsrc);
|
||||
|
||||
for (List<Ref<Resource> >::Element *E = rsrc.front(); E; E = E->next()) {
|
||||
for (List<Ref<Resource>>::Element *E = rsrc.front(); E; E = E->next()) {
|
||||
|
||||
if (!E->get()->is_class("ImageTexture"))
|
||||
continue;
|
||||
|
@ -1059,10 +1059,10 @@ void _OS::print_resources_by_type(const Vector<String> &p_types) {
|
|||
|
||||
Map<String, int> type_count;
|
||||
|
||||
List<Ref<Resource> > resources;
|
||||
List<Ref<Resource>> resources;
|
||||
ResourceCache::get_cached_resources(&resources);
|
||||
|
||||
for (List<Ref<Resource> >::Element *E = resources.front(); E; E = E->next()) {
|
||||
for (List<Ref<Resource>>::Element *E = resources.front(); E; E = E->next()) {
|
||||
|
||||
Ref<Resource> r = E->get();
|
||||
|
||||
|
@ -1747,7 +1747,7 @@ Vector<Vector3> _Geometry::clip_polygon(const Vector<Vector3> &p_points, const P
|
|||
|
||||
Array _Geometry::merge_polygons_2d(const Vector<Vector2> &p_polygon_a, const Vector<Vector2> &p_polygon_b) {
|
||||
|
||||
Vector<Vector<Point2> > polys = Geometry::merge_polygons_2d(p_polygon_a, p_polygon_b);
|
||||
Vector<Vector<Point2>> polys = Geometry::merge_polygons_2d(p_polygon_a, p_polygon_b);
|
||||
|
||||
Array ret;
|
||||
|
||||
|
@ -1759,7 +1759,7 @@ Array _Geometry::merge_polygons_2d(const Vector<Vector2> &p_polygon_a, const Vec
|
|||
|
||||
Array _Geometry::clip_polygons_2d(const Vector<Vector2> &p_polygon_a, const Vector<Vector2> &p_polygon_b) {
|
||||
|
||||
Vector<Vector<Point2> > polys = Geometry::clip_polygons_2d(p_polygon_a, p_polygon_b);
|
||||
Vector<Vector<Point2>> polys = Geometry::clip_polygons_2d(p_polygon_a, p_polygon_b);
|
||||
|
||||
Array ret;
|
||||
|
||||
|
@ -1771,7 +1771,7 @@ Array _Geometry::clip_polygons_2d(const Vector<Vector2> &p_polygon_a, const Vect
|
|||
|
||||
Array _Geometry::intersect_polygons_2d(const Vector<Vector2> &p_polygon_a, const Vector<Vector2> &p_polygon_b) {
|
||||
|
||||
Vector<Vector<Point2> > polys = Geometry::intersect_polygons_2d(p_polygon_a, p_polygon_b);
|
||||
Vector<Vector<Point2>> polys = Geometry::intersect_polygons_2d(p_polygon_a, p_polygon_b);
|
||||
|
||||
Array ret;
|
||||
|
||||
|
@ -1783,7 +1783,7 @@ Array _Geometry::intersect_polygons_2d(const Vector<Vector2> &p_polygon_a, const
|
|||
|
||||
Array _Geometry::exclude_polygons_2d(const Vector<Vector2> &p_polygon_a, const Vector<Vector2> &p_polygon_b) {
|
||||
|
||||
Vector<Vector<Point2> > polys = Geometry::exclude_polygons_2d(p_polygon_a, p_polygon_b);
|
||||
Vector<Vector<Point2>> polys = Geometry::exclude_polygons_2d(p_polygon_a, p_polygon_b);
|
||||
|
||||
Array ret;
|
||||
|
||||
|
@ -1795,7 +1795,7 @@ Array _Geometry::exclude_polygons_2d(const Vector<Vector2> &p_polygon_a, const V
|
|||
|
||||
Array _Geometry::clip_polyline_with_polygon_2d(const Vector<Vector2> &p_polyline, const Vector<Vector2> &p_polygon) {
|
||||
|
||||
Vector<Vector<Point2> > polys = Geometry::clip_polyline_with_polygon_2d(p_polyline, p_polygon);
|
||||
Vector<Vector<Point2>> polys = Geometry::clip_polyline_with_polygon_2d(p_polyline, p_polygon);
|
||||
|
||||
Array ret;
|
||||
|
||||
|
@ -1807,7 +1807,7 @@ Array _Geometry::clip_polyline_with_polygon_2d(const Vector<Vector2> &p_polyline
|
|||
|
||||
Array _Geometry::intersect_polyline_with_polygon_2d(const Vector<Vector2> &p_polyline, const Vector<Vector2> &p_polygon) {
|
||||
|
||||
Vector<Vector<Point2> > polys = Geometry::intersect_polyline_with_polygon_2d(p_polyline, p_polygon);
|
||||
Vector<Vector<Point2>> polys = Geometry::intersect_polyline_with_polygon_2d(p_polyline, p_polygon);
|
||||
|
||||
Array ret;
|
||||
|
||||
|
@ -1819,7 +1819,7 @@ Array _Geometry::intersect_polyline_with_polygon_2d(const Vector<Vector2> &p_pol
|
|||
|
||||
Array _Geometry::offset_polygon_2d(const Vector<Vector2> &p_polygon, real_t p_delta, PolyJoinType p_join_type) {
|
||||
|
||||
Vector<Vector<Point2> > polys = Geometry::offset_polygon_2d(p_polygon, p_delta, Geometry::PolyJoinType(p_join_type));
|
||||
Vector<Vector<Point2>> polys = Geometry::offset_polygon_2d(p_polygon, p_delta, Geometry::PolyJoinType(p_join_type));
|
||||
|
||||
Array ret;
|
||||
|
||||
|
@ -1831,7 +1831,7 @@ Array _Geometry::offset_polygon_2d(const Vector<Vector2> &p_polygon, real_t p_de
|
|||
|
||||
Array _Geometry::offset_polyline_2d(const Vector<Vector2> &p_polygon, real_t p_delta, PolyJoinType p_join_type, PolyEndType p_end_type) {
|
||||
|
||||
Vector<Vector<Point2> > polys = Geometry::offset_polyline_2d(p_polygon, p_delta, Geometry::PolyJoinType(p_join_type), Geometry::PolyEndType(p_end_type));
|
||||
Vector<Vector<Point2>> polys = Geometry::offset_polyline_2d(p_polygon, p_delta, Geometry::PolyJoinType(p_join_type), Geometry::PolyEndType(p_end_type));
|
||||
|
||||
Array ret;
|
||||
|
||||
|
|
|
@ -1391,7 +1391,7 @@ void ClassDB::get_extensions_for_type(const StringName &p_class, List<String> *p
|
|||
}
|
||||
}
|
||||
|
||||
HashMap<StringName, HashMap<StringName, Variant> > ClassDB::default_values;
|
||||
HashMap<StringName, HashMap<StringName, Variant>> ClassDB::default_values;
|
||||
Set<StringName> ClassDB::default_values_cached;
|
||||
|
||||
Variant ClassDB::class_get_default_property_value(const StringName &p_class, const StringName &p_property, bool *r_valid) {
|
||||
|
|
|
@ -117,7 +117,7 @@ public:
|
|||
void *class_ptr;
|
||||
HashMap<StringName, MethodBind *> method_map;
|
||||
HashMap<StringName, int> constant_map;
|
||||
HashMap<StringName, List<StringName> > enum_map;
|
||||
HashMap<StringName, List<StringName>> enum_map;
|
||||
HashMap<StringName, MethodInfo> signal_map;
|
||||
List<PropertyInfo> property_list;
|
||||
#ifdef DEBUG_METHODS_ENABLED
|
||||
|
@ -158,7 +158,7 @@ public:
|
|||
|
||||
static void _add_class2(const StringName &p_class, const StringName &p_inherits);
|
||||
|
||||
static HashMap<StringName, HashMap<StringName, Variant> > default_values;
|
||||
static HashMap<StringName, HashMap<StringName, Variant>> default_values;
|
||||
static Set<StringName> default_values_cached;
|
||||
|
||||
private:
|
||||
|
|
|
@ -51,8 +51,8 @@ void PHashTranslation::generate(const Ref<Translation> &p_from) {
|
|||
|
||||
int size = Math::larger_prime(keys.size());
|
||||
|
||||
Vector<Vector<Pair<int, CharString> > > buckets;
|
||||
Vector<Map<uint32_t, int> > table;
|
||||
Vector<Vector<Pair<int, CharString>>> buckets;
|
||||
Vector<Map<uint32_t, int>> table;
|
||||
Vector<uint32_t> hfunc_table;
|
||||
Vector<_PHashTranslationCmp> compressed;
|
||||
|
||||
|
@ -110,7 +110,7 @@ void PHashTranslation::generate(const Ref<Translation> &p_from) {
|
|||
|
||||
for (int i = 0; i < size; i++) {
|
||||
|
||||
const Vector<Pair<int, CharString> > &b = buckets[i];
|
||||
const Vector<Pair<int, CharString>> &b = buckets[i];
|
||||
Map<uint32_t, int> &t = table.write[i];
|
||||
|
||||
if (b.size() == 0)
|
||||
|
|
|
@ -130,10 +130,10 @@ List<StringName> InputMap::get_actions() const {
|
|||
return actions;
|
||||
}
|
||||
|
||||
List<Ref<InputEvent> >::Element *InputMap::_find_event(Action &p_action, const Ref<InputEvent> &p_event, bool *p_pressed, float *p_strength) const {
|
||||
List<Ref<InputEvent>>::Element *InputMap::_find_event(Action &p_action, const Ref<InputEvent> &p_event, bool *p_pressed, float *p_strength) const {
|
||||
ERR_FAIL_COND_V(!p_event.is_valid(), NULL);
|
||||
|
||||
for (List<Ref<InputEvent> >::Element *E = p_action.inputs.front(); E; E = E->next()) {
|
||||
for (List<Ref<InputEvent>>::Element *E = p_action.inputs.front(); E; E = E->next()) {
|
||||
|
||||
const Ref<InputEvent> e = E->get();
|
||||
|
||||
|
@ -185,7 +185,7 @@ void InputMap::action_erase_event(const StringName &p_action, const Ref<InputEve
|
|||
|
||||
ERR_FAIL_COND_MSG(!input_map.has(p_action), _suggest_actions(p_action));
|
||||
|
||||
List<Ref<InputEvent> >::Element *E = _find_event(input_map[p_action], p_event);
|
||||
List<Ref<InputEvent>>::Element *E = _find_event(input_map[p_action], p_event);
|
||||
if (E) {
|
||||
input_map[p_action].inputs.erase(E);
|
||||
if (Input::get_singleton()->is_action_pressed(p_action)) {
|
||||
|
@ -204,9 +204,9 @@ void InputMap::action_erase_events(const StringName &p_action) {
|
|||
Array InputMap::_get_action_list(const StringName &p_action) {
|
||||
|
||||
Array ret;
|
||||
const List<Ref<InputEvent> > *al = get_action_list(p_action);
|
||||
const List<Ref<InputEvent>> *al = get_action_list(p_action);
|
||||
if (al) {
|
||||
for (const List<Ref<InputEvent> >::Element *E = al->front(); E; E = E->next()) {
|
||||
for (const List<Ref<InputEvent>>::Element *E = al->front(); E; E = E->next()) {
|
||||
|
||||
ret.push_back(E->get());
|
||||
}
|
||||
|
@ -215,7 +215,7 @@ Array InputMap::_get_action_list(const StringName &p_action) {
|
|||
return ret;
|
||||
}
|
||||
|
||||
const List<Ref<InputEvent> > *InputMap::get_action_list(const StringName &p_action) {
|
||||
const List<Ref<InputEvent>> *InputMap::get_action_list(const StringName &p_action) {
|
||||
|
||||
const Map<StringName, Action>::Element *E = input_map.find(p_action);
|
||||
if (!E)
|
||||
|
@ -243,7 +243,7 @@ bool InputMap::event_get_action_status(const Ref<InputEvent> &p_event, const Str
|
|||
|
||||
bool pressed;
|
||||
float strength;
|
||||
List<Ref<InputEvent> >::Element *event = _find_event(E->get(), p_event, &pressed, &strength);
|
||||
List<Ref<InputEvent>>::Element *event = _find_event(E->get(), p_event, &pressed, &strength);
|
||||
if (event != NULL) {
|
||||
if (p_pressed != NULL)
|
||||
*p_pressed = pressed;
|
||||
|
|
|
@ -47,7 +47,7 @@ public:
|
|||
struct Action {
|
||||
int id;
|
||||
float deadzone;
|
||||
List<Ref<InputEvent> > inputs;
|
||||
List<Ref<InputEvent>> inputs;
|
||||
};
|
||||
|
||||
private:
|
||||
|
@ -55,7 +55,7 @@ private:
|
|||
|
||||
mutable Map<StringName, Action> input_map;
|
||||
|
||||
List<Ref<InputEvent> >::Element *_find_event(Action &p_action, const Ref<InputEvent> &p_event, bool *p_pressed = NULL, float *p_strength = NULL) const;
|
||||
List<Ref<InputEvent>>::Element *_find_event(Action &p_action, const Ref<InputEvent> &p_event, bool *p_pressed = NULL, float *p_strength = NULL) const;
|
||||
|
||||
Array _get_action_list(const StringName &p_action);
|
||||
Array _get_actions();
|
||||
|
@ -78,7 +78,7 @@ public:
|
|||
void action_erase_event(const StringName &p_action, const Ref<InputEvent> &p_event);
|
||||
void action_erase_events(const StringName &p_action);
|
||||
|
||||
const List<Ref<InputEvent> > *get_action_list(const StringName &p_action);
|
||||
const List<Ref<InputEvent>> *get_action_list(const StringName &p_action);
|
||||
bool event_is_action(const Ref<InputEvent> &p_event, const StringName &p_action) const;
|
||||
bool event_get_action_status(const Ref<InputEvent> &p_event, const StringName &p_action, bool *p_pressed = NULL, float *p_strength = NULL) const;
|
||||
|
||||
|
|
|
@ -106,7 +106,7 @@ bool ConfigFile::has_section_key(const String &p_section, const String &p_key) c
|
|||
|
||||
void ConfigFile::get_sections(List<String> *r_sections) const {
|
||||
|
||||
for (OrderedHashMap<String, OrderedHashMap<String, Variant> >::ConstElement E = values.front(); E; E = E.next()) {
|
||||
for (OrderedHashMap<String, OrderedHashMap<String, Variant>>::ConstElement E = values.front(); E; E = E.next()) {
|
||||
r_sections->push_back(E.key());
|
||||
}
|
||||
}
|
||||
|
@ -186,7 +186,7 @@ Error ConfigFile::save_encrypted_pass(const String &p_path, const String &p_pass
|
|||
|
||||
Error ConfigFile::_internal_save(FileAccess *file) {
|
||||
|
||||
for (OrderedHashMap<String, OrderedHashMap<String, Variant> >::Element E = values.front(); E; E = E.next()) {
|
||||
for (OrderedHashMap<String, OrderedHashMap<String, Variant>>::Element E = values.front(); E; E = E.next()) {
|
||||
|
||||
if (E != values.front())
|
||||
file->store_string("\n");
|
||||
|
|
|
@ -40,7 +40,7 @@ class ConfigFile : public Reference {
|
|||
|
||||
GDCLASS(ConfigFile, Reference);
|
||||
|
||||
OrderedHashMap<String, OrderedHashMap<String, Variant> > values;
|
||||
OrderedHashMap<String, OrderedHashMap<String, Variant>> values;
|
||||
|
||||
PoolStringArray _get_sections() const;
|
||||
PoolStringArray _get_section_keys(const String &p_section) const;
|
||||
|
|
|
@ -34,12 +34,12 @@
|
|||
#include "core/os/dir_access.h"
|
||||
#include "core/project_settings.h"
|
||||
|
||||
static Map<String, Vector<uint8_t> > *files = NULL;
|
||||
static Map<String, Vector<uint8_t>> *files = NULL;
|
||||
|
||||
void FileAccessMemory::register_file(String p_name, Vector<uint8_t> p_data) {
|
||||
|
||||
if (!files) {
|
||||
files = memnew((Map<String, Vector<uint8_t> >));
|
||||
files = memnew((Map<String, Vector<uint8_t>>));
|
||||
}
|
||||
|
||||
String name;
|
||||
|
@ -88,7 +88,7 @@ Error FileAccessMemory::_open(const String &p_path, int p_mode_flags) {
|
|||
String name = fix_path(p_path);
|
||||
//name = DirAccess::normalize_path(name);
|
||||
|
||||
Map<String, Vector<uint8_t> >::Element *E = files->find(name);
|
||||
Map<String, Vector<uint8_t>>::Element *E = files->find(name);
|
||||
ERR_FAIL_COND_V_MSG(!E, ERR_FILE_NOT_FOUND, "Can't find file '" + p_path + "'.");
|
||||
|
||||
data = E->get().ptrw();
|
||||
|
|
|
@ -389,7 +389,7 @@ Error HTTPClient::poll() {
|
|||
handshaking = true;
|
||||
} else {
|
||||
// We are already handshaking, which means we can use your already active SSL connection
|
||||
ssl = static_cast<Ref<StreamPeerSSL> >(connection);
|
||||
ssl = static_cast<Ref<StreamPeerSSL>>(connection);
|
||||
if (ssl.is_null()) {
|
||||
close();
|
||||
status = STATUS_SSL_HANDSHAKE_ERROR;
|
||||
|
|
|
@ -362,7 +362,7 @@ Ref<ResourceImporter> ResourceFormatImporter::get_importer_by_name(const String
|
|||
return Ref<ResourceImporter>();
|
||||
}
|
||||
|
||||
void ResourceFormatImporter::get_importers_for_extension(const String &p_extension, List<Ref<ResourceImporter> > *r_importers) {
|
||||
void ResourceFormatImporter::get_importers_for_extension(const String &p_extension, List<Ref<ResourceImporter>> *r_importers) {
|
||||
|
||||
for (int i = 0; i < importers.size(); i++) {
|
||||
List<String> local_exts;
|
||||
|
@ -375,7 +375,7 @@ void ResourceFormatImporter::get_importers_for_extension(const String &p_extensi
|
|||
}
|
||||
}
|
||||
|
||||
void ResourceFormatImporter::get_importers(List<Ref<ResourceImporter> > *r_importers) {
|
||||
void ResourceFormatImporter::get_importers(List<Ref<ResourceImporter>> *r_importers) {
|
||||
for (int i = 0; i < importers.size(); i++) {
|
||||
r_importers->push_back(importers[i]);
|
||||
}
|
||||
|
@ -429,7 +429,7 @@ bool ResourceFormatImporter::are_import_settings_valid(const String &p_path) con
|
|||
|
||||
String ResourceFormatImporter::get_import_settings_hash() const {
|
||||
|
||||
Vector<Ref<ResourceImporter> > sorted_importers = importers;
|
||||
Vector<Ref<ResourceImporter>> sorted_importers = importers;
|
||||
|
||||
sorted_importers.sort_custom<SortImporterByName>();
|
||||
|
||||
|
|
|
@ -54,7 +54,7 @@ class ResourceFormatImporter : public ResourceFormatLoader {
|
|||
bool operator()(const Ref<ResourceImporter> &p_a, const Ref<ResourceImporter> &p_b) const;
|
||||
};
|
||||
|
||||
Vector<Ref<ResourceImporter> > importers;
|
||||
Vector<Ref<ResourceImporter>> importers;
|
||||
|
||||
public:
|
||||
static ResourceFormatImporter *get_singleton() { return singleton; }
|
||||
|
@ -83,8 +83,8 @@ public:
|
|||
void remove_importer(const Ref<ResourceImporter> &p_importer) { importers.erase(p_importer); }
|
||||
Ref<ResourceImporter> get_importer_by_name(const String &p_name) const;
|
||||
Ref<ResourceImporter> get_importer_by_extension(const String &p_extension) const;
|
||||
void get_importers_for_extension(const String &p_extension, List<Ref<ResourceImporter> > *r_importers);
|
||||
void get_importers(List<Ref<ResourceImporter> > *r_importers);
|
||||
void get_importers_for_extension(const String &p_extension, List<Ref<ResourceImporter>> *r_importers);
|
||||
void get_importers(List<Ref<ResourceImporter>> *r_importers);
|
||||
|
||||
bool are_import_settings_valid(const String &p_path) const;
|
||||
String get_import_settings_hash() const;
|
||||
|
@ -126,7 +126,7 @@ public:
|
|||
|
||||
virtual Error import(const String &p_source_file, const String &p_save_path, const Map<StringName, Variant> &p_options, List<String> *r_platform_variants, List<String> *r_gen_files = NULL, Variant *r_metadata = NULL) = 0;
|
||||
|
||||
virtual Error import_group_file(const String &p_group_file, const Map<String, Map<StringName, Variant> > &p_source_file_options, const Map<String, String> &p_base_paths) { return ERR_UNAVAILABLE; }
|
||||
virtual Error import_group_file(const String &p_group_file, const Map<String, Map<StringName, Variant>> &p_source_file_options, const Map<String, String> &p_base_paths) { return ERR_UNAVAILABLE; }
|
||||
virtual bool are_import_settings_valid(const String &p_path) const { return true; }
|
||||
virtual String get_import_settings_string() const { return String(); }
|
||||
};
|
||||
|
|
|
@ -970,7 +970,7 @@ void ResourceLoader::add_custom_loaders() {
|
|||
|
||||
void ResourceLoader::remove_custom_loaders() {
|
||||
|
||||
Vector<Ref<ResourceFormatLoader> > custom_loaders;
|
||||
Vector<Ref<ResourceFormatLoader>> custom_loaders;
|
||||
for (int i = 0; i < loader_count; ++i) {
|
||||
if (loader[i]->get_script_instance()) {
|
||||
custom_loaders.push_back(loader[i]);
|
||||
|
@ -1005,7 +1005,7 @@ bool ResourceLoader::abort_on_missing_resource = true;
|
|||
bool ResourceLoader::timestamp_on_load = false;
|
||||
|
||||
SelfList<Resource>::List ResourceLoader::remapped_list;
|
||||
HashMap<String, Vector<String> > ResourceLoader::translation_remaps;
|
||||
HashMap<String, Vector<String>> ResourceLoader::translation_remaps;
|
||||
HashMap<String, String> ResourceLoader::path_remaps;
|
||||
|
||||
ResourceLoaderImport ResourceLoader::import = NULL;
|
||||
|
|
|
@ -104,7 +104,7 @@ class ResourceLoader {
|
|||
static void *dep_err_notify_ud;
|
||||
static DependencyErrorNotify dep_err_notify;
|
||||
static bool abort_on_missing_resource;
|
||||
static HashMap<String, Vector<String> > translation_remaps;
|
||||
static HashMap<String, Vector<String>> translation_remaps;
|
||||
static HashMap<String, String> path_remaps;
|
||||
|
||||
static String _path_remap(const String &p_path, bool *r_translation_remapped = NULL);
|
||||
|
|
|
@ -256,7 +256,7 @@ void ResourceSaver::add_custom_savers() {
|
|||
|
||||
void ResourceSaver::remove_custom_savers() {
|
||||
|
||||
Vector<Ref<ResourceFormatSaver> > custom_savers;
|
||||
Vector<Ref<ResourceFormatSaver>> custom_savers;
|
||||
for (int i = 0; i < saver_count; ++i) {
|
||||
if (saver[i]->get_script_instance()) {
|
||||
custom_savers.push_back(saver[i]);
|
||||
|
|
|
@ -600,7 +600,7 @@ public:
|
|||
|
||||
void sort() {
|
||||
|
||||
sort_custom<Comparator<T> >();
|
||||
sort_custom<Comparator<T>>();
|
||||
}
|
||||
|
||||
template <class C>
|
||||
|
@ -681,7 +681,7 @@ public:
|
|||
idx++;
|
||||
}
|
||||
|
||||
SortArray<Element *, AuxiliaryComparator<C> > sort;
|
||||
SortArray<Element *, AuxiliaryComparator<C>> sort;
|
||||
sort.sort(aux_buffer, s);
|
||||
|
||||
_data->first = aux_buffer[0];
|
||||
|
|
|
@ -197,7 +197,7 @@ public:
|
|||
}
|
||||
|
||||
void sort() {
|
||||
sort_custom<_DefaultComparator<T> >();
|
||||
sort_custom<_DefaultComparator<T>>();
|
||||
}
|
||||
|
||||
void ordered_insert(T p_val) {
|
||||
|
|
|
@ -217,9 +217,9 @@ static bool _group_face(_FaceClassify *p_faces, int len, int p_index, int p_grou
|
|||
return true;
|
||||
}
|
||||
|
||||
PoolVector<PoolVector<Face3> > Geometry::separate_objects(PoolVector<Face3> p_array) {
|
||||
PoolVector<PoolVector<Face3>> Geometry::separate_objects(PoolVector<Face3> p_array) {
|
||||
|
||||
PoolVector<PoolVector<Face3> > objects;
|
||||
PoolVector<PoolVector<Face3>> objects;
|
||||
|
||||
int len = p_array.size();
|
||||
|
||||
|
@ -242,7 +242,7 @@ PoolVector<PoolVector<Face3> > Geometry::separate_objects(PoolVector<Face3> p_ar
|
|||
|
||||
bool error = _connect_faces(_fcptr, len, -1);
|
||||
|
||||
ERR_FAIL_COND_V_MSG(error, PoolVector<PoolVector<Face3> >(), "Invalid geometry.");
|
||||
ERR_FAIL_COND_V_MSG(error, PoolVector<PoolVector<Face3>>(), "Invalid geometry.");
|
||||
|
||||
// Group connected faces in separate objects.
|
||||
|
||||
|
@ -266,7 +266,7 @@ PoolVector<PoolVector<Face3> > Geometry::separate_objects(PoolVector<Face3> p_ar
|
|||
if (group >= 0) {
|
||||
|
||||
objects.resize(group);
|
||||
PoolVector<PoolVector<Face3> >::Write obw = objects.write();
|
||||
PoolVector<PoolVector<Face3>>::Write obw = objects.write();
|
||||
PoolVector<Face3> *group_faces = obw.ptr();
|
||||
|
||||
for (int i = 0; i < len; i++) {
|
||||
|
@ -689,8 +689,8 @@ PoolVector<Face3> Geometry::wrap_geometry(PoolVector<Face3> p_array, real_t *p_e
|
|||
return wrapped_faces;
|
||||
}
|
||||
|
||||
Vector<Vector<Vector2> > Geometry::decompose_polygon_in_convex(Vector<Point2> polygon) {
|
||||
Vector<Vector<Vector2> > decomp;
|
||||
Vector<Vector<Vector2>> Geometry::decompose_polygon_in_convex(Vector<Point2> polygon) {
|
||||
Vector<Vector<Vector2>> decomp;
|
||||
List<TriangulatorPoly> in_poly, out_poly;
|
||||
|
||||
TriangulatorPoly inp;
|
||||
|
@ -1093,7 +1093,7 @@ void Geometry::make_atlas(const Vector<Size2i> &p_rects, Vector<Point2i> &r_resu
|
|||
r_size = Size2(results[best].max_w, results[best].max_h);
|
||||
}
|
||||
|
||||
Vector<Vector<Point2> > Geometry::_polypaths_do_operation(PolyBooleanOperation p_op, const Vector<Point2> &p_polypath_a, const Vector<Point2> &p_polypath_b, bool is_a_open) {
|
||||
Vector<Vector<Point2>> Geometry::_polypaths_do_operation(PolyBooleanOperation p_op, const Vector<Point2> &p_polypath_a, const Vector<Point2> &p_polypath_b, bool is_a_open) {
|
||||
|
||||
using namespace ClipperLib;
|
||||
|
||||
|
@ -1128,7 +1128,7 @@ Vector<Vector<Point2> > Geometry::_polypaths_do_operation(PolyBooleanOperation p
|
|||
clp.Execute(op, paths); // Works on closed polygons only.
|
||||
}
|
||||
// Have to scale points down now.
|
||||
Vector<Vector<Point2> > polypaths;
|
||||
Vector<Vector<Point2>> polypaths;
|
||||
|
||||
for (Paths::size_type i = 0; i < paths.size(); ++i) {
|
||||
Vector<Vector2> polypath;
|
||||
|
@ -1145,7 +1145,7 @@ Vector<Vector<Point2> > Geometry::_polypaths_do_operation(PolyBooleanOperation p
|
|||
return polypaths;
|
||||
}
|
||||
|
||||
Vector<Vector<Point2> > Geometry::_polypath_offset(const Vector<Point2> &p_polypath, real_t p_delta, PolyJoinType p_join_type, PolyEndType p_end_type) {
|
||||
Vector<Vector<Point2>> Geometry::_polypath_offset(const Vector<Point2> &p_polypath, real_t p_delta, PolyJoinType p_join_type, PolyEndType p_end_type) {
|
||||
|
||||
using namespace ClipperLib;
|
||||
|
||||
|
@ -1179,7 +1179,7 @@ Vector<Vector<Point2> > Geometry::_polypath_offset(const Vector<Point2> &p_polyp
|
|||
co.Execute(paths, p_delta * SCALE_FACTOR); // Inflate/deflate.
|
||||
|
||||
// Have to scale points down now.
|
||||
Vector<Vector<Point2> > polypaths;
|
||||
Vector<Vector<Point2>> polypaths;
|
||||
|
||||
for (Paths::size_type i = 0; i < paths.size(); ++i) {
|
||||
Vector<Vector2> polypath;
|
||||
|
|
|
@ -820,44 +820,44 @@ public:
|
|||
END_ROUND
|
||||
};
|
||||
|
||||
static Vector<Vector<Point2> > merge_polygons_2d(const Vector<Point2> &p_polygon_a, const Vector<Point2> &p_polygon_b) {
|
||||
static Vector<Vector<Point2>> merge_polygons_2d(const Vector<Point2> &p_polygon_a, const Vector<Point2> &p_polygon_b) {
|
||||
|
||||
return _polypaths_do_operation(OPERATION_UNION, p_polygon_a, p_polygon_b);
|
||||
}
|
||||
|
||||
static Vector<Vector<Point2> > clip_polygons_2d(const Vector<Point2> &p_polygon_a, const Vector<Point2> &p_polygon_b) {
|
||||
static Vector<Vector<Point2>> clip_polygons_2d(const Vector<Point2> &p_polygon_a, const Vector<Point2> &p_polygon_b) {
|
||||
|
||||
return _polypaths_do_operation(OPERATION_DIFFERENCE, p_polygon_a, p_polygon_b);
|
||||
}
|
||||
|
||||
static Vector<Vector<Point2> > intersect_polygons_2d(const Vector<Point2> &p_polygon_a, const Vector<Point2> &p_polygon_b) {
|
||||
static Vector<Vector<Point2>> intersect_polygons_2d(const Vector<Point2> &p_polygon_a, const Vector<Point2> &p_polygon_b) {
|
||||
|
||||
return _polypaths_do_operation(OPERATION_INTERSECTION, p_polygon_a, p_polygon_b);
|
||||
}
|
||||
|
||||
static Vector<Vector<Point2> > exclude_polygons_2d(const Vector<Point2> &p_polygon_a, const Vector<Point2> &p_polygon_b) {
|
||||
static Vector<Vector<Point2>> exclude_polygons_2d(const Vector<Point2> &p_polygon_a, const Vector<Point2> &p_polygon_b) {
|
||||
|
||||
return _polypaths_do_operation(OPERATION_XOR, p_polygon_a, p_polygon_b);
|
||||
}
|
||||
|
||||
static Vector<Vector<Point2> > clip_polyline_with_polygon_2d(const Vector<Vector2> &p_polyline, const Vector<Vector2> &p_polygon) {
|
||||
static Vector<Vector<Point2>> clip_polyline_with_polygon_2d(const Vector<Vector2> &p_polyline, const Vector<Vector2> &p_polygon) {
|
||||
|
||||
return _polypaths_do_operation(OPERATION_DIFFERENCE, p_polyline, p_polygon, true);
|
||||
}
|
||||
|
||||
static Vector<Vector<Point2> > intersect_polyline_with_polygon_2d(const Vector<Vector2> &p_polyline, const Vector<Vector2> &p_polygon) {
|
||||
static Vector<Vector<Point2>> intersect_polyline_with_polygon_2d(const Vector<Vector2> &p_polyline, const Vector<Vector2> &p_polygon) {
|
||||
|
||||
return _polypaths_do_operation(OPERATION_INTERSECTION, p_polyline, p_polygon, true);
|
||||
}
|
||||
|
||||
static Vector<Vector<Point2> > offset_polygon_2d(const Vector<Vector2> &p_polygon, real_t p_delta, PolyJoinType p_join_type) {
|
||||
static Vector<Vector<Point2>> offset_polygon_2d(const Vector<Vector2> &p_polygon, real_t p_delta, PolyJoinType p_join_type) {
|
||||
|
||||
return _polypath_offset(p_polygon, p_delta, p_join_type, END_POLYGON);
|
||||
}
|
||||
|
||||
static Vector<Vector<Point2> > offset_polyline_2d(const Vector<Vector2> &p_polygon, real_t p_delta, PolyJoinType p_join_type, PolyEndType p_end_type) {
|
||||
static Vector<Vector<Point2>> offset_polyline_2d(const Vector<Vector2> &p_polygon, real_t p_delta, PolyJoinType p_join_type, PolyEndType p_end_type) {
|
||||
|
||||
ERR_FAIL_COND_V_MSG(p_end_type == END_POLYGON, Vector<Vector<Point2> >(), "Attempt to offset a polyline like a polygon (use offset_polygon_2d instead).");
|
||||
ERR_FAIL_COND_V_MSG(p_end_type == END_POLYGON, Vector<Vector<Point2>>(), "Attempt to offset a polyline like a polygon (use offset_polygon_2d instead).");
|
||||
|
||||
return _polypath_offset(p_polygon, p_delta, p_join_type, p_end_type);
|
||||
}
|
||||
|
@ -929,7 +929,7 @@ public:
|
|||
return (intersections & 1);
|
||||
}
|
||||
|
||||
static PoolVector<PoolVector<Face3> > separate_objects(PoolVector<Face3> p_array);
|
||||
static PoolVector<PoolVector<Face3>> separate_objects(PoolVector<Face3> p_array);
|
||||
|
||||
// Create a "wrap" that encloses the given geometry.
|
||||
static PoolVector<Face3> wrap_geometry(PoolVector<Face3> p_array, real_t *p_error = NULL);
|
||||
|
@ -1034,7 +1034,7 @@ public:
|
|||
H.resize(k);
|
||||
return H;
|
||||
}
|
||||
static Vector<Vector<Vector2> > decompose_polygon_in_convex(Vector<Point2> polygon);
|
||||
static Vector<Vector<Vector2>> decompose_polygon_in_convex(Vector<Point2> polygon);
|
||||
|
||||
static MeshData build_convex_mesh(const PoolVector<Plane> &p_planes);
|
||||
static PoolVector<Plane> build_sphere_planes(real_t p_radius, int p_lats, int p_lons, Vector3::Axis p_axis = Vector3::AXIS_Z);
|
||||
|
@ -1054,8 +1054,8 @@ public:
|
|||
static Vector<Vector3> compute_convex_mesh_points(const Plane *p_planes, int p_plane_count);
|
||||
|
||||
private:
|
||||
static Vector<Vector<Point2> > _polypaths_do_operation(PolyBooleanOperation p_op, const Vector<Point2> &p_polypath_a, const Vector<Point2> &p_polypath_b, bool is_a_open = false);
|
||||
static Vector<Vector<Point2> > _polypath_offset(const Vector<Point2> &p_polypath, real_t p_delta, PolyJoinType p_join_type, PolyEndType p_end_type);
|
||||
static Vector<Vector<Point2>> _polypaths_do_operation(PolyBooleanOperation p_op, const Vector<Point2> &p_polypath_a, const Vector<Point2> &p_polypath_b, bool is_a_open = false);
|
||||
static Vector<Vector<Point2>> _polypath_offset(const Vector<Point2> &p_polypath, real_t p_delta, PolyJoinType p_join_type, PolyEndType p_end_type);
|
||||
};
|
||||
|
||||
#endif
|
||||
|
|
|
@ -171,7 +171,7 @@ struct PtrToArg<const T *> {
|
|||
|
||||
#define MAKE_VECARG(m_type) \
|
||||
template <> \
|
||||
struct PtrToArg<Vector<m_type> > { \
|
||||
struct PtrToArg<Vector<m_type>> { \
|
||||
_FORCE_INLINE_ static Vector<m_type> convert(const void *p_ptr) { \
|
||||
const PoolVector<m_type> *dvs = reinterpret_cast<const PoolVector<m_type> *>(p_ptr); \
|
||||
Vector<m_type> ret; \
|
||||
|
@ -216,7 +216,7 @@ struct PtrToArg<const T *> {
|
|||
|
||||
#define MAKE_VECARG_ALT(m_type, m_type_alt) \
|
||||
template <> \
|
||||
struct PtrToArg<Vector<m_type_alt> > { \
|
||||
struct PtrToArg<Vector<m_type_alt>> { \
|
||||
_FORCE_INLINE_ static Vector<m_type_alt> convert(const void *p_ptr) { \
|
||||
const PoolVector<m_type> *dvs = reinterpret_cast<const PoolVector<m_type> *>(p_ptr); \
|
||||
Vector<m_type_alt> ret; \
|
||||
|
@ -270,7 +270,7 @@ MAKE_VECARG_ALT(String, StringName);
|
|||
//for stuff that gets converted to Array vectors
|
||||
#define MAKE_VECARR(m_type) \
|
||||
template <> \
|
||||
struct PtrToArg<Vector<m_type> > { \
|
||||
struct PtrToArg<Vector<m_type>> { \
|
||||
_FORCE_INLINE_ static Vector<m_type> convert(const void *p_ptr) { \
|
||||
const Array *arr = reinterpret_cast<const Array *>(p_ptr); \
|
||||
Vector<m_type> ret; \
|
||||
|
@ -310,7 +310,7 @@ MAKE_VECARR(Plane);
|
|||
|
||||
#define MAKE_DVECARR(m_type) \
|
||||
template <> \
|
||||
struct PtrToArg<PoolVector<m_type> > { \
|
||||
struct PtrToArg<PoolVector<m_type>> { \
|
||||
_FORCE_INLINE_ static PoolVector<m_type> convert(const void *p_ptr) { \
|
||||
const Array *arr = reinterpret_cast<const Array *>(p_ptr); \
|
||||
PoolVector<m_type> ret; \
|
||||
|
@ -402,7 +402,7 @@ MAKE_STRINGCONV(StringName);
|
|||
MAKE_STRINGCONV_BY_REFERENCE(IP_Address);
|
||||
|
||||
template <>
|
||||
struct PtrToArg<PoolVector<Face3> > {
|
||||
struct PtrToArg<PoolVector<Face3>> {
|
||||
_FORCE_INLINE_ static PoolVector<Face3> convert(const void *p_ptr) {
|
||||
const PoolVector<Vector3> *dvs = reinterpret_cast<const PoolVector<Vector3> *>(p_ptr);
|
||||
PoolVector<Face3> ret;
|
||||
|
|
|
@ -50,7 +50,7 @@
|
|||
*/
|
||||
template <class TKey, class TValue,
|
||||
class Hasher = HashMapHasherDefault,
|
||||
class Comparator = HashMapComparatorDefault<TKey> >
|
||||
class Comparator = HashMapComparatorDefault<TKey>>
|
||||
class OAHashMap {
|
||||
|
||||
private:
|
||||
|
|
|
@ -45,7 +45,7 @@
|
|||
*/
|
||||
template <class K, class V, class Hasher = HashMapHasherDefault, class Comparator = HashMapComparatorDefault<K>, uint8_t MIN_HASH_TABLE_POWER = 3, uint8_t RELATIONSHIP = 8>
|
||||
class OrderedHashMap {
|
||||
typedef List<Pair<const K *, V> > InternalList;
|
||||
typedef List<Pair<const K *, V>> InternalList;
|
||||
typedef HashMap<K, typename InternalList::Element *, Hasher, Comparator, MIN_HASH_TABLE_POWER, RELATIONSHIP> InternalMap;
|
||||
|
||||
InternalList list;
|
||||
|
|
|
@ -79,7 +79,7 @@ void thread_process_array(uint32_t p_elements, C *p_instance, M p_method, U p_us
|
|||
Thread *threads = memnew_arr(Thread, thread_count);
|
||||
|
||||
for (int i = 0; i < thread_count; i++) {
|
||||
threads[i].start(process_array_thread<ThreadArrayProcessData<C, U> >, &data);
|
||||
threads[i].start(process_array_thread<ThreadArrayProcessData<C, U>>, &data);
|
||||
}
|
||||
|
||||
for (int i = 0; i < thread_count; i++) {
|
||||
|
|
|
@ -667,7 +667,7 @@ Error ProjectSettings::save() {
|
|||
return error;
|
||||
}
|
||||
|
||||
Error ProjectSettings::_save_settings_binary(const String &p_file, const Map<String, List<String> > &props, const CustomMap &p_custom, const String &p_custom_features) {
|
||||
Error ProjectSettings::_save_settings_binary(const String &p_file, const Map<String, List<String>> &props, const CustomMap &p_custom, const String &p_custom_features) {
|
||||
|
||||
Error err;
|
||||
FileAccess *file = FileAccess::open(p_file, FileAccess::WRITE, &err);
|
||||
|
@ -678,7 +678,7 @@ Error ProjectSettings::_save_settings_binary(const String &p_file, const Map<Str
|
|||
|
||||
int count = 0;
|
||||
|
||||
for (Map<String, List<String> >::Element *E = props.front(); E; E = E->next()) {
|
||||
for (Map<String, List<String>>::Element *E = props.front(); E; E = E->next()) {
|
||||
|
||||
for (List<String>::Element *F = E->get().front(); F; F = F->next()) {
|
||||
|
||||
|
@ -715,7 +715,7 @@ Error ProjectSettings::_save_settings_binary(const String &p_file, const Map<Str
|
|||
file->store_32(count); //store how many properties are saved
|
||||
}
|
||||
|
||||
for (Map<String, List<String> >::Element *E = props.front(); E; E = E->next()) {
|
||||
for (Map<String, List<String>>::Element *E = props.front(); E; E = E->next()) {
|
||||
|
||||
for (List<String>::Element *F = E->get().front(); F; F = F->next()) {
|
||||
|
||||
|
@ -755,7 +755,7 @@ Error ProjectSettings::_save_settings_binary(const String &p_file, const Map<Str
|
|||
return OK;
|
||||
}
|
||||
|
||||
Error ProjectSettings::_save_settings_text(const String &p_file, const Map<String, List<String> > &props, const CustomMap &p_custom, const String &p_custom_features) {
|
||||
Error ProjectSettings::_save_settings_text(const String &p_file, const Map<String, List<String>> &props, const CustomMap &p_custom, const String &p_custom_features) {
|
||||
|
||||
Error err;
|
||||
FileAccess *file = FileAccess::open(p_file, FileAccess::WRITE, &err);
|
||||
|
@ -776,7 +776,7 @@ Error ProjectSettings::_save_settings_text(const String &p_file, const Map<Strin
|
|||
file->store_string("custom_features=\"" + p_custom_features + "\"\n");
|
||||
file->store_string("\n");
|
||||
|
||||
for (Map<String, List<String> >::Element *E = props.front(); E; E = E->next()) {
|
||||
for (Map<String, List<String>>::Element *E = props.front(); E; E = E->next()) {
|
||||
|
||||
if (E != props.front())
|
||||
file->store_string("\n");
|
||||
|
@ -853,7 +853,7 @@ Error ProjectSettings::save_custom(const String &p_path, const CustomMap &p_cust
|
|||
vclist.insert(vc);
|
||||
}
|
||||
|
||||
Map<String, List<String> > props;
|
||||
Map<String, List<String>> props;
|
||||
|
||||
for (Set<_VCSort>::Element *E = vclist.front(); E; E = E->next()) {
|
||||
|
||||
|
|
|
@ -98,8 +98,8 @@ protected:
|
|||
Error _load_settings_binary(const String &p_path);
|
||||
Error _load_settings_text_or_binary(const String &p_text_path, const String &p_bin_path);
|
||||
|
||||
Error _save_settings_text(const String &p_file, const Map<String, List<String> > &props, const CustomMap &p_custom = CustomMap(), const String &p_custom_features = String());
|
||||
Error _save_settings_binary(const String &p_file, const Map<String, List<String> > &props, const CustomMap &p_custom = CustomMap(), const String &p_custom_features = String());
|
||||
Error _save_settings_text(const String &p_file, const Map<String, List<String>> &props, const CustomMap &p_custom = CustomMap(), const String &p_custom_features = String());
|
||||
Error _save_settings_binary(const String &p_file, const Map<String, List<String>> &props, const CustomMap &p_custom = CustomMap(), const String &p_custom_features = String());
|
||||
|
||||
Error _save_custom_bnd(const String &p_file);
|
||||
|
||||
|
|
|
@ -318,7 +318,7 @@ public:
|
|||
#ifdef PTRCALL_ENABLED
|
||||
|
||||
template <class T>
|
||||
struct PtrToArg<Ref<T> > {
|
||||
struct PtrToArg<Ref<T>> {
|
||||
|
||||
_FORCE_INLINE_ static Ref<T> convert(const void *p_ptr) {
|
||||
|
||||
|
@ -371,7 +371,7 @@ struct PtrToArg<const RefPtr &> {
|
|||
#ifdef DEBUG_METHODS_ENABLED
|
||||
|
||||
template <class T>
|
||||
struct GetTypeInfo<Ref<T> > {
|
||||
struct GetTypeInfo<Ref<T>> {
|
||||
static const Variant::Type VARIANT_TYPE = Variant::OBJECT;
|
||||
static const GodotTypeInfo::Metadata METADATA = GodotTypeInfo::METADATA_NONE;
|
||||
|
||||
|
|
|
@ -150,7 +150,7 @@ void Resource::reload_from_file() {
|
|||
}
|
||||
}
|
||||
|
||||
Ref<Resource> Resource::duplicate_for_local_scene(Node *p_for_scene, Map<Ref<Resource>, Ref<Resource> > &remap_cache) {
|
||||
Ref<Resource> Resource::duplicate_for_local_scene(Node *p_for_scene, Map<Ref<Resource>, Ref<Resource>> &remap_cache) {
|
||||
|
||||
List<PropertyInfo> plist;
|
||||
get_property_list(&plist);
|
||||
|
@ -189,7 +189,7 @@ Ref<Resource> Resource::duplicate_for_local_scene(Node *p_for_scene, Map<Ref<Res
|
|||
return r;
|
||||
}
|
||||
|
||||
void Resource::configure_for_local_scene(Node *p_for_scene, Map<Ref<Resource>, Ref<Resource> > &remap_cache) {
|
||||
void Resource::configure_for_local_scene(Node *p_for_scene, Map<Ref<Resource>, Ref<Resource>> &remap_cache) {
|
||||
|
||||
List<PropertyInfo> plist;
|
||||
get_property_list(&plist);
|
||||
|
@ -437,7 +437,7 @@ Resource::~Resource() {
|
|||
|
||||
HashMap<String, Resource *> ResourceCache::resources;
|
||||
#ifdef TOOLS_ENABLED
|
||||
HashMap<String, HashMap<String, int> > ResourceCache::resource_path_cache;
|
||||
HashMap<String, HashMap<String, int>> ResourceCache::resource_path_cache;
|
||||
#endif
|
||||
|
||||
RWLock ResourceCache::lock;
|
||||
|
@ -486,7 +486,7 @@ Resource *ResourceCache::get(const String &p_path) {
|
|||
return *res;
|
||||
}
|
||||
|
||||
void ResourceCache::get_cached_resources(List<Ref<Resource> > *p_resources) {
|
||||
void ResourceCache::get_cached_resources(List<Ref<Resource>> *p_resources) {
|
||||
|
||||
lock.read_lock();
|
||||
const String *K = NULL;
|
||||
|
|
|
@ -104,8 +104,8 @@ public:
|
|||
int get_subindex() const;
|
||||
|
||||
virtual Ref<Resource> duplicate(bool p_subresources = false) const;
|
||||
Ref<Resource> duplicate_for_local_scene(Node *p_for_scene, Map<Ref<Resource>, Ref<Resource> > &remap_cache);
|
||||
void configure_for_local_scene(Node *p_for_scene, Map<Ref<Resource>, Ref<Resource> > &remap_cache);
|
||||
Ref<Resource> duplicate_for_local_scene(Node *p_for_scene, Map<Ref<Resource>, Ref<Resource>> &remap_cache);
|
||||
void configure_for_local_scene(Node *p_for_scene, Map<Ref<Resource>, Ref<Resource>> &remap_cache);
|
||||
|
||||
void set_local_to_scene(bool p_enable);
|
||||
bool is_local_to_scene() const;
|
||||
|
@ -151,7 +151,7 @@ class ResourceCache {
|
|||
static RWLock lock;
|
||||
static HashMap<String, Resource *> resources;
|
||||
#ifdef TOOLS_ENABLED
|
||||
static HashMap<String, HashMap<String, int> > resource_path_cache; // each tscn has a set of resource paths and IDs
|
||||
static HashMap<String, HashMap<String, int>> resource_path_cache; // each tscn has a set of resource paths and IDs
|
||||
static RWLock path_cache_lock;
|
||||
#endif // TOOLS_ENABLED
|
||||
friend void unregister_core_types();
|
||||
|
@ -163,7 +163,7 @@ public:
|
|||
static bool has(const String &p_path);
|
||||
static Resource *get(const String &p_path);
|
||||
static void dump(const char *p_file = NULL, bool p_short = false);
|
||||
static void get_cached_resources(List<Ref<Resource> > *p_resources);
|
||||
static void get_cached_resources(List<Ref<Resource>> *p_resources);
|
||||
static int get_cached_resource_count();
|
||||
};
|
||||
|
||||
|
|
|
@ -52,7 +52,7 @@
|
|||
#define SAFE_NUMERIC_TYPE_PUN_GUARANTEES(m_type) \
|
||||
static_assert(sizeof(SafeNumeric<m_type>) == sizeof(m_type), ""); \
|
||||
static_assert(alignof(SafeNumeric<m_type>) == alignof(m_type), ""); \
|
||||
static_assert(std::is_trivially_destructible<std::atomic<m_type> >::value, "");
|
||||
static_assert(std::is_trivially_destructible<std::atomic<m_type>>::value, "");
|
||||
|
||||
#if defined(DEBUG_ENABLED)
|
||||
void check_lockless_atomics();
|
||||
|
|
|
@ -178,14 +178,14 @@ void ScriptDebuggerLocal::debug(ScriptLanguage *p_script, bool p_can_continue, b
|
|||
|
||||
if (line.get_slice_count(" ") <= 1) {
|
||||
|
||||
const Map<int, Set<StringName> > &breakpoints = get_breakpoints();
|
||||
const Map<int, Set<StringName>> &breakpoints = get_breakpoints();
|
||||
if (breakpoints.size() == 0) {
|
||||
print_line("No Breakpoints.");
|
||||
continue;
|
||||
}
|
||||
|
||||
print_line("Breakpoint(s): " + itos(breakpoints.size()));
|
||||
for (Map<int, Set<StringName> >::Element *E = breakpoints.front(); E; E = E->next()) {
|
||||
for (Map<int, Set<StringName>>::Element *E = breakpoints.front(); E; E = E->next()) {
|
||||
print_line("\t" + String(E->value().front()->get()) + ":" + itos(E->key()));
|
||||
}
|
||||
|
||||
|
|
|
@ -295,7 +295,7 @@ void ScriptServer::save_global_classes() {
|
|||
}
|
||||
|
||||
////////////////////
|
||||
void ScriptInstance::get_property_state(List<Pair<StringName, Variant> > &state) {
|
||||
void ScriptInstance::get_property_state(List<Pair<StringName, Variant>> &state) {
|
||||
|
||||
List<PropertyInfo> pinfo;
|
||||
get_property_list(&pinfo);
|
||||
|
|
|
@ -165,7 +165,7 @@ public:
|
|||
virtual Variant::Type get_property_type(const StringName &p_name, bool *r_is_valid = NULL) const = 0;
|
||||
|
||||
virtual Object *get_owner() { return NULL; }
|
||||
virtual void get_property_state(List<Pair<StringName, Variant> > &state);
|
||||
virtual void get_property_state(List<Pair<StringName, Variant>> &state);
|
||||
|
||||
virtual void get_method_list(List<MethodInfo> *p_list) const = 0;
|
||||
virtual bool has_method(const StringName &p_method) const = 0;
|
||||
|
@ -341,7 +341,7 @@ public:
|
|||
|
||||
virtual void get_recognized_extensions(List<String> *p_extensions) const = 0;
|
||||
virtual void get_public_functions(List<MethodInfo> *p_functions) const = 0;
|
||||
virtual void get_public_constants(List<Pair<String, Variant> > *p_constants) const = 0;
|
||||
virtual void get_public_constants(List<Pair<String, Variant>> *p_constants) const = 0;
|
||||
|
||||
struct ProfilingInfo {
|
||||
StringName signature;
|
||||
|
@ -423,7 +423,7 @@ class ScriptDebugger {
|
|||
int depth;
|
||||
|
||||
static ScriptDebugger *singleton;
|
||||
Map<int, Set<StringName> > breakpoints;
|
||||
Map<int, Set<StringName>> breakpoints;
|
||||
|
||||
ScriptLanguage *break_lang;
|
||||
|
||||
|
@ -441,7 +441,7 @@ public:
|
|||
bool is_breakpoint(int p_line, const StringName &p_source) const;
|
||||
bool is_breakpoint_line(int p_line) const;
|
||||
void clear_breakpoints();
|
||||
const Map<int, Set<StringName> > &get_breakpoints() const { return breakpoints; }
|
||||
const Map<int, Set<StringName>> &get_breakpoints() const { return breakpoints; }
|
||||
|
||||
virtual void debug(ScriptLanguage *p_script, bool p_can_continue = true, bool p_is_error_breakpoint = false) = 0;
|
||||
virtual void idle_poll();
|
||||
|
|
|
@ -1008,7 +1008,7 @@ String TranslationServer::get_locale_name(const String &p_locale) const {
|
|||
|
||||
Array TranslationServer::get_loaded_locales() const {
|
||||
Array locales;
|
||||
for (const Set<Ref<Translation> >::Element *E = translations.front(); E; E = E->next()) {
|
||||
for (const Set<Ref<Translation>>::Element *E = translations.front(); E; E = E->next()) {
|
||||
|
||||
const Ref<Translation> &t = E->get();
|
||||
ERR_FAIL_COND_V(t.is_null(), Array());
|
||||
|
@ -1085,7 +1085,7 @@ StringName TranslationServer::translate(const StringName &p_message) const {
|
|||
String lang = get_language_code(locale);
|
||||
bool near_match = false;
|
||||
|
||||
for (const Set<Ref<Translation> >::Element *E = translations.front(); E; E = E->next()) {
|
||||
for (const Set<Ref<Translation>>::Element *E = translations.front(); E; E = E->next()) {
|
||||
const Ref<Translation> &t = E->get();
|
||||
ERR_FAIL_COND_V(t.is_null(), p_message);
|
||||
String l = t->get_locale();
|
||||
|
@ -1118,7 +1118,7 @@ StringName TranslationServer::translate(const StringName &p_message) const {
|
|||
String fallback_lang = get_language_code(fallback);
|
||||
near_match = false;
|
||||
|
||||
for (const Set<Ref<Translation> >::Element *E = translations.front(); E; E = E->next()) {
|
||||
for (const Set<Ref<Translation>>::Element *E = translations.front(); E; E = E->next()) {
|
||||
const Ref<Translation> &t = E->get();
|
||||
ERR_FAIL_COND_V(t.is_null(), p_message);
|
||||
String l = t->get_locale();
|
||||
|
|
|
@ -71,7 +71,7 @@ class TranslationServer : public Object {
|
|||
String locale;
|
||||
String fallback;
|
||||
|
||||
Set<Ref<Translation> > translations;
|
||||
Set<Ref<Translation>> translations;
|
||||
Ref<Translation> tool_translation;
|
||||
|
||||
Map<String, String> locale_name_map;
|
||||
|
|
|
@ -208,7 +208,7 @@ struct GetTypeInfo<const Variant &> {
|
|||
|
||||
#define MAKE_TEMPLATE_TYPE_INFO(m_template, m_type, m_var_type) \
|
||||
template <> \
|
||||
struct GetTypeInfo<m_template<m_type> > { \
|
||||
struct GetTypeInfo<m_template<m_type>> { \
|
||||
static const Variant::Type VARIANT_TYPE = m_var_type; \
|
||||
static const GodotTypeInfo::Metadata METADATA = GodotTypeInfo::METADATA_NONE; \
|
||||
static inline PropertyInfo get_class_info() { \
|
||||
|
|
|
@ -1855,25 +1855,25 @@ inline DA _convert_array_from_variant(const Variant &p_variant) {
|
|||
return _convert_array<DA, Array>(p_variant.operator Array());
|
||||
}
|
||||
case Variant::POOL_BYTE_ARRAY: {
|
||||
return _convert_array<DA, PoolVector<uint8_t> >(p_variant.operator PoolVector<uint8_t>());
|
||||
return _convert_array<DA, PoolVector<uint8_t>>(p_variant.operator PoolVector<uint8_t>());
|
||||
}
|
||||
case Variant::POOL_INT_ARRAY: {
|
||||
return _convert_array<DA, PoolVector<int> >(p_variant.operator PoolVector<int>());
|
||||
return _convert_array<DA, PoolVector<int>>(p_variant.operator PoolVector<int>());
|
||||
}
|
||||
case Variant::POOL_REAL_ARRAY: {
|
||||
return _convert_array<DA, PoolVector<real_t> >(p_variant.operator PoolVector<real_t>());
|
||||
return _convert_array<DA, PoolVector<real_t>>(p_variant.operator PoolVector<real_t>());
|
||||
}
|
||||
case Variant::POOL_STRING_ARRAY: {
|
||||
return _convert_array<DA, PoolVector<String> >(p_variant.operator PoolVector<String>());
|
||||
return _convert_array<DA, PoolVector<String>>(p_variant.operator PoolVector<String>());
|
||||
}
|
||||
case Variant::POOL_VECTOR2_ARRAY: {
|
||||
return _convert_array<DA, PoolVector<Vector2> >(p_variant.operator PoolVector<Vector2>());
|
||||
return _convert_array<DA, PoolVector<Vector2>>(p_variant.operator PoolVector<Vector2>());
|
||||
}
|
||||
case Variant::POOL_VECTOR3_ARRAY: {
|
||||
return _convert_array<DA, PoolVector<Vector3> >(p_variant.operator PoolVector<Vector3>());
|
||||
return _convert_array<DA, PoolVector<Vector3>>(p_variant.operator PoolVector<Vector3>());
|
||||
}
|
||||
case Variant::POOL_COLOR_ARRAY: {
|
||||
return _convert_array<DA, PoolVector<Color> >(p_variant.operator PoolVector<Color>());
|
||||
return _convert_array<DA, PoolVector<Color>>(p_variant.operator PoolVector<Color>());
|
||||
}
|
||||
default: {
|
||||
return DA();
|
||||
|
@ -1894,21 +1894,21 @@ Variant::operator PoolVector<uint8_t>() const {
|
|||
if (type == POOL_BYTE_ARRAY)
|
||||
return *reinterpret_cast<const PoolVector<uint8_t> *>(_data._mem);
|
||||
else
|
||||
return _convert_array_from_variant<PoolVector<uint8_t> >(*this);
|
||||
return _convert_array_from_variant<PoolVector<uint8_t>>(*this);
|
||||
}
|
||||
Variant::operator PoolVector<int>() const {
|
||||
|
||||
if (type == POOL_INT_ARRAY)
|
||||
return *reinterpret_cast<const PoolVector<int> *>(_data._mem);
|
||||
else
|
||||
return _convert_array_from_variant<PoolVector<int> >(*this);
|
||||
return _convert_array_from_variant<PoolVector<int>>(*this);
|
||||
}
|
||||
Variant::operator PoolVector<real_t>() const {
|
||||
|
||||
if (type == POOL_REAL_ARRAY)
|
||||
return *reinterpret_cast<const PoolVector<real_t> *>(_data._mem);
|
||||
else
|
||||
return _convert_array_from_variant<PoolVector<real_t> >(*this);
|
||||
return _convert_array_from_variant<PoolVector<real_t>>(*this);
|
||||
}
|
||||
|
||||
Variant::operator PoolVector<String>() const {
|
||||
|
@ -1916,21 +1916,21 @@ Variant::operator PoolVector<String>() const {
|
|||
if (type == POOL_STRING_ARRAY)
|
||||
return *reinterpret_cast<const PoolVector<String> *>(_data._mem);
|
||||
else
|
||||
return _convert_array_from_variant<PoolVector<String> >(*this);
|
||||
return _convert_array_from_variant<PoolVector<String>>(*this);
|
||||
}
|
||||
Variant::operator PoolVector<Vector3>() const {
|
||||
|
||||
if (type == POOL_VECTOR3_ARRAY)
|
||||
return *reinterpret_cast<const PoolVector<Vector3> *>(_data._mem);
|
||||
else
|
||||
return _convert_array_from_variant<PoolVector<Vector3> >(*this);
|
||||
return _convert_array_from_variant<PoolVector<Vector3>>(*this);
|
||||
}
|
||||
Variant::operator PoolVector<Vector2>() const {
|
||||
|
||||
if (type == POOL_VECTOR2_ARRAY)
|
||||
return *reinterpret_cast<const PoolVector<Vector2> *>(_data._mem);
|
||||
else
|
||||
return _convert_array_from_variant<PoolVector<Vector2> >(*this);
|
||||
return _convert_array_from_variant<PoolVector<Vector2>>(*this);
|
||||
}
|
||||
|
||||
Variant::operator PoolVector<Color>() const {
|
||||
|
@ -1938,7 +1938,7 @@ Variant::operator PoolVector<Color>() const {
|
|||
if (type == POOL_COLOR_ARRAY)
|
||||
return *reinterpret_cast<const PoolVector<Color> *>(_data._mem);
|
||||
else
|
||||
return _convert_array_from_variant<PoolVector<Color> >(*this);
|
||||
return _convert_array_from_variant<PoolVector<Color>>(*this);
|
||||
}
|
||||
|
||||
/* helpers */
|
||||
|
|
|
@ -102,7 +102,7 @@ public:
|
|||
|
||||
void sort() {
|
||||
|
||||
sort_custom<_DefaultComparator<T> >();
|
||||
sort_custom<_DefaultComparator<T>>();
|
||||
}
|
||||
|
||||
void ordered_insert(const T &p_val) {
|
||||
|
|
|
@ -138,7 +138,7 @@ public:
|
|||
PoolVector<uint8_t> index_array;
|
||||
int index_count;
|
||||
AABB aabb;
|
||||
Vector<PoolVector<uint8_t> > blend_shapes;
|
||||
Vector<PoolVector<uint8_t>> blend_shapes;
|
||||
Vector<AABB> bone_aabbs;
|
||||
};
|
||||
|
||||
|
@ -298,7 +298,7 @@ public:
|
|||
return mesh_owner.make_rid(mesh);
|
||||
}
|
||||
|
||||
void mesh_add_surface(RID p_mesh, uint32_t p_format, VS::PrimitiveType p_primitive, const PoolVector<uint8_t> &p_array, int p_vertex_count, const PoolVector<uint8_t> &p_index_array, int p_index_count, const AABB &p_aabb, const Vector<PoolVector<uint8_t> > &p_blend_shapes = Vector<PoolVector<uint8_t> >(), const Vector<AABB> &p_bone_aabbs = Vector<AABB>()) {
|
||||
void mesh_add_surface(RID p_mesh, uint32_t p_format, VS::PrimitiveType p_primitive, const PoolVector<uint8_t> &p_array, int p_vertex_count, const PoolVector<uint8_t> &p_index_array, int p_index_count, const AABB &p_aabb, const Vector<PoolVector<uint8_t>> &p_blend_shapes = Vector<PoolVector<uint8_t>>(), const Vector<AABB> &p_bone_aabbs = Vector<AABB>()) {
|
||||
DummyMesh *m = mesh_owner.getornull(p_mesh);
|
||||
ERR_FAIL_COND(!m);
|
||||
|
||||
|
@ -387,9 +387,9 @@ public:
|
|||
|
||||
return m->surfaces[p_surface].aabb;
|
||||
}
|
||||
Vector<PoolVector<uint8_t> > mesh_surface_get_blend_shapes(RID p_mesh, int p_surface) const {
|
||||
Vector<PoolVector<uint8_t>> mesh_surface_get_blend_shapes(RID p_mesh, int p_surface) const {
|
||||
DummyMesh *m = mesh_owner.getornull(p_mesh);
|
||||
ERR_FAIL_COND_V(!m, Vector<PoolVector<uint8_t> >());
|
||||
ERR_FAIL_COND_V(!m, Vector<PoolVector<uint8_t>>());
|
||||
|
||||
return m->surfaces[p_surface].blend_shapes;
|
||||
}
|
||||
|
|
|
@ -2330,7 +2330,7 @@ static PoolVector<uint8_t> _unpack_half_floats(const PoolVector<uint8_t> &array,
|
|||
return ret;
|
||||
}
|
||||
|
||||
void RasterizerStorageGLES2::mesh_add_surface(RID p_mesh, uint32_t p_format, VS::PrimitiveType p_primitive, const PoolVector<uint8_t> &p_array, int p_vertex_count, const PoolVector<uint8_t> &p_index_array, int p_index_count, const AABB &p_aabb, const Vector<PoolVector<uint8_t> > &p_blend_shapes, const Vector<AABB> &p_bone_aabbs) {
|
||||
void RasterizerStorageGLES2::mesh_add_surface(RID p_mesh, uint32_t p_format, VS::PrimitiveType p_primitive, const PoolVector<uint8_t> &p_array, int p_vertex_count, const PoolVector<uint8_t> &p_index_array, int p_index_count, const AABB &p_aabb, const Vector<PoolVector<uint8_t>> &p_blend_shapes, const Vector<AABB> &p_bone_aabbs) {
|
||||
|
||||
Mesh *mesh = mesh_owner.getornull(p_mesh);
|
||||
ERR_FAIL_COND(!mesh);
|
||||
|
@ -2795,10 +2795,10 @@ AABB RasterizerStorageGLES2::mesh_surface_get_aabb(RID p_mesh, int p_surface) co
|
|||
return mesh->surfaces[p_surface]->aabb;
|
||||
}
|
||||
|
||||
Vector<PoolVector<uint8_t> > RasterizerStorageGLES2::mesh_surface_get_blend_shapes(RID p_mesh, int p_surface) const {
|
||||
Vector<PoolVector<uint8_t>> RasterizerStorageGLES2::mesh_surface_get_blend_shapes(RID p_mesh, int p_surface) const {
|
||||
const Mesh *mesh = mesh_owner.getornull(p_mesh);
|
||||
ERR_FAIL_COND_V(!mesh, Vector<PoolVector<uint8_t> >());
|
||||
ERR_FAIL_INDEX_V(p_surface, mesh->surfaces.size(), Vector<PoolVector<uint8_t> >());
|
||||
ERR_FAIL_COND_V(!mesh, Vector<PoolVector<uint8_t>>());
|
||||
ERR_FAIL_INDEX_V(p_surface, mesh->surfaces.size(), Vector<PoolVector<uint8_t>>());
|
||||
#ifndef TOOLS_ENABLED
|
||||
ERR_PRINT("OpenGL ES 2.0 does not allow retrieving blend shape data");
|
||||
#endif
|
||||
|
|
|
@ -280,7 +280,7 @@ public:
|
|||
|
||||
RenderTarget *render_target;
|
||||
|
||||
Vector<Ref<Image> > images;
|
||||
Vector<Ref<Image>> images;
|
||||
|
||||
bool redraw_if_visible;
|
||||
|
||||
|
@ -566,7 +566,7 @@ public:
|
|||
Map<StringName, Variant> params;
|
||||
SelfList<Material> list;
|
||||
SelfList<Material> dirty_list;
|
||||
Vector<Pair<StringName, RID> > textures;
|
||||
Vector<Pair<StringName, RID>> textures;
|
||||
float line_width;
|
||||
int render_priority;
|
||||
|
||||
|
@ -677,7 +677,7 @@ public:
|
|||
|
||||
PoolVector<uint8_t> data;
|
||||
PoolVector<uint8_t> index_data;
|
||||
Vector<PoolVector<uint8_t> > blend_shape_data;
|
||||
Vector<PoolVector<uint8_t>> blend_shape_data;
|
||||
|
||||
int total_data_size;
|
||||
|
||||
|
@ -729,7 +729,7 @@ public:
|
|||
|
||||
virtual RID mesh_create();
|
||||
|
||||
virtual void mesh_add_surface(RID p_mesh, uint32_t p_format, VS::PrimitiveType p_primitive, const PoolVector<uint8_t> &p_array, int p_vertex_count, const PoolVector<uint8_t> &p_index_array, int p_index_count, const AABB &p_aabb, const Vector<PoolVector<uint8_t> > &p_blend_shapes = Vector<PoolVector<uint8_t> >(), const Vector<AABB> &p_bone_aabbs = Vector<AABB>());
|
||||
virtual void mesh_add_surface(RID p_mesh, uint32_t p_format, VS::PrimitiveType p_primitive, const PoolVector<uint8_t> &p_array, int p_vertex_count, const PoolVector<uint8_t> &p_index_array, int p_index_count, const AABB &p_aabb, const Vector<PoolVector<uint8_t>> &p_blend_shapes = Vector<PoolVector<uint8_t>>(), const Vector<AABB> &p_bone_aabbs = Vector<AABB>());
|
||||
|
||||
virtual void mesh_set_blend_shape_count(RID p_mesh, int p_amount);
|
||||
virtual int mesh_get_blend_shape_count(RID p_mesh) const;
|
||||
|
@ -752,7 +752,7 @@ public:
|
|||
virtual VS::PrimitiveType mesh_surface_get_primitive_type(RID p_mesh, int p_surface) const;
|
||||
|
||||
virtual AABB mesh_surface_get_aabb(RID p_mesh, int p_surface) const;
|
||||
virtual Vector<PoolVector<uint8_t> > mesh_surface_get_blend_shapes(RID p_mesh, int p_surface) const;
|
||||
virtual Vector<PoolVector<uint8_t>> mesh_surface_get_blend_shapes(RID p_mesh, int p_surface) const;
|
||||
virtual Vector<AABB> mesh_surface_get_skeleton_aabb(RID p_mesh, int p_surface) const;
|
||||
|
||||
virtual void mesh_remove_surface(RID p_mesh, int p_surface);
|
||||
|
|
|
@ -41,7 +41,7 @@ class ShaderCompilerGLES2 {
|
|||
public:
|
||||
struct IdentifierActions {
|
||||
|
||||
Map<StringName, Pair<int *, int> > render_mode_values;
|
||||
Map<StringName, Pair<int *, int>> render_mode_values;
|
||||
Map<StringName, bool *> render_mode_flags;
|
||||
Map<StringName, bool *> usage_flag_pointers;
|
||||
Map<StringName, bool *> write_flag_pointers;
|
||||
|
|
|
@ -179,7 +179,7 @@ private:
|
|||
|
||||
int max_image_units;
|
||||
|
||||
Map<StringName, Pair<ShaderLanguage::DataType, Vector<ShaderLanguage::ConstantNode::Value> > > uniform_values;
|
||||
Map<StringName, Pair<ShaderLanguage::DataType, Vector<ShaderLanguage::ConstantNode::Value>>> uniform_values;
|
||||
|
||||
protected:
|
||||
_FORCE_INLINE_ int _get_uniform(int p_which) const;
|
||||
|
|
|
@ -3510,7 +3510,7 @@ RID RasterizerStorageGLES3::mesh_create() {
|
|||
return mesh_owner.make_rid(mesh);
|
||||
}
|
||||
|
||||
void RasterizerStorageGLES3::mesh_add_surface(RID p_mesh, uint32_t p_format, VS::PrimitiveType p_primitive, const PoolVector<uint8_t> &p_array, int p_vertex_count, const PoolVector<uint8_t> &p_index_array, int p_index_count, const AABB &p_aabb, const Vector<PoolVector<uint8_t> > &p_blend_shapes, const Vector<AABB> &p_bone_aabbs) {
|
||||
void RasterizerStorageGLES3::mesh_add_surface(RID p_mesh, uint32_t p_format, VS::PrimitiveType p_primitive, const PoolVector<uint8_t> &p_array, int p_vertex_count, const PoolVector<uint8_t> &p_index_array, int p_index_count, const AABB &p_aabb, const Vector<PoolVector<uint8_t>> &p_blend_shapes, const Vector<AABB> &p_bone_aabbs) {
|
||||
|
||||
PoolVector<uint8_t> array = p_array;
|
||||
|
||||
|
@ -4169,13 +4169,13 @@ AABB RasterizerStorageGLES3::mesh_surface_get_aabb(RID p_mesh, int p_surface) co
|
|||
|
||||
return mesh->surfaces[p_surface]->aabb;
|
||||
}
|
||||
Vector<PoolVector<uint8_t> > RasterizerStorageGLES3::mesh_surface_get_blend_shapes(RID p_mesh, int p_surface) const {
|
||||
Vector<PoolVector<uint8_t>> RasterizerStorageGLES3::mesh_surface_get_blend_shapes(RID p_mesh, int p_surface) const {
|
||||
|
||||
const Mesh *mesh = mesh_owner.getornull(p_mesh);
|
||||
ERR_FAIL_COND_V(!mesh, Vector<PoolVector<uint8_t> >());
|
||||
ERR_FAIL_INDEX_V(p_surface, mesh->surfaces.size(), Vector<PoolVector<uint8_t> >());
|
||||
ERR_FAIL_COND_V(!mesh, Vector<PoolVector<uint8_t>>());
|
||||
ERR_FAIL_INDEX_V(p_surface, mesh->surfaces.size(), Vector<PoolVector<uint8_t>>());
|
||||
|
||||
Vector<PoolVector<uint8_t> > bsarr;
|
||||
Vector<PoolVector<uint8_t>> bsarr;
|
||||
|
||||
for (int i = 0; i < mesh->surfaces[p_surface]->blend_shapes.size(); i++) {
|
||||
|
||||
|
@ -4190,7 +4190,7 @@ Vector<PoolVector<uint8_t> > RasterizerStorageGLES3::mesh_surface_get_blend_shap
|
|||
}
|
||||
#else
|
||||
void *data = glMapBufferRange(GL_ELEMENT_ARRAY_BUFFER, 0, mesh->surfaces[p_surface]->array_byte_size, GL_MAP_READ_BIT);
|
||||
ERR_FAIL_COND_V(!data, Vector<PoolVector<uint8_t> >());
|
||||
ERR_FAIL_COND_V(!data, Vector<PoolVector<uint8_t>>());
|
||||
{
|
||||
PoolVector<uint8_t>::Write w = ret.write();
|
||||
memcpy(w.ptr(), data, mesh->surfaces[p_surface]->array_byte_size);
|
||||
|
|
|
@ -290,7 +290,7 @@ public:
|
|||
|
||||
RenderTarget *render_target;
|
||||
|
||||
Vector<Ref<Image> > images;
|
||||
Vector<Ref<Image>> images;
|
||||
|
||||
VisualServer::TextureDetectCallback detect_3d;
|
||||
void *detect_3d_ud;
|
||||
|
@ -763,7 +763,7 @@ public:
|
|||
|
||||
virtual RID mesh_create();
|
||||
|
||||
virtual void mesh_add_surface(RID p_mesh, uint32_t p_format, VS::PrimitiveType p_primitive, const PoolVector<uint8_t> &p_array, int p_vertex_count, const PoolVector<uint8_t> &p_index_array, int p_index_count, const AABB &p_aabb, const Vector<PoolVector<uint8_t> > &p_blend_shapes = Vector<PoolVector<uint8_t> >(), const Vector<AABB> &p_bone_aabbs = Vector<AABB>());
|
||||
virtual void mesh_add_surface(RID p_mesh, uint32_t p_format, VS::PrimitiveType p_primitive, const PoolVector<uint8_t> &p_array, int p_vertex_count, const PoolVector<uint8_t> &p_index_array, int p_index_count, const AABB &p_aabb, const Vector<PoolVector<uint8_t>> &p_blend_shapes = Vector<PoolVector<uint8_t>>(), const Vector<AABB> &p_bone_aabbs = Vector<AABB>());
|
||||
|
||||
virtual void mesh_set_blend_shape_count(RID p_mesh, int p_amount);
|
||||
virtual int mesh_get_blend_shape_count(RID p_mesh) const;
|
||||
|
@ -786,7 +786,7 @@ public:
|
|||
virtual VS::PrimitiveType mesh_surface_get_primitive_type(RID p_mesh, int p_surface) const;
|
||||
|
||||
virtual AABB mesh_surface_get_aabb(RID p_mesh, int p_surface) const;
|
||||
virtual Vector<PoolVector<uint8_t> > mesh_surface_get_blend_shapes(RID p_mesh, int p_surface) const;
|
||||
virtual Vector<PoolVector<uint8_t>> mesh_surface_get_blend_shapes(RID p_mesh, int p_surface) const;
|
||||
virtual Vector<AABB> mesh_surface_get_skeleton_aabb(RID p_mesh, int p_surface) const;
|
||||
|
||||
virtual void mesh_remove_surface(RID p_mesh, int p_surface);
|
||||
|
|
|
@ -40,7 +40,7 @@ class ShaderCompilerGLES3 {
|
|||
public:
|
||||
struct IdentifierActions {
|
||||
|
||||
Map<StringName, Pair<int *, int> > render_mode_values;
|
||||
Map<StringName, Pair<int *, int>> render_mode_values;
|
||||
Map<StringName, bool *> render_mode_flags;
|
||||
Map<StringName, bool *> usage_flag_pointers;
|
||||
Map<StringName, bool *> write_flag_pointers;
|
||||
|
|
|
@ -1079,7 +1079,7 @@ void AnimationBezierTrackEdit::duplicate_selection() {
|
|||
|
||||
undo_redo->create_action(TTR("Anim Duplicate Keys"));
|
||||
|
||||
List<Pair<int, float> > new_selection_values;
|
||||
List<Pair<int, float>> new_selection_values;
|
||||
|
||||
for (Set<int>::Element *E = selection.back(); E; E = E->prev()) {
|
||||
|
||||
|
@ -1106,7 +1106,7 @@ void AnimationBezierTrackEdit::duplicate_selection() {
|
|||
//reselect duplicated
|
||||
|
||||
selection.clear();
|
||||
for (List<Pair<int, float> >::Element *E = new_selection_values.front(); E; E = E->next()) {
|
||||
for (List<Pair<int, float>>::Element *E = new_selection_values.front(); E; E = E->next()) {
|
||||
|
||||
int track = E->get().first;
|
||||
float time = E->get().second;
|
||||
|
|
|
@ -752,7 +752,7 @@ public:
|
|||
if (animation != p_anim)
|
||||
return;
|
||||
|
||||
for (Map<int, List<float> >::Element *E = key_ofs_map.front(); E; E = E->next()) {
|
||||
for (Map<int, List<float>>::Element *E = key_ofs_map.front(); E; E = E->next()) {
|
||||
|
||||
int key = 0;
|
||||
for (List<float>::Element *F = E->value().front(); F; F = F->next()) {
|
||||
|
@ -780,7 +780,7 @@ public:
|
|||
|
||||
bool update_obj = false;
|
||||
bool change_notify_deserved = false;
|
||||
for (Map<int, List<float> >::Element *E = key_ofs_map.front(); E; E = E->next()) {
|
||||
for (Map<int, List<float>>::Element *E = key_ofs_map.front(); E; E = E->next()) {
|
||||
|
||||
int track = E->key();
|
||||
for (List<float>::Element *F = E->value().front(); F; F = F->next()) {
|
||||
|
@ -1063,7 +1063,7 @@ public:
|
|||
|
||||
bool _get(const StringName &p_name, Variant &r_ret) const {
|
||||
|
||||
for (Map<int, List<float> >::Element *E = key_ofs_map.front(); E; E = E->next()) {
|
||||
for (Map<int, List<float>>::Element *E = key_ofs_map.front(); E; E = E->next()) {
|
||||
|
||||
int track = E->key();
|
||||
for (List<float>::Element *F = E->value().front(); F; F = F->next()) {
|
||||
|
@ -1211,7 +1211,7 @@ public:
|
|||
bool show_time = true;
|
||||
bool same_track_type = true;
|
||||
bool same_key_type = true;
|
||||
for (Map<int, List<float> >::Element *E = key_ofs_map.front(); E; E = E->next()) {
|
||||
for (Map<int, List<float>>::Element *E = key_ofs_map.front(); E; E = E->next()) {
|
||||
|
||||
int track = E->key();
|
||||
ERR_FAIL_INDEX(track, animation->get_track_count());
|
||||
|
@ -1365,7 +1365,7 @@ public:
|
|||
|
||||
Ref<Animation> animation;
|
||||
|
||||
Map<int, List<float> > key_ofs_map;
|
||||
Map<int, List<float>> key_ofs_map;
|
||||
Map<int, NodePath> base_map;
|
||||
PropertyInfo hint;
|
||||
|
||||
|
@ -4907,7 +4907,7 @@ void AnimationTrackEditor::_update_key_edit() {
|
|||
multi_key_edit = memnew(AnimationMultiTrackKeyEdit);
|
||||
multi_key_edit->animation = animation;
|
||||
|
||||
Map<int, List<float> > key_ofs_map;
|
||||
Map<int, List<float>> key_ofs_map;
|
||||
Map<int, NodePath> base_map;
|
||||
int first_track = -1;
|
||||
for (Map<SelectedKey, KeyInfo>::Element *E = selection.front(); E; E = E->next()) {
|
||||
|
@ -5199,7 +5199,7 @@ void AnimationTrackEditor::_anim_duplicate_keys(bool transpose) {
|
|||
|
||||
undo_redo->create_action(TTR("Anim Duplicate Keys"));
|
||||
|
||||
List<Pair<int, float> > new_selection_values;
|
||||
List<Pair<int, float>> new_selection_values;
|
||||
|
||||
for (Map<SelectedKey, KeyInfo>::Element *E = selection.back(); E; E = E->prev()) {
|
||||
|
||||
|
@ -5237,7 +5237,7 @@ void AnimationTrackEditor::_anim_duplicate_keys(bool transpose) {
|
|||
//reselect duplicated
|
||||
|
||||
Map<SelectedKey, KeyInfo> new_selection;
|
||||
for (List<Pair<int, float> >::Element *E = new_selection_values.front(); E; E = E->next()) {
|
||||
for (List<Pair<int, float>>::Element *E = new_selection_values.front(); E; E = E->next()) {
|
||||
|
||||
int track = E->get().first;
|
||||
float time = E->get().second;
|
||||
|
|
|
@ -430,7 +430,7 @@ class AnimationTrackEditor : public VBoxContainer {
|
|||
Rect2 box_select_rect;
|
||||
void _scroll_input(const Ref<InputEvent> &p_event);
|
||||
|
||||
Vector<Ref<AnimationTrackEditPlugin> > track_edit_plugins;
|
||||
Vector<Ref<AnimationTrackEditPlugin>> track_edit_plugins;
|
||||
|
||||
void _cancel_bezier_edit();
|
||||
void _bezier_edit(int p_for_track);
|
||||
|
|
|
@ -1773,12 +1773,12 @@ void Collada::_parse_animation(XMLParser &parser) {
|
|||
return;
|
||||
}
|
||||
|
||||
Map<String, Vector<float> > float_sources;
|
||||
Map<String, Vector<String> > string_sources;
|
||||
Map<String, Vector<float>> float_sources;
|
||||
Map<String, Vector<String>> string_sources;
|
||||
Map<String, int> source_strides;
|
||||
Map<String, Map<String, String> > samplers;
|
||||
Map<String, Vector<String> > source_param_names;
|
||||
Map<String, Vector<String> > source_param_types;
|
||||
Map<String, Map<String, String>> samplers;
|
||||
Map<String, Vector<String>> source_param_names;
|
||||
Map<String, Vector<String>> source_param_types;
|
||||
|
||||
String id = "";
|
||||
if (parser.has_attribute("id"))
|
||||
|
|
|
@ -570,8 +570,8 @@ public:
|
|||
|
||||
Vector<AnimationClip> animation_clips;
|
||||
Vector<AnimationTrack> animation_tracks;
|
||||
Map<String, Vector<int> > referenced_tracks;
|
||||
Map<String, Vector<int> > by_id_tracks;
|
||||
Map<String, Vector<int>> referenced_tracks;
|
||||
Map<String, Vector<int>> by_id_tracks;
|
||||
|
||||
float animation_length;
|
||||
|
||||
|
|
|
@ -994,7 +994,7 @@ void ConnectionsDock::update_tree() {
|
|||
String descr;
|
||||
bool found = false;
|
||||
|
||||
Map<StringName, Map<StringName, String> >::Element *G = descr_cache.find(base);
|
||||
Map<StringName, Map<StringName, String>>::Element *G = descr_cache.find(base);
|
||||
if (G) {
|
||||
Map<StringName, String>::Element *F = G->get().find(signal_name);
|
||||
if (F) {
|
||||
|
|
|
@ -142,7 +142,7 @@ class ConnectionsDock : public VBoxContainer {
|
|||
UndoRedo *undo_redo;
|
||||
LineEdit *search_box;
|
||||
|
||||
Map<StringName, Map<StringName, String> > descr_cache;
|
||||
Map<StringName, Map<StringName, String>> descr_cache;
|
||||
|
||||
void _filter_changed(const String &p_text);
|
||||
|
||||
|
|
|
@ -63,7 +63,7 @@ void DependencyEditor::_load_pressed(Object *p_item, int p_cell, int p_button) {
|
|||
search->popup_centered_ratio(0.65); // So it doesn't completely cover the dialog below it.
|
||||
}
|
||||
|
||||
void DependencyEditor::_fix_and_find(EditorFileSystemDirectory *efsd, Map<String, Map<String, String> > &candidates) {
|
||||
void DependencyEditor::_fix_and_find(EditorFileSystemDirectory *efsd, Map<String, Map<String, String>> &candidates) {
|
||||
|
||||
for (int i = 0; i < efsd->get_subdir_count(); i++) {
|
||||
_fix_and_find(efsd->get_subdir(i), candidates);
|
||||
|
@ -124,7 +124,7 @@ void DependencyEditor::_fix_all() {
|
|||
if (!EditorFileSystem::get_singleton()->get_filesystem())
|
||||
return;
|
||||
|
||||
Map<String, Map<String, String> > candidates;
|
||||
Map<String, Map<String, String>> candidates;
|
||||
|
||||
for (List<String>::Element *E = missing.front(); E; E = E->next()) {
|
||||
|
||||
|
@ -140,7 +140,7 @@ void DependencyEditor::_fix_all() {
|
|||
|
||||
Map<String, String> remaps;
|
||||
|
||||
for (Map<String, Map<String, String> >::Element *E = candidates.front(); E; E = E->next()) {
|
||||
for (Map<String, Map<String, String>>::Element *E = candidates.front(); E; E = E->next()) {
|
||||
|
||||
for (Map<String, String>::Element *F = E->get().front(); F; F = F->next()) {
|
||||
|
||||
|
|
|
@ -52,7 +52,7 @@ class DependencyEditor : public AcceptDialog {
|
|||
String editing;
|
||||
List<String> missing;
|
||||
|
||||
void _fix_and_find(EditorFileSystemDirectory *efsd, Map<String, Map<String, String> > &candidates);
|
||||
void _fix_and_find(EditorFileSystemDirectory *efsd, Map<String, Map<String, String>> &candidates);
|
||||
|
||||
void _searched(const String &p_path);
|
||||
void _load_pressed(Object *p_item, int p_cell, int p_button);
|
||||
|
|
|
@ -692,10 +692,10 @@ void DocData::generate(bool p_basic_types) {
|
|||
}
|
||||
|
||||
// Get constants.
|
||||
List<Pair<String, Variant> > cinfo;
|
||||
List<Pair<String, Variant>> cinfo;
|
||||
lang->get_public_constants(&cinfo);
|
||||
|
||||
for (List<Pair<String, Variant> >::Element *E = cinfo.front(); E; E = E->next()) {
|
||||
for (List<Pair<String, Variant>>::Element *E = cinfo.front(); E; E = E->next()) {
|
||||
|
||||
ConstantDoc cd;
|
||||
cd.name = E->get().first;
|
||||
|
|
|
@ -133,7 +133,7 @@ void EditorAssetInstaller::open(const String &p_path, int p_depth) {
|
|||
ret = unzGoToNextFile(pkg);
|
||||
}
|
||||
|
||||
Map<String, Ref<Texture> > extension_guess;
|
||||
Map<String, Ref<Texture>> extension_guess;
|
||||
{
|
||||
extension_guess["png"] = get_icon("ImageTexture", "EditorIcons");
|
||||
extension_guess["jpg"] = get_icon("ImageTexture", "EditorIcons");
|
||||
|
|
|
@ -522,7 +522,7 @@ Variant EditorData::instance_custom_type(const String &p_type, const String &p_i
|
|||
|
||||
void EditorData::remove_custom_type(const String &p_type) {
|
||||
|
||||
for (Map<String, Vector<CustomType> >::Element *E = custom_types.front(); E; E = E->next()) {
|
||||
for (Map<String, Vector<CustomType>>::Element *E = custom_types.front(); E; E = E->next()) {
|
||||
|
||||
for (int i = 0; i < E->get().size(); i++) {
|
||||
if (E->get()[i].name == p_type) {
|
||||
|
|
|
@ -136,7 +136,7 @@ private:
|
|||
String name;
|
||||
Variant value;
|
||||
};
|
||||
Map<String, Vector<CustomType> > custom_types;
|
||||
Map<String, Vector<CustomType>> custom_types;
|
||||
|
||||
List<PropertyData> clipboard;
|
||||
UndoRedo undo_redo;
|
||||
|
@ -182,7 +182,7 @@ public:
|
|||
void add_custom_type(const String &p_type, const String &p_inherits, const Ref<Script> &p_script, const Ref<Texture> &p_icon);
|
||||
Variant instance_custom_type(const String &p_type, const String &p_inherits);
|
||||
void remove_custom_type(const String &p_type);
|
||||
const Map<String, Vector<CustomType> > &get_custom_types() const { return custom_types; }
|
||||
const Map<String, Vector<CustomType>> &get_custom_types() const { return custom_types; }
|
||||
|
||||
int add_edited_scene(int p_at_pos);
|
||||
void move_edited_scene_index(int p_idx, int p_to_idx);
|
||||
|
|
|
@ -671,7 +671,7 @@ EditorExportPlatform::FeatureContainers EditorExportPlatform::get_feature_contai
|
|||
|
||||
EditorExportPlatform::ExportNotifier::ExportNotifier(EditorExportPlatform &p_platform, const Ref<EditorExportPreset> &p_preset, bool p_debug, const String &p_path, int p_flags) {
|
||||
FeatureContainers features = p_platform.get_feature_containers(p_preset);
|
||||
Vector<Ref<EditorExportPlugin> > export_plugins = EditorExport::get_singleton()->get_export_plugins();
|
||||
Vector<Ref<EditorExportPlugin>> export_plugins = EditorExport::get_singleton()->get_export_plugins();
|
||||
//initial export plugin callback
|
||||
for (int i = 0; i < export_plugins.size(); i++) {
|
||||
if (export_plugins[i]->get_script_instance()) { //script based
|
||||
|
@ -683,7 +683,7 @@ EditorExportPlatform::ExportNotifier::ExportNotifier(EditorExportPlatform &p_pla
|
|||
}
|
||||
|
||||
EditorExportPlatform::ExportNotifier::~ExportNotifier() {
|
||||
Vector<Ref<EditorExportPlugin> > export_plugins = EditorExport::get_singleton()->get_export_plugins();
|
||||
Vector<Ref<EditorExportPlugin>> export_plugins = EditorExport::get_singleton()->get_export_plugins();
|
||||
for (int i = 0; i < export_plugins.size(); i++) {
|
||||
if (export_plugins[i]->get_script_instance()) {
|
||||
export_plugins.write[i]->_export_end_script();
|
||||
|
@ -743,7 +743,7 @@ Error EditorExportPlatform::export_project_files(const Ref<EditorExportPreset> &
|
|||
_edit_filter_list(paths, String("*.import"), true);
|
||||
|
||||
Error err = OK;
|
||||
Vector<Ref<EditorExportPlugin> > export_plugins = EditorExport::get_singleton()->get_export_plugins();
|
||||
Vector<Ref<EditorExportPlugin>> export_plugins = EditorExport::get_singleton()->get_export_plugins();
|
||||
|
||||
for (int i = 0; i < export_plugins.size(); i++) {
|
||||
|
||||
|
@ -1393,7 +1393,7 @@ void EditorExport::remove_export_plugin(const Ref<EditorExportPlugin> &p_plugin)
|
|||
export_plugins.erase(p_plugin);
|
||||
}
|
||||
|
||||
Vector<Ref<EditorExportPlugin> > EditorExport::get_export_plugins() {
|
||||
Vector<Ref<EditorExportPlugin>> EditorExport::get_export_plugins() {
|
||||
|
||||
return export_plugins;
|
||||
}
|
||||
|
@ -1509,7 +1509,7 @@ void EditorExport::load_config() {
|
|||
}
|
||||
|
||||
void EditorExport::update_export_presets() {
|
||||
Map<StringName, List<EditorExportPlatform::ExportOption> > platform_options;
|
||||
Map<StringName, List<EditorExportPlatform::ExportOption>> platform_options;
|
||||
|
||||
for (int i = 0; i < export_platforms.size(); i++) {
|
||||
Ref<EditorExportPlatform> platform = export_platforms[i];
|
||||
|
|
|
@ -350,9 +350,9 @@ public:
|
|||
class EditorExport : public Node {
|
||||
GDCLASS(EditorExport, Node);
|
||||
|
||||
Vector<Ref<EditorExportPlatform> > export_platforms;
|
||||
Vector<Ref<EditorExportPreset> > export_presets;
|
||||
Vector<Ref<EditorExportPlugin> > export_plugins;
|
||||
Vector<Ref<EditorExportPlatform>> export_platforms;
|
||||
Vector<Ref<EditorExportPreset>> export_presets;
|
||||
Vector<Ref<EditorExportPlugin>> export_plugins;
|
||||
|
||||
StringName _export_presets_updated;
|
||||
|
||||
|
@ -384,7 +384,7 @@ public:
|
|||
|
||||
void add_export_plugin(const Ref<EditorExportPlugin> &p_plugin);
|
||||
void remove_export_plugin(const Ref<EditorExportPlugin> &p_plugin);
|
||||
Vector<Ref<EditorExportPlugin> > get_export_plugins();
|
||||
Vector<Ref<EditorExportPlugin>> get_export_plugins();
|
||||
|
||||
void load_config();
|
||||
void update_export_presets();
|
||||
|
|
|
@ -153,7 +153,7 @@ Error EditorFeatureProfile::save_to_file(const String &p_path) {
|
|||
|
||||
Array dis_props;
|
||||
|
||||
for (Map<StringName, Set<StringName> >::Element *E = disabled_properties.front(); E; E = E->next()) {
|
||||
for (Map<StringName, Set<StringName>>::Element *E = disabled_properties.front(); E; E = E->next()) {
|
||||
for (Set<StringName>::Element *F = E->get().front(); F; F = F->next()) {
|
||||
dis_props.push_back(String(E->key()) + ":" + String(F->get()));
|
||||
}
|
||||
|
|
|
@ -58,7 +58,7 @@ public:
|
|||
private:
|
||||
Set<StringName> disabled_classes;
|
||||
Set<StringName> disabled_editors;
|
||||
Map<StringName, Set<StringName> > disabled_properties;
|
||||
Map<StringName, Set<StringName>> disabled_properties;
|
||||
|
||||
bool features_disabled[FEATURE_MAX];
|
||||
static const char *feature_names[FEATURE_MAX];
|
||||
|
|
|
@ -1562,7 +1562,7 @@ Error EditorFileSystem::_reimport_group(const String &p_group_file, const Vector
|
|||
|
||||
String importer_name;
|
||||
|
||||
Map<String, Map<StringName, Variant> > source_file_options;
|
||||
Map<String, Map<StringName, Variant>> source_file_options;
|
||||
Map<String, String> base_paths;
|
||||
for (int i = 0; i < p_files.size(); i++) {
|
||||
|
||||
|
@ -1622,7 +1622,7 @@ Error EditorFileSystem::_reimport_group(const String &p_group_file, const Vector
|
|||
Error err = importer->import_group_file(p_group_file, source_file_options, base_paths);
|
||||
|
||||
//all went well, overwrite config files with proper remaps and md5s
|
||||
for (Map<String, Map<StringName, Variant> >::Element *E = source_file_options.front(); E; E = E->next()) {
|
||||
for (Map<String, Map<StringName, Variant>>::Element *E = source_file_options.front(); E; E = E->next()) {
|
||||
|
||||
const String &file = E->key();
|
||||
String base_path = ResourceFormatImporter::get_singleton()->get_import_base_path(file);
|
||||
|
@ -1944,7 +1944,7 @@ void EditorFileSystem::_reimport_file(const String &p_file) {
|
|||
EditorResourcePreview::get_singleton()->check_for_invalidation(p_file);
|
||||
}
|
||||
|
||||
void EditorFileSystem::_find_group_files(EditorFileSystemDirectory *efd, Map<String, Vector<String> > &group_files, Set<String> &groups_to_reimport) {
|
||||
void EditorFileSystem::_find_group_files(EditorFileSystemDirectory *efd, Map<String, Vector<String>> &group_files, Set<String> &groups_to_reimport) {
|
||||
|
||||
int fc = efd->files.size();
|
||||
const EditorFileSystemDirectory::FileInfo *const *files = efd->files.ptr();
|
||||
|
@ -2021,9 +2021,9 @@ void EditorFileSystem::reimport_files(const Vector<String> &p_files) {
|
|||
//reimport groups
|
||||
|
||||
if (groups_to_reimport.size()) {
|
||||
Map<String, Vector<String> > group_files;
|
||||
Map<String, Vector<String>> group_files;
|
||||
_find_group_files(filesystem, group_files, groups_to_reimport);
|
||||
for (Map<String, Vector<String> >::Element *E = group_files.front(); E; E = E->next()) {
|
||||
for (Map<String, Vector<String>>::Element *E = group_files.front(); E; E = E->next()) {
|
||||
|
||||
Error err = _reimport_group(E->key(), E->get());
|
||||
if (err == OK) {
|
||||
|
|
|
@ -244,7 +244,7 @@ class EditorFileSystem : public Node {
|
|||
|
||||
bool using_fat32_or_exfat; // Workaround for projects in FAT32 or exFAT filesystem (pendrives, most of the time)
|
||||
|
||||
void _find_group_files(EditorFileSystemDirectory *efd, Map<String, Vector<String> > &group_files, Set<String> &groups_to_reimport);
|
||||
void _find_group_files(EditorFileSystemDirectory *efd, Map<String, Vector<String>> &group_files, Set<String> &groups_to_reimport);
|
||||
|
||||
void _move_group_files(EditorFileSystemDirectory *efd, const String &p_group_file, const String &p_new_location);
|
||||
|
||||
|
|
|
@ -809,7 +809,7 @@ void EditorHelp::_update_doc() {
|
|||
// Constants and enums
|
||||
if (cd.constants.size()) {
|
||||
|
||||
Map<String, Vector<DocData::ConstantDoc> > enums;
|
||||
Map<String, Vector<DocData::ConstantDoc>> enums;
|
||||
Vector<DocData::ConstantDoc> constants;
|
||||
|
||||
for (int i = 0; i < cd.constants.size(); i++) {
|
||||
|
@ -839,7 +839,7 @@ void EditorHelp::_update_doc() {
|
|||
|
||||
class_desc->add_newline();
|
||||
|
||||
for (Map<String, Vector<DocData::ConstantDoc> >::Element *E = enums.front(); E; E = E->next()) {
|
||||
for (Map<String, Vector<DocData::ConstantDoc>>::Element *E = enums.front(); E; E = E->next()) {
|
||||
|
||||
enum_line[E->key()] = class_desc->get_line_count() - 2;
|
||||
|
||||
|
@ -1206,7 +1206,7 @@ void EditorHelp::_help_callback(const String &p_topic) {
|
|||
if (constant_line.has(name))
|
||||
line = constant_line[name];
|
||||
else {
|
||||
Map<String, Map<String, int> >::Element *iter = enum_values_line.front();
|
||||
Map<String, Map<String, int>>::Element *iter = enum_values_line.front();
|
||||
while (true) {
|
||||
if (iter->value().has(name)) {
|
||||
line = iter->value()[name];
|
||||
|
@ -1507,8 +1507,8 @@ void EditorHelp::go_to_class(const String &p_class, int p_scroll) {
|
|||
_goto_desc(p_class, p_scroll);
|
||||
}
|
||||
|
||||
Vector<Pair<String, int> > EditorHelp::get_sections() {
|
||||
Vector<Pair<String, int> > sections;
|
||||
Vector<Pair<String, int>> EditorHelp::get_sections() {
|
||||
Vector<Pair<String, int>> sections;
|
||||
|
||||
for (int i = 0; i < section_line.size(); i++) {
|
||||
sections.push_back(Pair<String, int>(section_line[i].first, i));
|
||||
|
|
|
@ -108,14 +108,14 @@ class EditorHelp : public VBoxContainer {
|
|||
|
||||
String edited_class;
|
||||
|
||||
Vector<Pair<String, int> > section_line;
|
||||
Vector<Pair<String, int>> section_line;
|
||||
Map<String, int> method_line;
|
||||
Map<String, int> signal_line;
|
||||
Map<String, int> property_line;
|
||||
Map<String, int> theme_property_line;
|
||||
Map<String, int> constant_line;
|
||||
Map<String, int> enum_line;
|
||||
Map<String, Map<String, int> > enum_values_line;
|
||||
Map<String, Map<String, int>> enum_values_line;
|
||||
int description_line;
|
||||
|
||||
RichTextLabel *class_desc;
|
||||
|
@ -175,7 +175,7 @@ public:
|
|||
void go_to_help(const String &p_help);
|
||||
void go_to_class(const String &p_class, int p_scroll = 0);
|
||||
|
||||
Vector<Pair<String, int> > get_sections();
|
||||
Vector<Pair<String, int>> get_sections();
|
||||
void scroll_to_section(int p_section_index);
|
||||
|
||||
void popup_search();
|
||||
|
|
|
@ -1459,7 +1459,7 @@ void EditorInspector::update_tree() {
|
|||
if (!object)
|
||||
return;
|
||||
|
||||
List<Ref<EditorInspectorPlugin> > valid_plugins;
|
||||
List<Ref<EditorInspectorPlugin>> valid_plugins;
|
||||
|
||||
for (int i = inspector_plugin_count - 1; i >= 0; i--) { //start by last, so lastly added can override newly added
|
||||
if (!inspector_plugins[i]->can_handle(object))
|
||||
|
@ -1495,7 +1495,7 @@ void EditorInspector::update_tree() {
|
|||
|
||||
Color sscolor = get_color("prop_subsection", "Editor");
|
||||
|
||||
for (List<Ref<EditorInspectorPlugin> >::Element *E = valid_plugins.front(); E; E = E->next()) {
|
||||
for (List<Ref<EditorInspectorPlugin>>::Element *E = valid_plugins.front(); E; E = E->next()) {
|
||||
Ref<EditorInspectorPlugin> ped = E->get();
|
||||
ped->parse_begin(object);
|
||||
_parse_added_editors(main_vbox, ped);
|
||||
|
@ -1562,7 +1562,7 @@ void EditorInspector::update_tree() {
|
|||
category->set_tooltip(p.name + "::" + (class_descr_cache[type2] == "" ? "" : class_descr_cache[type2]));
|
||||
}
|
||||
|
||||
for (List<Ref<EditorInspectorPlugin> >::Element *E = valid_plugins.front(); E; E = E->next()) {
|
||||
for (List<Ref<EditorInspectorPlugin>>::Element *E = valid_plugins.front(); E; E = E->next()) {
|
||||
Ref<EditorInspectorPlugin> ped = E->get();
|
||||
ped->parse_category(object, p.name);
|
||||
_parse_added_editors(main_vbox, ped);
|
||||
|
@ -1693,7 +1693,7 @@ void EditorInspector::update_tree() {
|
|||
String descr;
|
||||
bool found = false;
|
||||
|
||||
Map<StringName, Map<StringName, String> >::Element *E = descr_cache.find(classname);
|
||||
Map<StringName, Map<StringName, String>>::Element *E = descr_cache.find(classname);
|
||||
if (E) {
|
||||
Map<StringName, String>::Element *F = E->get().find(propname);
|
||||
if (F) {
|
||||
|
@ -1736,7 +1736,7 @@ void EditorInspector::update_tree() {
|
|||
doc_hint = descr;
|
||||
}
|
||||
|
||||
for (List<Ref<EditorInspectorPlugin> >::Element *E = valid_plugins.front(); E; E = E->next()) {
|
||||
for (List<Ref<EditorInspectorPlugin>>::Element *E = valid_plugins.front(); E; E = E->next()) {
|
||||
Ref<EditorInspectorPlugin> ped = E->get();
|
||||
bool exclusive = ped->parse_property(object, p.type, p.name, p.hint, p.hint_string, p.usage);
|
||||
|
||||
|
@ -1819,7 +1819,7 @@ void EditorInspector::update_tree() {
|
|||
}
|
||||
}
|
||||
|
||||
for (List<Ref<EditorInspectorPlugin> >::Element *E = valid_plugins.front(); E; E = E->next()) {
|
||||
for (List<Ref<EditorInspectorPlugin>>::Element *E = valid_plugins.front(); E; E = E->next()) {
|
||||
Ref<EditorInspectorPlugin> ped = E->get();
|
||||
ped->parse_end();
|
||||
_parse_added_editors(main_vbox, ped);
|
||||
|
@ -1950,7 +1950,7 @@ void EditorInspector::collapse_all_folding() {
|
|||
E->get()->fold();
|
||||
}
|
||||
|
||||
for (Map<StringName, List<EditorProperty *> >::Element *F = editor_property_map.front(); F; F = F->next()) {
|
||||
for (Map<StringName, List<EditorProperty *>>::Element *F = editor_property_map.front(); F; F = F->next()) {
|
||||
for (List<EditorProperty *>::Element *E = F->get().front(); E; E = E->next()) {
|
||||
E->get()->collapse_all_folding();
|
||||
}
|
||||
|
@ -1961,7 +1961,7 @@ void EditorInspector::expand_all_folding() {
|
|||
for (List<EditorInspectorSection *>::Element *E = sections.front(); E; E = E->next()) {
|
||||
E->get()->unfold();
|
||||
}
|
||||
for (Map<StringName, List<EditorProperty *> >::Element *F = editor_property_map.front(); F; F = F->next()) {
|
||||
for (Map<StringName, List<EditorProperty *>>::Element *F = editor_property_map.front(); F; F = F->next()) {
|
||||
for (List<EditorProperty *>::Element *E = F->get().front(); E; E = E->next()) {
|
||||
E->get()->expand_all_folding();
|
||||
}
|
||||
|
@ -2184,7 +2184,7 @@ void EditorInspector::_property_selected(const String &p_path, int p_focusable)
|
|||
property_selected = p_path;
|
||||
property_focusable = p_focusable;
|
||||
//deselect the others
|
||||
for (Map<StringName, List<EditorProperty *> >::Element *F = editor_property_map.front(); F; F = F->next()) {
|
||||
for (Map<StringName, List<EditorProperty *>>::Element *F = editor_property_map.front(); F; F = F->next()) {
|
||||
if (F->key() == property_selected)
|
||||
continue;
|
||||
for (List<EditorProperty *>::Element *E = F->get().front(); E; E = E->next()) {
|
||||
|
@ -2244,7 +2244,7 @@ void EditorInspector::_notification(int p_what) {
|
|||
if (refresh_countdown > 0) {
|
||||
refresh_countdown -= get_process_delta_time();
|
||||
if (refresh_countdown <= 0) {
|
||||
for (Map<StringName, List<EditorProperty *> >::Element *F = editor_property_map.front(); F; F = F->next()) {
|
||||
for (Map<StringName, List<EditorProperty *>>::Element *F = editor_property_map.front(); F; F = F->next()) {
|
||||
for (List<EditorProperty *>::Element *E = F->get().front(); E; E = E->next()) {
|
||||
E->get()->update_property();
|
||||
E->get()->update_reload_status();
|
||||
|
|
|
@ -261,7 +261,7 @@ class EditorInspector : public ScrollContainer {
|
|||
VBoxContainer *main_vbox;
|
||||
|
||||
//map use to cache the instanced editors
|
||||
Map<StringName, List<EditorProperty *> > editor_property_map;
|
||||
Map<StringName, List<EditorProperty *>> editor_property_map;
|
||||
List<EditorInspectorSection *> sections;
|
||||
Set<StringName> pending;
|
||||
|
||||
|
@ -291,7 +291,7 @@ class EditorInspector : public ScrollContainer {
|
|||
int property_focusable;
|
||||
int update_scroll_request;
|
||||
|
||||
Map<StringName, Map<StringName, String> > descr_cache;
|
||||
Map<StringName, Map<StringName, String>> descr_cache;
|
||||
Map<StringName, String> class_descr_cache;
|
||||
Set<StringName> restart_request_props;
|
||||
|
||||
|
|
|
@ -176,7 +176,7 @@ EditorNode *EditorNode::singleton = NULL;
|
|||
void EditorNode::disambiguate_filenames(const Vector<String> p_full_paths, Vector<String> &r_filenames) {
|
||||
// Keep track of a list of "index sets," i.e. sets of indices
|
||||
// within disambiguated_scene_names which contain the same name.
|
||||
Vector<Set<int> > index_sets;
|
||||
Vector<Set<int>> index_sets;
|
||||
Map<String, int> scene_name_to_set_index;
|
||||
for (int i = 0; i < r_filenames.size(); i++) {
|
||||
String scene_name = r_filenames[i];
|
||||
|
@ -648,7 +648,7 @@ void EditorNode::_on_plugin_ready(Object *p_script, const String &p_activate_nam
|
|||
|
||||
void EditorNode::_resources_changed(const PoolVector<String> &p_resources) {
|
||||
|
||||
List<Ref<Resource> > changed;
|
||||
List<Ref<Resource>> changed;
|
||||
|
||||
int rc = p_resources.size();
|
||||
for (int i = 0; i < rc; i++) {
|
||||
|
@ -674,7 +674,7 @@ void EditorNode::_resources_changed(const PoolVector<String> &p_resources) {
|
|||
}
|
||||
|
||||
if (changed.size()) {
|
||||
for (List<Ref<Resource> >::Element *E = changed.front(); E; E = E->next()) {
|
||||
for (List<Ref<Resource>>::Element *E = changed.front(); E; E = E->next()) {
|
||||
E->get()->reload_from_file();
|
||||
}
|
||||
}
|
||||
|
@ -1418,7 +1418,7 @@ bool EditorNode::_validate_scene_recursive(const String &p_filename, Node *p_nod
|
|||
return false;
|
||||
}
|
||||
|
||||
static bool _find_edited_resources(const Ref<Resource> &p_resource, Set<Ref<Resource> > &edited_resources) {
|
||||
static bool _find_edited_resources(const Ref<Resource> &p_resource, Set<Ref<Resource>> &edited_resources) {
|
||||
|
||||
if (p_resource->is_edited()) {
|
||||
edited_resources.insert(p_resource);
|
||||
|
@ -1455,11 +1455,11 @@ int EditorNode::_save_external_resources() {
|
|||
flg |= ResourceSaver::FLAG_COMPRESS;
|
||||
flg |= ResourceSaver::FLAG_REPLACE_SUBRESOURCE_PATHS;
|
||||
|
||||
Set<Ref<Resource> > edited_subresources;
|
||||
Set<Ref<Resource>> edited_subresources;
|
||||
int saved = 0;
|
||||
List<Ref<Resource> > cached;
|
||||
List<Ref<Resource>> cached;
|
||||
ResourceCache::get_cached_resources(&cached);
|
||||
for (List<Ref<Resource> >::Element *E = cached.front(); E; E = E->next()) {
|
||||
for (List<Ref<Resource>>::Element *E = cached.front(); E; E = E->next()) {
|
||||
|
||||
Ref<Resource> res = E->get();
|
||||
if (!res->get_path().is_resource_file())
|
||||
|
@ -1474,7 +1474,7 @@ int EditorNode::_save_external_resources() {
|
|||
// clear later, because user may have put the same subresource in two different resources,
|
||||
// which will be shared until the next reload
|
||||
|
||||
for (Set<Ref<Resource> >::Element *E = edited_subresources.front(); E; E = E->next()) {
|
||||
for (Set<Ref<Resource>>::Element *E = edited_subresources.front(); E; E = E->next()) {
|
||||
Ref<Resource> res = E->get();
|
||||
res->set_edited(false);
|
||||
}
|
||||
|
@ -3620,7 +3620,7 @@ Error EditorNode::load_scene(const String &p_scene, bool p_ignore_broken_deps, b
|
|||
|
||||
dependency_errors.erase(lpath); //at least not self path
|
||||
|
||||
for (Map<String, Set<String> >::Element *E = dependency_errors.front(); E; E = E->next()) {
|
||||
for (Map<String, Set<String>>::Element *E = dependency_errors.front(); E; E = E->next()) {
|
||||
|
||||
String txt = vformat(TTR("Scene '%s' has broken dependencies:"), E->key()) + "\n";
|
||||
for (Set<String>::Element *F = E->get().front(); F; F = F->next()) {
|
||||
|
@ -4071,8 +4071,8 @@ Ref<Texture> EditorNode::get_class_icon(const String &p_class, const String &p_f
|
|||
return icon;
|
||||
}
|
||||
|
||||
const Map<String, Vector<EditorData::CustomType> > &p_map = EditorNode::get_editor_data().get_custom_types();
|
||||
for (const Map<String, Vector<EditorData::CustomType> >::Element *E = p_map.front(); E; E = E->next()) {
|
||||
const Map<String, Vector<EditorData::CustomType>> &p_map = EditorNode::get_editor_data().get_custom_types();
|
||||
for (const Map<String, Vector<EditorData::CustomType>>::Element *E = p_map.front(); E; E = E->next()) {
|
||||
const Vector<EditorData::CustomType> &ct = E->value();
|
||||
for (int i = 0; i < ct.size(); ++i) {
|
||||
if (ct[i].name == p_class) {
|
||||
|
@ -5428,10 +5428,10 @@ void EditorNode::reload_scene(const String &p_path) {
|
|||
|
||||
//first of all, reload internal textures, materials, meshes, etc. as they might have changed on disk
|
||||
|
||||
List<Ref<Resource> > cached;
|
||||
List<Ref<Resource>> cached;
|
||||
ResourceCache::get_cached_resources(&cached);
|
||||
List<Ref<Resource> > to_clear; //clear internal resources from previous scene from being used
|
||||
for (List<Ref<Resource> >::Element *E = cached.front(); E; E = E->next()) {
|
||||
List<Ref<Resource>> to_clear; //clear internal resources from previous scene from being used
|
||||
for (List<Ref<Resource>>::Element *E = cached.front(); E; E = E->next()) {
|
||||
|
||||
if (E->get()->get_path().begins_with(p_path + "::")) { //subresources of existing scene
|
||||
to_clear.push_back(E->get());
|
||||
|
@ -5562,9 +5562,9 @@ void EditorNode::remove_resource_conversion_plugin(const Ref<EditorResourceConve
|
|||
resource_conversion_plugins.erase(p_plugin);
|
||||
}
|
||||
|
||||
Vector<Ref<EditorResourceConversionPlugin> > EditorNode::find_resource_conversion_plugin(const Ref<Resource> &p_for_resource) {
|
||||
Vector<Ref<EditorResourceConversionPlugin>> EditorNode::find_resource_conversion_plugin(const Ref<Resource> &p_for_resource) {
|
||||
|
||||
Vector<Ref<EditorResourceConversionPlugin> > ret;
|
||||
Vector<Ref<EditorResourceConversionPlugin>> ret;
|
||||
|
||||
for (int i = 0; i < resource_conversion_plugins.size(); i++) {
|
||||
if (resource_conversion_plugins[i].is_valid() && resource_conversion_plugins[i]->handles(p_for_resource)) {
|
||||
|
|
|
@ -526,7 +526,7 @@ private:
|
|||
Set<FileDialog *> file_dialogs;
|
||||
Set<EditorFileDialog *> editor_file_dialogs;
|
||||
|
||||
Map<String, Ref<Texture> > icon_type_cache;
|
||||
Map<String, Ref<Texture>> icon_type_cache;
|
||||
void _build_icon_type_cache();
|
||||
|
||||
bool _initializing_addons;
|
||||
|
@ -549,7 +549,7 @@ private:
|
|||
void _find_node_types(Node *p_node, int &count_2d, int &count_3d);
|
||||
void _save_scene_with_preview(String p_file, int p_idx = -1);
|
||||
|
||||
Map<String, Set<String> > dependency_errors;
|
||||
Map<String, Set<String>> dependency_errors;
|
||||
|
||||
static void _dependency_error_report(void *ud, const String &p_path, const String &p_dep, const String &p_type) {
|
||||
EditorNode *en = (EditorNode *)ud;
|
||||
|
@ -635,7 +635,7 @@ private:
|
|||
|
||||
void _update_update_spinner();
|
||||
|
||||
Vector<Ref<EditorResourceConversionPlugin> > resource_conversion_plugins;
|
||||
Vector<Ref<EditorResourceConversionPlugin>> resource_conversion_plugins;
|
||||
|
||||
PrintHandlerList print_handler;
|
||||
static void _print_handler(void *p_this, const String &p_string, bool p_error);
|
||||
|
@ -865,7 +865,7 @@ public:
|
|||
|
||||
void add_resource_conversion_plugin(const Ref<EditorResourceConversionPlugin> &p_plugin);
|
||||
void remove_resource_conversion_plugin(const Ref<EditorResourceConversionPlugin> &p_plugin);
|
||||
Vector<Ref<EditorResourceConversionPlugin> > find_resource_conversion_plugin(const Ref<Resource> &p_for_resource);
|
||||
Vector<Ref<EditorResourceConversionPlugin>> find_resource_conversion_plugin(const Ref<Resource> &p_for_resource);
|
||||
|
||||
static void add_init_callback(EditorNodeInitCallback p_callback) { _init_callbacks.push_back(p_callback); }
|
||||
static void add_build_callback(EditorBuildCallback p_callback);
|
||||
|
|
|
@ -45,13 +45,13 @@
|
|||
|
||||
Array EditorInterface::_make_mesh_previews(const Array &p_meshes, int p_preview_size) {
|
||||
|
||||
Vector<Ref<Mesh> > meshes;
|
||||
Vector<Ref<Mesh>> meshes;
|
||||
|
||||
for (int i = 0; i < p_meshes.size(); i++) {
|
||||
meshes.push_back(p_meshes[i]);
|
||||
}
|
||||
|
||||
Vector<Ref<Texture> > textures = make_mesh_previews(meshes, NULL, p_preview_size);
|
||||
Vector<Ref<Texture>> textures = make_mesh_previews(meshes, NULL, p_preview_size);
|
||||
Array ret;
|
||||
for (int i = 0; i < textures.size(); i++) {
|
||||
ret.push_back(textures[i]);
|
||||
|
@ -60,7 +60,7 @@ Array EditorInterface::_make_mesh_previews(const Array &p_meshes, int p_preview_
|
|||
return ret;
|
||||
}
|
||||
|
||||
Vector<Ref<Texture> > EditorInterface::make_mesh_previews(const Vector<Ref<Mesh> > &p_meshes, Vector<Transform> *p_transforms, int p_preview_size) {
|
||||
Vector<Ref<Texture>> EditorInterface::make_mesh_previews(const Vector<Ref<Mesh>> &p_meshes, Vector<Transform> *p_transforms, int p_preview_size) {
|
||||
|
||||
int size = p_preview_size;
|
||||
|
||||
|
@ -87,7 +87,7 @@ Vector<Ref<Texture> > EditorInterface::make_mesh_previews(const Vector<Ref<Mesh>
|
|||
|
||||
EditorProgress ep("mlib", TTR("Creating Mesh Previews"), p_meshes.size());
|
||||
|
||||
Vector<Ref<Texture> > textures;
|
||||
Vector<Ref<Texture>> textures;
|
||||
|
||||
for (int i = 0; i < p_meshes.size(); i++) {
|
||||
|
||||
|
|
|
@ -110,7 +110,7 @@ public:
|
|||
Error save_scene();
|
||||
void save_scene_as(const String &p_scene, bool p_with_preview = true);
|
||||
|
||||
Vector<Ref<Texture> > make_mesh_previews(const Vector<Ref<Mesh> > &p_meshes, Vector<Transform> *p_transforms, int p_preview_size);
|
||||
Vector<Ref<Texture>> make_mesh_previews(const Vector<Ref<Mesh>> &p_meshes, Vector<Transform> *p_transforms, int p_preview_size);
|
||||
|
||||
void set_main_screen_editor(const String &p_name);
|
||||
void set_distraction_free_mode(bool p_enter);
|
||||
|
|
|
@ -624,8 +624,8 @@ bool EditorProfiler::is_profiling() {
|
|||
return activate->is_pressed();
|
||||
}
|
||||
|
||||
Vector<Vector<String> > EditorProfiler::get_data_as_csv() const {
|
||||
Vector<Vector<String> > res;
|
||||
Vector<Vector<String>> EditorProfiler::get_data_as_csv() const {
|
||||
Vector<Vector<String>> res;
|
||||
|
||||
if (frame_metrics.empty()) {
|
||||
return res;
|
||||
|
|
|
@ -169,7 +169,7 @@ public:
|
|||
|
||||
void clear();
|
||||
|
||||
Vector<Vector<String> > get_data_as_csv() const;
|
||||
Vector<Vector<String>> get_data_as_csv() const;
|
||||
|
||||
EditorProfiler();
|
||||
};
|
||||
|
|
|
@ -2233,7 +2233,7 @@ void EditorPropertyResource::_menu_option(int p_which) {
|
|||
|
||||
List<PropertyInfo> property_list;
|
||||
res_orig->get_property_list(&property_list);
|
||||
List<Pair<String, Variant> > propvalues;
|
||||
List<Pair<String, Variant>> propvalues;
|
||||
|
||||
for (List<PropertyInfo>::Element *E = property_list.front(); E; E = E->next()) {
|
||||
|
||||
|
@ -2256,7 +2256,7 @@ void EditorPropertyResource::_menu_option(int p_which) {
|
|||
|
||||
ERR_FAIL_COND(res.is_null());
|
||||
|
||||
for (List<Pair<String, Variant> >::Element *E = propvalues.front(); E; E = E->next()) {
|
||||
for (List<Pair<String, Variant>>::Element *E = propvalues.front(); E; E = E->next()) {
|
||||
|
||||
Pair<String, Variant> &p = E->get();
|
||||
res->set(p.first, p.second);
|
||||
|
@ -2318,7 +2318,7 @@ void EditorPropertyResource::_menu_option(int p_which) {
|
|||
|
||||
int to_type = p_which - CONVERT_BASE_ID;
|
||||
|
||||
Vector<Ref<EditorResourceConversionPlugin> > conversions = EditorNode::get_singleton()->find_resource_conversion_plugin(res);
|
||||
Vector<Ref<EditorResourceConversionPlugin>> conversions = EditorNode::get_singleton()->find_resource_conversion_plugin(res);
|
||||
|
||||
ERR_FAIL_INDEX(to_type, conversions.size());
|
||||
|
||||
|
@ -2549,7 +2549,7 @@ void EditorPropertyResource::_update_menu_items() {
|
|||
|
||||
if (!res.is_null()) {
|
||||
|
||||
Vector<Ref<EditorResourceConversionPlugin> > conversions = EditorNode::get_singleton()->find_resource_conversion_plugin(res);
|
||||
Vector<Ref<EditorResourceConversionPlugin>> conversions = EditorNode::get_singleton()->find_resource_conversion_plugin(res);
|
||||
if (conversions.size()) {
|
||||
menu->add_separator();
|
||||
}
|
||||
|
|
|
@ -95,7 +95,7 @@ class EditorResourcePreview : public Node {
|
|||
static void _thread_func(void *ud);
|
||||
void _thread();
|
||||
|
||||
Vector<Ref<EditorResourcePreviewGenerator> > preview_generators;
|
||||
Vector<Ref<EditorResourcePreviewGenerator>> preview_generators;
|
||||
|
||||
protected:
|
||||
static void _bind_methods();
|
||||
|
|
|
@ -125,7 +125,7 @@ bool EditorSettings::_get(const StringName &p_name, Variant &r_ret) const {
|
|||
if (p_name.operator String() == "shortcuts") {
|
||||
|
||||
Array arr;
|
||||
for (const Map<String, Ref<ShortCut> >::Element *E = shortcuts.front(); E; E = E->next()) {
|
||||
for (const Map<String, Ref<ShortCut>>::Element *E = shortcuts.front(); E; E = E->next()) {
|
||||
|
||||
Ref<ShortCut> sc = E->get();
|
||||
|
||||
|
@ -1528,7 +1528,7 @@ void EditorSettings::add_shortcut(const String &p_name, Ref<ShortCut> &p_shortcu
|
|||
|
||||
bool EditorSettings::is_shortcut(const String &p_name, const Ref<InputEvent> &p_event) const {
|
||||
|
||||
const Map<String, Ref<ShortCut> >::Element *E = shortcuts.find(p_name);
|
||||
const Map<String, Ref<ShortCut>>::Element *E = shortcuts.find(p_name);
|
||||
ERR_FAIL_COND_V_MSG(!E, false, "Unknown Shortcut: " + p_name + ".");
|
||||
|
||||
return E->get()->is_shortcut(p_event);
|
||||
|
@ -1536,7 +1536,7 @@ bool EditorSettings::is_shortcut(const String &p_name, const Ref<InputEvent> &p_
|
|||
|
||||
Ref<ShortCut> EditorSettings::get_shortcut(const String &p_name) const {
|
||||
|
||||
const Map<String, Ref<ShortCut> >::Element *E = shortcuts.find(p_name);
|
||||
const Map<String, Ref<ShortCut>>::Element *E = shortcuts.find(p_name);
|
||||
if (!E)
|
||||
return Ref<ShortCut>();
|
||||
|
||||
|
@ -1545,7 +1545,7 @@ Ref<ShortCut> EditorSettings::get_shortcut(const String &p_name) const {
|
|||
|
||||
void EditorSettings::get_shortcut_list(List<String> *r_shortcuts) {
|
||||
|
||||
for (const Map<String, Ref<ShortCut> >::Element *E = shortcuts.front(); E; E = E->next()) {
|
||||
for (const Map<String, Ref<ShortCut>>::Element *E = shortcuts.front(); E; E = E->next()) {
|
||||
|
||||
r_shortcuts->push_back(E->key());
|
||||
}
|
||||
|
|
|
@ -95,7 +95,7 @@ private:
|
|||
int last_order;
|
||||
|
||||
Ref<Resource> clipboard;
|
||||
Map<String, Ref<ShortCut> > shortcuts;
|
||||
Map<String, Ref<ShortCut>> shortcuts;
|
||||
|
||||
String resource_path;
|
||||
String settings_dir;
|
||||
|
|
|
@ -1104,10 +1104,10 @@ void FileSystemDock::_try_duplicate_item(const FileOrFolder &p_item, const Strin
|
|||
|
||||
void FileSystemDock::_update_resource_paths_after_move(const Map<String, String> &p_renames) const {
|
||||
// Rename all resources loaded, be it subresources or actual resources.
|
||||
List<Ref<Resource> > cached;
|
||||
List<Ref<Resource>> cached;
|
||||
ResourceCache::get_cached_resources(&cached);
|
||||
|
||||
for (List<Ref<Resource> >::Element *E = cached.front(); E; E = E->next()) {
|
||||
for (List<Ref<Resource>>::Element *E = cached.front(); E; E = E->next()) {
|
||||
Ref<Resource> r = E->get();
|
||||
|
||||
String base_path = r->get_path();
|
||||
|
|
|
@ -49,7 +49,7 @@ struct ColladaImport {
|
|||
Collada collada;
|
||||
Spatial *scene;
|
||||
|
||||
Vector<Ref<Animation> > animations;
|
||||
Vector<Ref<Animation>> animations;
|
||||
|
||||
struct NodeMap {
|
||||
//String path;
|
||||
|
@ -73,12 +73,12 @@ struct ColladaImport {
|
|||
|
||||
Map<String, NodeMap> node_map; //map from collada node to engine node
|
||||
Map<String, String> node_name_map; //map from collada node to engine node
|
||||
Map<String, Ref<ArrayMesh> > mesh_cache;
|
||||
Map<String, Ref<Curve3D> > curve_cache;
|
||||
Map<String, Ref<Material> > material_cache;
|
||||
Map<String, Ref<ArrayMesh>> mesh_cache;
|
||||
Map<String, Ref<Curve3D>> curve_cache;
|
||||
Map<String, Ref<Material>> material_cache;
|
||||
Map<Collada::Node *, Skeleton *> skeleton_map;
|
||||
|
||||
Map<Skeleton *, Map<String, int> > skeleton_bone_map;
|
||||
Map<Skeleton *, Map<String, int>> skeleton_bone_map;
|
||||
|
||||
Set<String> valid_animated_nodes;
|
||||
Vector<int> valid_animated_properties;
|
||||
|
@ -89,7 +89,7 @@ struct ColladaImport {
|
|||
Error _create_scene(Collada::Node *p_node, Spatial *p_parent);
|
||||
Error _create_resources(Collada::Node *p_node, bool p_use_compression);
|
||||
Error _create_material(const String &p_target);
|
||||
Error _create_mesh_surfaces(bool p_optimize, Ref<ArrayMesh> &p_mesh, const Map<String, Collada::NodeGeometry::Material> &p_material_map, const Collada::MeshData &meshdata, const Transform &p_local_xform, const Vector<int> &bone_remap, const Collada::SkinControllerData *p_skin_controller, const Collada::MorphControllerData *p_morph_data, Vector<Ref<ArrayMesh> > p_morph_meshes = Vector<Ref<ArrayMesh> >(), bool p_use_compression = false, bool p_use_mesh_material = false);
|
||||
Error _create_mesh_surfaces(bool p_optimize, Ref<ArrayMesh> &p_mesh, const Map<String, Collada::NodeGeometry::Material> &p_material_map, const Collada::MeshData &meshdata, const Transform &p_local_xform, const Vector<int> &bone_remap, const Collada::SkinControllerData *p_skin_controller, const Collada::MorphControllerData *p_morph_data, Vector<Ref<ArrayMesh>> p_morph_meshes = Vector<Ref<ArrayMesh>>(), bool p_use_compression = false, bool p_use_mesh_material = false);
|
||||
Error load(const String &p_path, int p_flags, bool p_force_make_tangents = false, bool p_use_compression = false);
|
||||
void _fix_param_animation_tracks();
|
||||
void create_animation(int p_clip, bool p_make_tracks_in_all_bones, bool p_import_value_tracks);
|
||||
|
@ -487,7 +487,7 @@ Error ColladaImport::_create_material(const String &p_target) {
|
|||
return OK;
|
||||
}
|
||||
|
||||
Error ColladaImport::_create_mesh_surfaces(bool p_optimize, Ref<ArrayMesh> &p_mesh, const Map<String, Collada::NodeGeometry::Material> &p_material_map, const Collada::MeshData &meshdata, const Transform &p_local_xform, const Vector<int> &bone_remap, const Collada::SkinControllerData *p_skin_controller, const Collada::MorphControllerData *p_morph_data, Vector<Ref<ArrayMesh> > p_morph_meshes, bool p_use_compression, bool p_use_mesh_material) {
|
||||
Error ColladaImport::_create_mesh_surfaces(bool p_optimize, Ref<ArrayMesh> &p_mesh, const Map<String, Collada::NodeGeometry::Material> &p_material_map, const Collada::MeshData &meshdata, const Transform &p_local_xform, const Vector<int> &bone_remap, const Collada::SkinControllerData *p_skin_controller, const Collada::MorphControllerData *p_morph_data, Vector<Ref<ArrayMesh>> p_morph_meshes, bool p_use_compression, bool p_use_mesh_material) {
|
||||
|
||||
bool local_xform_mirror = p_local_xform.basis.determinant() < 0;
|
||||
|
||||
|
@ -606,7 +606,7 @@ Error ColladaImport::_create_mesh_surfaces(bool p_optimize, Ref<ArrayMesh> &p_me
|
|||
/* ADD WEIGHTS IF EXIST */
|
||||
/************************/
|
||||
|
||||
Map<int, Vector<Collada::Vertex::Weight> > pre_weights;
|
||||
Map<int, Vector<Collada::Vertex::Weight>> pre_weights;
|
||||
|
||||
bool has_weights = false;
|
||||
|
||||
|
@ -1101,7 +1101,7 @@ Error ColladaImport::_create_resources(Collada::Node *p_node, bool p_use_compres
|
|||
String meshid;
|
||||
Transform apply_xform;
|
||||
Vector<int> bone_remap;
|
||||
Vector<Ref<ArrayMesh> > morphs;
|
||||
Vector<Ref<ArrayMesh>> morphs;
|
||||
|
||||
if (ng2->controller) {
|
||||
|
||||
|
@ -1178,7 +1178,7 @@ Error ColladaImport::_create_resources(Collada::Node *p_node, bool p_use_compres
|
|||
Ref<ArrayMesh> mesh = Ref<ArrayMesh>(memnew(ArrayMesh));
|
||||
const Collada::MeshData &meshdata = collada.state.mesh_data_map[meshid2];
|
||||
mesh->set_name(meshdata.name);
|
||||
Error err = _create_mesh_surfaces(false, mesh, ng2->material_map, meshdata, apply_xform, bone_remap, skin, NULL, Vector<Ref<ArrayMesh> >(), false);
|
||||
Error err = _create_mesh_surfaces(false, mesh, ng2->material_map, meshdata, apply_xform, bone_remap, skin, NULL, Vector<Ref<ArrayMesh>>(), false);
|
||||
ERR_FAIL_COND_V(err, err);
|
||||
|
||||
morphs.push_back(mesh);
|
||||
|
|
|
@ -1967,7 +1967,7 @@ Error EditorSceneImporterGLTF::_determine_skeletons(GLTFState &state) {
|
|||
skeleton_sets.get_representatives(groups_representatives);
|
||||
|
||||
Vector<GLTFNodeIndex> highest_group_members;
|
||||
Vector<Vector<GLTFNodeIndex> > groups;
|
||||
Vector<Vector<GLTFNodeIndex>> groups;
|
||||
for (int i = 0; i < groups_representatives.size(); ++i) {
|
||||
Vector<GLTFNodeIndex> group;
|
||||
skeleton_sets.get_members(group, groups_representatives[i]);
|
||||
|
|
|
@ -306,7 +306,7 @@ class EditorSceneImporterGLTF : public EditorSceneImporter {
|
|||
Channel<Vector3> translation_track;
|
||||
Channel<Quat> rotation_track;
|
||||
Channel<Vector3> scale_track;
|
||||
Vector<Channel<float> > weight_tracks;
|
||||
Vector<Channel<float>> weight_tracks;
|
||||
};
|
||||
|
||||
String name;
|
||||
|
@ -325,18 +325,18 @@ class EditorSceneImporterGLTF : public EditorSceneImporter {
|
|||
bool use_legacy_names;
|
||||
|
||||
Vector<GLTFNode *> nodes;
|
||||
Vector<Vector<uint8_t> > buffers;
|
||||
Vector<Vector<uint8_t>> buffers;
|
||||
Vector<GLTFBufferView> buffer_views;
|
||||
Vector<GLTFAccessor> accessors;
|
||||
|
||||
Vector<GLTFMesh> meshes; //meshes are loaded directly, no reason not to.
|
||||
Vector<Ref<Material> > materials;
|
||||
Vector<Ref<Material>> materials;
|
||||
|
||||
String scene_name;
|
||||
Vector<int> root_nodes;
|
||||
|
||||
Vector<GLTFTexture> textures;
|
||||
Vector<Ref<Texture> > images;
|
||||
Vector<Ref<Texture>> images;
|
||||
|
||||
Vector<GLTFSkin> skins;
|
||||
Vector<GLTFCamera> cameras;
|
||||
|
|
|
@ -96,7 +96,7 @@ Error ResourceImporterCSVTranslation::import(const String &p_source_file, const
|
|||
ERR_FAIL_COND_V(line.size() <= 1, ERR_PARSE_ERROR);
|
||||
|
||||
Vector<String> locales;
|
||||
Vector<Ref<Translation> > translations;
|
||||
Vector<Ref<Translation>> translations;
|
||||
|
||||
for (int i = 1; i < line.size(); i++) {
|
||||
|
||||
|
|
|
@ -91,7 +91,7 @@ void ResourceImporterLayeredTexture::get_import_options(List<ImportOption> *r_op
|
|||
r_options->push_back(ImportOption(PropertyInfo(Variant::INT, "slices/vertical", PROPERTY_HINT_RANGE, "1,256,1"), p_preset == PRESET_COLOR_CORRECT ? 1 : 8));
|
||||
}
|
||||
|
||||
void ResourceImporterLayeredTexture::_save_tex(const Vector<Ref<Image> > &p_images, const String &p_to_path, int p_compress_mode, Image::CompressMode p_vram_compression, bool p_mipmaps, int p_texture_flags) {
|
||||
void ResourceImporterLayeredTexture::_save_tex(const Vector<Ref<Image>> &p_images, const String &p_to_path, int p_compress_mode, Image::CompressMode p_vram_compression, bool p_mipmaps, int p_texture_flags) {
|
||||
|
||||
FileAccess *f = FileAccess::open(p_to_path, FileAccess::WRITE);
|
||||
f->store_8('G');
|
||||
|
@ -221,7 +221,7 @@ Error ResourceImporterLayeredTexture::import(const String &p_source_file, const
|
|||
if (srgb == 1)
|
||||
tex_flags |= Texture::FLAG_CONVERT_TO_LINEAR;
|
||||
|
||||
Vector<Ref<Image> > slices;
|
||||
Vector<Ref<Image>> slices;
|
||||
|
||||
int slice_w = image->get_width() / hslices;
|
||||
int slice_h = image->get_height() / vslices;
|
||||
|
|
|
@ -75,7 +75,7 @@ public:
|
|||
virtual void get_import_options(List<ImportOption> *r_options, int p_preset = 0) const;
|
||||
virtual bool get_option_visibility(const String &p_option, const Map<StringName, Variant> &p_options) const;
|
||||
|
||||
void _save_tex(const Vector<Ref<Image> > &p_images, const String &p_to_path, int p_compress_mode, Image::CompressMode p_vram_compression, bool p_mipmaps, int p_texture_flags);
|
||||
void _save_tex(const Vector<Ref<Image>> &p_images, const String &p_to_path, int p_compress_mode, Image::CompressMode p_vram_compression, bool p_mipmaps, int p_texture_flags);
|
||||
|
||||
virtual Error import(const String &p_source_file, const String &p_save_path, const Map<StringName, Variant> &p_options, List<String> *r_platform_variants, List<String> *r_gen_files = NULL, Variant *r_metadata = NULL);
|
||||
|
||||
|
|
|
@ -42,7 +42,7 @@ uint32_t EditorOBJImporter::get_import_flags() const {
|
|||
return IMPORT_SCENE;
|
||||
}
|
||||
|
||||
static Error _parse_material_library(const String &p_path, Map<String, Ref<SpatialMaterial> > &material_map, List<String> *r_missing_deps) {
|
||||
static Error _parse_material_library(const String &p_path, Map<String, Ref<SpatialMaterial>> &material_map, List<String> *r_missing_deps) {
|
||||
|
||||
FileAccessRef f = FileAccess::open(p_path, FileAccess::READ);
|
||||
ERR_FAIL_COND_V_MSG(!f, ERR_CANT_OPEN, vformat("Couldn't open MTL file '%s', it may not exist or not be readable.", p_path));
|
||||
|
@ -203,7 +203,7 @@ static Error _parse_material_library(const String &p_path, Map<String, Ref<Spati
|
|||
return OK;
|
||||
}
|
||||
|
||||
static Error _parse_obj(const String &p_path, List<Ref<Mesh> > &r_meshes, bool p_single_mesh, bool p_generate_tangents, bool p_optimize, Vector3 p_scale_mesh, Vector3 p_offset_mesh, List<String> *r_missing_deps) {
|
||||
static Error _parse_obj(const String &p_path, List<Ref<Mesh>> &r_meshes, bool p_single_mesh, bool p_generate_tangents, bool p_optimize, Vector3 p_scale_mesh, Vector3 p_offset_mesh, List<String> *r_missing_deps) {
|
||||
|
||||
FileAccessRef f = FileAccess::open(p_path, FileAccess::READ);
|
||||
ERR_FAIL_COND_V_MSG(!f, ERR_CANT_OPEN, vformat("Couldn't open OBJ file '%s', it may not exist or not be readable.", p_path));
|
||||
|
@ -221,7 +221,7 @@ static Error _parse_obj(const String &p_path, List<Ref<Mesh> > &r_meshes, bool p
|
|||
Vector<Vector2> uvs;
|
||||
String name;
|
||||
|
||||
Map<String, Map<String, Ref<SpatialMaterial> > > material_map;
|
||||
Map<String, Map<String, Ref<SpatialMaterial>>> material_map;
|
||||
|
||||
Ref<SurfaceTool> surf_tool = memnew(SurfaceTool);
|
||||
surf_tool->begin(Mesh::PRIMITIVE_TRIANGLES);
|
||||
|
@ -397,7 +397,7 @@ static Error _parse_obj(const String &p_path, List<Ref<Mesh> > &r_meshes, bool p
|
|||
|
||||
current_material_library = l.replace("mtllib", "").strip_edges();
|
||||
if (!material_map.has(current_material_library)) {
|
||||
Map<String, Ref<SpatialMaterial> > lib;
|
||||
Map<String, Ref<SpatialMaterial>> lib;
|
||||
Error err = _parse_material_library(current_material_library, lib, r_missing_deps);
|
||||
if (err == ERR_CANT_OPEN) {
|
||||
String dir = p_path.get_base_dir();
|
||||
|
@ -420,7 +420,7 @@ static Error _parse_obj(const String &p_path, List<Ref<Mesh> > &r_meshes, bool p
|
|||
|
||||
Node *EditorOBJImporter::import_scene(const String &p_path, uint32_t p_flags, int p_bake_fps, List<String> *r_missing_deps, Error *r_err) {
|
||||
|
||||
List<Ref<Mesh> > meshes;
|
||||
List<Ref<Mesh>> meshes;
|
||||
|
||||
Error err = _parse_obj(p_path, meshes, false, p_flags & IMPORT_GENERATE_TANGENT_ARRAYS, p_flags & IMPORT_USE_COMPRESSION, Vector3(1, 1, 1), Vector3(0, 0, 0), r_missing_deps);
|
||||
|
||||
|
@ -433,7 +433,7 @@ Node *EditorOBJImporter::import_scene(const String &p_path, uint32_t p_flags, in
|
|||
|
||||
Spatial *scene = memnew(Spatial);
|
||||
|
||||
for (List<Ref<Mesh> >::Element *E = meshes.front(); E; E = E->next()) {
|
||||
for (List<Ref<Mesh>>::Element *E = meshes.front(); E; E = E->next()) {
|
||||
|
||||
MeshInstance *mi = memnew(MeshInstance);
|
||||
mi->set_mesh(E->get());
|
||||
|
@ -500,7 +500,7 @@ bool ResourceImporterOBJ::get_option_visibility(const String &p_option, const Ma
|
|||
|
||||
Error ResourceImporterOBJ::import(const String &p_source_file, const String &p_save_path, const Map<StringName, Variant> &p_options, List<String> *r_platform_variants, List<String> *r_gen_files, Variant *r_metadata) {
|
||||
|
||||
List<Ref<Mesh> > meshes;
|
||||
List<Ref<Mesh>> meshes;
|
||||
|
||||
Error err = _parse_obj(p_source_file, meshes, true, p_options["generate_tangents"], p_options["optimize_mesh"], p_options["scale_mesh"], p_options["offset_mesh"], NULL);
|
||||
|
||||
|
|
|
@ -170,7 +170,7 @@ String ResourceImporterScene::get_visible_name() const {
|
|||
|
||||
void ResourceImporterScene::get_recognized_extensions(List<String> *p_extensions) const {
|
||||
|
||||
for (Set<Ref<EditorSceneImporter> >::Element *E = importers.front(); E; E = E->next()) {
|
||||
for (Set<Ref<EditorSceneImporter>>::Element *E = importers.front(); E; E = E->next()) {
|
||||
E->get()->get_extensions(p_extensions);
|
||||
}
|
||||
}
|
||||
|
@ -276,7 +276,7 @@ static String _fixstr(const String &p_what, const String &p_str) {
|
|||
return what;
|
||||
}
|
||||
|
||||
static void _gen_shape_list(const Ref<Mesh> &mesh, List<Ref<Shape> > &r_shape_list, bool p_convex) {
|
||||
static void _gen_shape_list(const Ref<Mesh> &mesh, List<Ref<Shape>> &r_shape_list, bool p_convex) {
|
||||
|
||||
if (!p_convex) {
|
||||
|
||||
|
@ -284,7 +284,7 @@ static void _gen_shape_list(const Ref<Mesh> &mesh, List<Ref<Shape> > &r_shape_li
|
|||
r_shape_list.push_back(shape);
|
||||
} else {
|
||||
|
||||
Vector<Ref<Shape> > cd = mesh->convex_decompose();
|
||||
Vector<Ref<Shape>> cd = mesh->convex_decompose();
|
||||
if (cd.size()) {
|
||||
for (int i = 0; i < cd.size(); i++) {
|
||||
r_shape_list.push_back(cd[i]);
|
||||
|
@ -293,7 +293,7 @@ static void _gen_shape_list(const Ref<Mesh> &mesh, List<Ref<Shape> > &r_shape_li
|
|||
}
|
||||
}
|
||||
|
||||
Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh>, List<Ref<Shape> > > &collision_map, LightBakeMode p_light_bake_mode) {
|
||||
Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh>, List<Ref<Shape>>> &collision_map, LightBakeMode p_light_bake_mode) {
|
||||
|
||||
// children first
|
||||
for (int i = 0; i < p_node->get_child_count(); i++) {
|
||||
|
@ -382,7 +382,7 @@ Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh>
|
|||
Ref<Mesh> mesh = mi->get_mesh();
|
||||
|
||||
if (mesh.is_valid()) {
|
||||
List<Ref<Shape> > shapes;
|
||||
List<Ref<Shape>> shapes;
|
||||
String fixed_name;
|
||||
if (collision_map.has(mesh)) {
|
||||
shapes = collision_map[mesh];
|
||||
|
@ -458,7 +458,7 @@ Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh>
|
|||
Ref<Mesh> mesh = mi->get_mesh();
|
||||
|
||||
if (mesh.is_valid()) {
|
||||
List<Ref<Shape> > shapes;
|
||||
List<Ref<Shape>> shapes;
|
||||
if (collision_map.has(mesh)) {
|
||||
shapes = collision_map[mesh];
|
||||
} else {
|
||||
|
@ -485,7 +485,7 @@ Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh>
|
|||
Ref<Mesh> mesh = mi->get_mesh();
|
||||
|
||||
if (mesh.is_valid()) {
|
||||
List<Ref<Shape> > shapes;
|
||||
List<Ref<Shape>> shapes;
|
||||
String fixed_name;
|
||||
if (collision_map.has(mesh)) {
|
||||
shapes = collision_map[mesh];
|
||||
|
@ -587,7 +587,7 @@ Node *ResourceImporterScene::_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh>
|
|||
Ref<ArrayMesh> mesh = mi->get_mesh();
|
||||
if (!mesh.is_null()) {
|
||||
|
||||
List<Ref<Shape> > shapes;
|
||||
List<Ref<Shape>> shapes;
|
||||
if (collision_map.has(mesh)) {
|
||||
shapes = collision_map[mesh];
|
||||
} else if (_teststr(mesh->get_name(), "col")) {
|
||||
|
@ -913,7 +913,7 @@ void ResourceImporterScene::_find_meshes(Node *p_node, Map<Ref<ArrayMesh>, Trans
|
|||
}
|
||||
}
|
||||
|
||||
void ResourceImporterScene::_make_external_resources(Node *p_node, const String &p_base_path, bool p_make_animations, bool p_animations_as_text, bool p_keep_animations, bool p_make_materials, bool p_materials_as_text, bool p_keep_materials, bool p_make_meshes, bool p_meshes_as_text, Map<Ref<Animation>, Ref<Animation> > &p_animations, Map<Ref<Material>, Ref<Material> > &p_materials, Map<Ref<ArrayMesh>, Ref<ArrayMesh> > &p_meshes) {
|
||||
void ResourceImporterScene::_make_external_resources(Node *p_node, const String &p_base_path, bool p_make_animations, bool p_animations_as_text, bool p_keep_animations, bool p_make_materials, bool p_materials_as_text, bool p_keep_materials, bool p_make_meshes, bool p_meshes_as_text, Map<Ref<Animation>, Ref<Animation>> &p_animations, Map<Ref<Material>, Ref<Material>> &p_materials, Map<Ref<ArrayMesh>, Ref<ArrayMesh>> &p_meshes) {
|
||||
|
||||
List<PropertyInfo> pi;
|
||||
|
||||
|
@ -1159,9 +1159,9 @@ void ResourceImporterScene::_replace_owner(Node *p_node, Node *p_scene, Node *p_
|
|||
}
|
||||
}
|
||||
|
||||
void ResourceImporterScene::_add_shapes(Node *p_node, const List<Ref<Shape> > &p_shapes) {
|
||||
void ResourceImporterScene::_add_shapes(Node *p_node, const List<Ref<Shape>> &p_shapes) {
|
||||
int idx = 0;
|
||||
for (const List<Ref<Shape> >::Element *E = p_shapes.front(); E; E = E->next()) {
|
||||
for (const List<Ref<Shape>>::Element *E = p_shapes.front(); E; E = E->next()) {
|
||||
CollisionShape *cshape = memnew(CollisionShape);
|
||||
cshape->set_shape(E->get());
|
||||
p_node->add_child(cshape);
|
||||
|
@ -1177,7 +1177,7 @@ Node *ResourceImporterScene::import_scene_from_other_importer(EditorSceneImporte
|
|||
Ref<EditorSceneImporter> importer;
|
||||
String ext = p_path.get_extension().to_lower();
|
||||
|
||||
for (Set<Ref<EditorSceneImporter> >::Element *E = importers.front(); E; E = E->next()) {
|
||||
for (Set<Ref<EditorSceneImporter>>::Element *E = importers.front(); E; E = E->next()) {
|
||||
|
||||
if (E->get().ptr() == p_exception)
|
||||
continue;
|
||||
|
@ -1209,7 +1209,7 @@ Ref<Animation> ResourceImporterScene::import_animation_from_other_importer(Edito
|
|||
Ref<EditorSceneImporter> importer;
|
||||
String ext = p_path.get_extension().to_lower();
|
||||
|
||||
for (Set<Ref<EditorSceneImporter> >::Element *E = importers.front(); E; E = E->next()) {
|
||||
for (Set<Ref<EditorSceneImporter>>::Element *E = importers.front(); E; E = E->next()) {
|
||||
|
||||
if (E->get().ptr() == p_exception)
|
||||
continue;
|
||||
|
@ -1244,7 +1244,7 @@ Error ResourceImporterScene::import(const String &p_source_file, const String &p
|
|||
EditorProgress progress("import", TTR("Import Scene"), 104);
|
||||
progress.step(TTR("Importing Scene..."), 0);
|
||||
|
||||
for (Set<Ref<EditorSceneImporter> >::Element *E = importers.front(); E; E = E->next()) {
|
||||
for (Set<Ref<EditorSceneImporter>>::Element *E = importers.front(); E; E = E->next()) {
|
||||
|
||||
List<String> extensions;
|
||||
E->get()->get_extensions(&extensions);
|
||||
|
@ -1339,7 +1339,7 @@ Error ResourceImporterScene::import(const String &p_source_file, const String &p
|
|||
float anim_optimizer_maxang = p_options["animation/optimizer/max_angle"];
|
||||
int light_bake_mode = p_options["meshes/light_baking"];
|
||||
|
||||
Map<Ref<Mesh>, List<Ref<Shape> > > collision_map;
|
||||
Map<Ref<Mesh>, List<Ref<Shape>>> collision_map;
|
||||
|
||||
scene = _fix_node(scene, scene, collision_map, LightBakeMode(light_bake_mode));
|
||||
|
||||
|
@ -1515,9 +1515,9 @@ Error ResourceImporterScene::import(const String &p_source_file, const String &p
|
|||
}
|
||||
|
||||
if (external_animations || external_materials || external_meshes) {
|
||||
Map<Ref<Animation>, Ref<Animation> > anim_map;
|
||||
Map<Ref<Material>, Ref<Material> > mat_map;
|
||||
Map<Ref<ArrayMesh>, Ref<ArrayMesh> > mesh_map;
|
||||
Map<Ref<Animation>, Ref<Animation>> anim_map;
|
||||
Map<Ref<Material>, Ref<Material>> mat_map;
|
||||
Map<Ref<ArrayMesh>, Ref<ArrayMesh>> mesh_map;
|
||||
|
||||
bool keep_materials = bool(p_options["materials/keep_on_reimport"]);
|
||||
|
||||
|
|
|
@ -93,7 +93,7 @@ public:
|
|||
class ResourceImporterScene : public ResourceImporter {
|
||||
GDCLASS(ResourceImporterScene, ResourceImporter);
|
||||
|
||||
Set<Ref<EditorSceneImporter> > importers;
|
||||
Set<Ref<EditorSceneImporter>> importers;
|
||||
|
||||
static ResourceImporterScene *singleton;
|
||||
|
||||
|
@ -121,12 +121,12 @@ class ResourceImporterScene : public ResourceImporter {
|
|||
};
|
||||
|
||||
void _replace_owner(Node *p_node, Node *p_scene, Node *p_new_owner);
|
||||
void _add_shapes(Node *p_node, const List<Ref<Shape> > &p_shapes);
|
||||
void _add_shapes(Node *p_node, const List<Ref<Shape>> &p_shapes);
|
||||
|
||||
public:
|
||||
static ResourceImporterScene *get_singleton() { return singleton; }
|
||||
|
||||
const Set<Ref<EditorSceneImporter> > &get_importers() const { return importers; }
|
||||
const Set<Ref<EditorSceneImporter>> &get_importers() const { return importers; }
|
||||
|
||||
void add_importer(Ref<EditorSceneImporter> p_importer) { importers.insert(p_importer); }
|
||||
void remove_importer(Ref<EditorSceneImporter> p_importer) { importers.erase(p_importer); }
|
||||
|
@ -146,9 +146,9 @@ public:
|
|||
|
||||
void _find_meshes(Node *p_node, Map<Ref<ArrayMesh>, Transform> &meshes);
|
||||
|
||||
void _make_external_resources(Node *p_node, const String &p_base_path, bool p_make_animations, bool p_animations_as_text, bool p_keep_animations, bool p_make_materials, bool p_materials_as_text, bool p_keep_materials, bool p_make_meshes, bool p_meshes_as_text, Map<Ref<Animation>, Ref<Animation> > &p_animations, Map<Ref<Material>, Ref<Material> > &p_materials, Map<Ref<ArrayMesh>, Ref<ArrayMesh> > &p_meshes);
|
||||
void _make_external_resources(Node *p_node, const String &p_base_path, bool p_make_animations, bool p_animations_as_text, bool p_keep_animations, bool p_make_materials, bool p_materials_as_text, bool p_keep_materials, bool p_make_meshes, bool p_meshes_as_text, Map<Ref<Animation>, Ref<Animation>> &p_animations, Map<Ref<Material>, Ref<Material>> &p_materials, Map<Ref<ArrayMesh>, Ref<ArrayMesh>> &p_meshes);
|
||||
|
||||
Node *_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh>, List<Ref<Shape> > > &collision_map, LightBakeMode p_light_bake_mode);
|
||||
Node *_fix_node(Node *p_node, Node *p_root, Map<Ref<Mesh>, List<Ref<Shape>>> &collision_map, LightBakeMode p_light_bake_mode);
|
||||
|
||||
void _create_clips(Node *scene, const Array &p_clips, bool p_bake_all);
|
||||
void _filter_anim_tracks(Ref<Animation> anim, Set<String> &keep);
|
||||
|
|
|
@ -193,7 +193,7 @@ static void _plot_triangle(Vector2 *vertices, const Vector2 &p_offset, bool p_tr
|
|||
}
|
||||
}
|
||||
|
||||
Error ResourceImporterTextureAtlas::import_group_file(const String &p_group_file, const Map<String, Map<StringName, Variant> > &p_source_file_options, const Map<String, String> &p_base_paths) {
|
||||
Error ResourceImporterTextureAtlas::import_group_file(const String &p_group_file, const Map<String, Map<StringName, Variant>> &p_source_file_options, const Map<String, String> &p_base_paths) {
|
||||
|
||||
ERR_FAIL_COND_V(p_source_file_options.size() == 0, ERR_BUG); //should never happen
|
||||
|
||||
|
@ -203,7 +203,7 @@ Error ResourceImporterTextureAtlas::import_group_file(const String &p_group_file
|
|||
pack_data_files.resize(p_source_file_options.size());
|
||||
|
||||
int idx = 0;
|
||||
for (const Map<String, Map<StringName, Variant> >::Element *E = p_source_file_options.front(); E; E = E->next(), idx++) {
|
||||
for (const Map<String, Map<StringName, Variant>>::Element *E = p_source_file_options.front(); E; E = E->next(), idx++) {
|
||||
|
||||
PackData &pack_data = pack_data_files.write[idx];
|
||||
const String &source = E->key();
|
||||
|
@ -252,7 +252,7 @@ Error ResourceImporterTextureAtlas::import_group_file(const String &p_group_file
|
|||
Ref<BitMap> bit_map;
|
||||
bit_map.instance();
|
||||
bit_map->create_from_image_alpha(image);
|
||||
Vector<Vector<Vector2> > polygons = bit_map->clip_opaque_to_polygons(Rect2(0, 0, image->get_width(), image->get_height()));
|
||||
Vector<Vector<Vector2>> polygons = bit_map->clip_opaque_to_polygons(Rect2(0, 0, image->get_width(), image->get_height()));
|
||||
|
||||
for (int j = 0; j < polygons.size(); j++) {
|
||||
|
||||
|
@ -328,7 +328,7 @@ Error ResourceImporterTextureAtlas::import_group_file(const String &p_group_file
|
|||
|
||||
//save the images
|
||||
idx = 0;
|
||||
for (const Map<String, Map<StringName, Variant> >::Element *E = p_source_file_options.front(); E; E = E->next(), idx++) {
|
||||
for (const Map<String, Map<StringName, Variant>>::Element *E = p_source_file_options.front(); E; E = E->next(), idx++) {
|
||||
|
||||
PackData &pack_data = pack_data_files.write[idx];
|
||||
|
||||
|
|
|
@ -40,7 +40,7 @@ class ResourceImporterTextureAtlas : public ResourceImporter {
|
|||
Rect2 region;
|
||||
bool is_mesh;
|
||||
Vector<int> chart_pieces; //one for region, many for mesh
|
||||
Vector<Vector<Vector2> > chart_vertices; //for mesh
|
||||
Vector<Vector<Vector2>> chart_vertices; //for mesh
|
||||
Ref<Image> image;
|
||||
};
|
||||
|
||||
|
@ -64,7 +64,7 @@ public:
|
|||
virtual String get_option_group_file() const;
|
||||
|
||||
virtual Error import(const String &p_source_file, const String &p_save_path, const Map<StringName, Variant> &p_options, List<String> *r_platform_variants, List<String> *r_gen_files = NULL, Variant *r_metadata = NULL);
|
||||
virtual Error import_group_file(const String &p_group_file, const Map<String, Map<StringName, Variant> > &p_source_file_options, const Map<String, String> &p_base_paths);
|
||||
virtual Error import_group_file(const String &p_group_file, const Map<String, Map<StringName, Variant>> &p_source_file_options, const Map<String, String> &p_base_paths);
|
||||
|
||||
ResourceImporterTextureAtlas();
|
||||
};
|
||||
|
|
|
@ -105,10 +105,10 @@ void ImportDefaultsEditor::_save() {
|
|||
}
|
||||
|
||||
void ImportDefaultsEditor::_update_importer() {
|
||||
List<Ref<ResourceImporter> > importer_list;
|
||||
List<Ref<ResourceImporter>> importer_list;
|
||||
ResourceFormatImporter::get_singleton()->get_importers(&importer_list);
|
||||
Ref<ResourceImporter> importer;
|
||||
for (List<Ref<ResourceImporter> >::Element *E = importer_list.front(); E; E = E->next()) {
|
||||
for (List<Ref<ResourceImporter>>::Element *E = importer_list.front(); E; E = E->next()) {
|
||||
if (E->get()->get_visible_name() == importers->get_item_text(importers->get_selected())) {
|
||||
importer = E->get();
|
||||
break;
|
||||
|
@ -165,10 +165,10 @@ void ImportDefaultsEditor::clear() {
|
|||
importers->add_item("<" + TTR("Select Importer") + ">");
|
||||
importers->set_item_disabled(0, true);
|
||||
|
||||
List<Ref<ResourceImporter> > importer_list;
|
||||
List<Ref<ResourceImporter>> importer_list;
|
||||
ResourceFormatImporter::get_singleton()->get_importers(&importer_list);
|
||||
Vector<String> names;
|
||||
for (List<Ref<ResourceImporter> >::Element *E = importer_list.front(); E; E = E->next()) {
|
||||
for (List<Ref<ResourceImporter>>::Element *E = importer_list.front(); E; E = E->next()) {
|
||||
String vn = E->get()->get_visible_name();
|
||||
names.push_back(vn);
|
||||
}
|
||||
|
|
|
@ -110,19 +110,19 @@ void ImportDock::set_edit_path(const String &p_path) {
|
|||
|
||||
_update_options(config);
|
||||
|
||||
List<Ref<ResourceImporter> > importers;
|
||||
List<Ref<ResourceImporter>> importers;
|
||||
ResourceFormatImporter::get_singleton()->get_importers_for_extension(p_path.get_extension(), &importers);
|
||||
List<Pair<String, String> > importer_names;
|
||||
List<Pair<String, String>> importer_names;
|
||||
|
||||
for (List<Ref<ResourceImporter> >::Element *E = importers.front(); E; E = E->next()) {
|
||||
for (List<Ref<ResourceImporter>>::Element *E = importers.front(); E; E = E->next()) {
|
||||
importer_names.push_back(Pair<String, String>(E->get()->get_visible_name(), E->get()->get_importer_name()));
|
||||
}
|
||||
|
||||
importer_names.sort_custom<PairSort<String, String> >();
|
||||
importer_names.sort_custom<PairSort<String, String>>();
|
||||
|
||||
import_as->clear();
|
||||
|
||||
for (List<Pair<String, String> >::Element *E = importer_names.front(); E; E = E->next()) {
|
||||
for (List<Pair<String, String>>::Element *E = importer_names.front(); E; E = E->next()) {
|
||||
import_as->add_item(E->get().first);
|
||||
import_as->set_item_metadata(import_as->get_item_count() - 1, E->get().second);
|
||||
if (E->get().second == importer_name) {
|
||||
|
@ -252,19 +252,19 @@ void ImportDock::set_edit_multiple_paths(const Vector<String> &p_paths) {
|
|||
|
||||
params->update();
|
||||
|
||||
List<Ref<ResourceImporter> > importers;
|
||||
List<Ref<ResourceImporter>> importers;
|
||||
ResourceFormatImporter::get_singleton()->get_importers_for_extension(p_paths[0].get_extension(), &importers);
|
||||
List<Pair<String, String> > importer_names;
|
||||
List<Pair<String, String>> importer_names;
|
||||
|
||||
for (List<Ref<ResourceImporter> >::Element *E = importers.front(); E; E = E->next()) {
|
||||
for (List<Ref<ResourceImporter>>::Element *E = importers.front(); E; E = E->next()) {
|
||||
importer_names.push_back(Pair<String, String>(E->get()->get_visible_name(), E->get()->get_importer_name()));
|
||||
}
|
||||
|
||||
importer_names.sort_custom<PairSort<String, String> >();
|
||||
importer_names.sort_custom<PairSort<String, String>>();
|
||||
|
||||
import_as->clear();
|
||||
|
||||
for (List<Pair<String, String> >::Element *E = importer_names.front(); E; E = E->next()) {
|
||||
for (List<Pair<String, String>>::Element *E = importer_names.front(); E; E = E->next()) {
|
||||
import_as->add_item(E->get().first);
|
||||
import_as->set_item_metadata(import_as->get_item_count() - 1, E->get().second);
|
||||
if (E->get().second == params->importer->get_importer_name()) {
|
||||
|
|
|
@ -539,7 +539,7 @@ bool AnimationNodeBlendTreeEditor::_update_filters(const Ref<AnimationNode> &ano
|
|||
updating = true;
|
||||
|
||||
Set<String> paths;
|
||||
HashMap<String, Set<String> > types;
|
||||
HashMap<String, Set<String>> types;
|
||||
{
|
||||
List<StringName> animations;
|
||||
player->get_animation_list(&animations);
|
||||
|
|
|
@ -2103,7 +2103,7 @@ bool CanvasItemEditor::_gui_input_move(const Ref<InputEvent> &p_event) {
|
|||
if (m.is_valid()) {
|
||||
|
||||
// Save the ik chain for reapplying before IK solve
|
||||
Vector<List<Dictionary> > all_bones_ik_states;
|
||||
Vector<List<Dictionary>> all_bones_ik_states;
|
||||
for (List<CanvasItem *>::Element *E = drag_selection.front(); E; E = E->next()) {
|
||||
List<Dictionary> bones_ik_states;
|
||||
_save_canvas_item_ik_chain(E->get(), NULL, &bones_ik_states);
|
||||
|
@ -2213,7 +2213,7 @@ bool CanvasItemEditor::_gui_input_move(const Ref<InputEvent> &p_event) {
|
|||
if (drag_selection.size() > 0) {
|
||||
|
||||
// Save the ik chain for reapplying before IK solve
|
||||
Vector<List<Dictionary> > all_bones_ik_states;
|
||||
Vector<List<Dictionary>> all_bones_ik_states;
|
||||
for (List<CanvasItem *>::Element *E = drag_selection.front(); E; E = E->next()) {
|
||||
List<Dictionary> bones_ik_states;
|
||||
_save_canvas_item_ik_chain(E->get(), NULL, &bones_ik_states);
|
||||
|
|
|
@ -197,7 +197,7 @@ void MeshInstanceEditor::_menu_option(int p_option) {
|
|||
return;
|
||||
}
|
||||
|
||||
Vector<Ref<Shape> > shapes = mesh->convex_decompose();
|
||||
Vector<Ref<Shape>> shapes = mesh->convex_decompose();
|
||||
|
||||
if (!shapes.size()) {
|
||||
err_dialog->set_text(TTR("Couldn't create any collision shapes."));
|
||||
|
|
|
@ -170,7 +170,7 @@ void MeshLibraryEditor::_import_scene(Node *p_scene, Ref<MeshLibrary> p_library,
|
|||
|
||||
if (1) {
|
||||
|
||||
Vector<Ref<Mesh> > meshes;
|
||||
Vector<Ref<Mesh>> meshes;
|
||||
Vector<Transform> transforms;
|
||||
Vector<int> ids = p_library->get_item_list();
|
||||
for (int i = 0; i < ids.size(); i++) {
|
||||
|
@ -182,7 +182,7 @@ void MeshLibraryEditor::_import_scene(Node *p_scene, Ref<MeshLibrary> p_library,
|
|||
}
|
||||
}
|
||||
|
||||
Vector<Ref<Texture> > textures = EditorInterface::get_singleton()->make_mesh_previews(meshes, &transforms, EditorSettings::get_singleton()->get("editors/grid_map/preview_size"));
|
||||
Vector<Ref<Texture>> textures = EditorInterface::get_singleton()->make_mesh_previews(meshes, &transforms, EditorSettings::get_singleton()->get("editors/grid_map/preview_size"));
|
||||
int j = 0;
|
||||
for (int i = 0; i < ids.size(); i++) {
|
||||
|
||||
|
|
|
@ -985,7 +985,7 @@ Ref<Script> ScriptEditor::_get_current_script() {
|
|||
Array ScriptEditor::_get_open_scripts() const {
|
||||
|
||||
Array ret;
|
||||
Vector<Ref<Script> > scripts = get_open_scripts();
|
||||
Vector<Ref<Script>> scripts = get_open_scripts();
|
||||
int scrits_amount = scripts.size();
|
||||
for (int idx_script = 0; idx_script < scrits_amount; idx_script++) {
|
||||
ret.push_back(scripts[idx_script]);
|
||||
|
@ -1641,7 +1641,7 @@ void ScriptEditor::ensure_select_current() {
|
|||
_update_selected_editor_menu();
|
||||
}
|
||||
|
||||
void ScriptEditor::_find_scripts(Node *p_base, Node *p_current, Set<Ref<Script> > &used) {
|
||||
void ScriptEditor::_find_scripts(Node *p_base, Node *p_current, Set<Ref<Script>> &used) {
|
||||
if (p_current != p_base && p_current->get_owner() != p_base)
|
||||
return;
|
||||
|
||||
|
@ -1774,7 +1774,7 @@ void ScriptEditor::_update_help_overview() {
|
|||
return;
|
||||
}
|
||||
|
||||
Vector<Pair<String, int> > sections = se->get_sections();
|
||||
Vector<Pair<String, int>> sections = se->get_sections();
|
||||
for (int i = 0; i < sections.size(); i++) {
|
||||
help_overview->add_item(sections[i].first);
|
||||
help_overview->set_item_metadata(i, sections[i].second);
|
||||
|
@ -1827,7 +1827,7 @@ void ScriptEditor::_update_script_names() {
|
|||
if (restoring_layout)
|
||||
return;
|
||||
|
||||
Set<Ref<Script> > used;
|
||||
Set<Ref<Script>> used;
|
||||
Node *edited = EditorNode::get_singleton()->get_edited_scene();
|
||||
if (edited) {
|
||||
_find_scripts(edited, edited, used);
|
||||
|
@ -2999,9 +2999,9 @@ void ScriptEditor::_history_back() {
|
|||
}
|
||||
}
|
||||
|
||||
Vector<Ref<Script> > ScriptEditor::get_open_scripts() const {
|
||||
Vector<Ref<Script>> ScriptEditor::get_open_scripts() const {
|
||||
|
||||
Vector<Ref<Script> > out_scripts = Vector<Ref<Script> >();
|
||||
Vector<Ref<Script>> out_scripts = Vector<Ref<Script>>();
|
||||
|
||||
for (int i = 0; i < tab_container->get_child_count(); i++) {
|
||||
ScriptEditorBase *se = Object::cast_to<ScriptEditorBase>(tab_container->get_child(i));
|
||||
|
|
|
@ -360,7 +360,7 @@ class ScriptEditor : public PanelContainer {
|
|||
void _update_help_overview();
|
||||
void _help_overview_selected(int p_idx);
|
||||
|
||||
void _find_scripts(Node *p_base, Node *p_current, Set<Ref<Script> > &used);
|
||||
void _find_scripts(Node *p_base, Node *p_current, Set<Ref<Script>> &used);
|
||||
|
||||
void _tree_changed();
|
||||
|
||||
|
@ -437,7 +437,7 @@ public:
|
|||
void get_window_layout(Ref<ConfigFile> p_layout);
|
||||
|
||||
void set_scene_root_script(Ref<Script> p_script);
|
||||
Vector<Ref<Script> > get_open_scripts() const;
|
||||
Vector<Ref<Script>> get_open_scripts() const;
|
||||
|
||||
bool script_goto_method(Ref<Script> p_script, const String &p_method);
|
||||
|
||||
|
|
|
@ -756,7 +756,7 @@ static Node *_find_node_for_script(Node *p_base, Node *p_current, const Ref<Scri
|
|||
return NULL;
|
||||
}
|
||||
|
||||
static void _find_changed_scripts_for_external_editor(Node *p_base, Node *p_current, Set<Ref<Script> > &r_scripts) {
|
||||
static void _find_changed_scripts_for_external_editor(Node *p_base, Node *p_current, Set<Ref<Script>> &r_scripts) {
|
||||
|
||||
if (p_current->get_owner() != p_base && p_base != p_current)
|
||||
return;
|
||||
|
@ -777,14 +777,14 @@ void ScriptEditor::_update_modified_scripts_for_external_editor(Ref<Script> p_fo
|
|||
|
||||
ERR_FAIL_COND(!get_tree());
|
||||
|
||||
Set<Ref<Script> > scripts;
|
||||
Set<Ref<Script>> scripts;
|
||||
|
||||
Node *base = get_tree()->get_edited_scene_root();
|
||||
if (base) {
|
||||
_find_changed_scripts_for_external_editor(base, base, scripts);
|
||||
}
|
||||
|
||||
for (Set<Ref<Script> >::Element *E = scripts.front(); E; E = E->next()) {
|
||||
for (Set<Ref<Script>>::Element *E = scripts.front(); E; E = E->next()) {
|
||||
|
||||
Ref<Script> script = E->get();
|
||||
|
||||
|
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue