| 1193 | } |
| 1194 | |
| 1195 | bool GDScript::inherits_script(const Ref<Script> &p_script) const { |
| 1196 | Ref<GDScript> gd = p_script; |
| 1197 | if (gd.is_null()) { |
| 1198 | return false; |
| 1199 | } |
| 1200 | |
| 1201 | const GDScript *s = this; |
| 1202 | |
| 1203 | while (s) { |
| 1204 | if (s == p_script.ptr()) { |
| 1205 | return true; |
| 1206 | } |
| 1207 | s = s->_base; |
| 1208 | } |
| 1209 | |
| 1210 | return false; |
| 1211 | } |
| 1212 | |
| 1213 | GDScript *GDScript::find_class(const String &p_qualified_name) { |
| 1214 | String first = p_qualified_name.get_slice("::", 0); |
no test coverage detected