Repository: godot
Issue: `get_script_method_list()` lists functions from inherited scripts
Labels: discussion,topic:core,documentation

### Tested versions

- v4.2.2.stable.official [15073afe3]
- v4.3.stable.mono.official [77dcf97d8]
- v4.4.dev2.official [97ef3c837]

### System information

Windows 11

### Issue description

From the official [documentation](https://docs.godotengine.org/en/stable/classes/class_script.html#class-script-method-get-script-method-list) the function `get_script_method_list` should `Returns the list of methods in **this** Script.`

However, the methods of the inherited scripts are also listed, contrary to the documentation.

```gd
class_name CustomClassExtendsCustomClass
extends CustomResourceTestClass

# override
@warning_ignore("untyped_declaration")
func foo2():
	return "foo2 overriden"

func bar2() -> String:
	return bar()
```


```gd
Script res://CustomClassExtendsCustomClass.gd
{ "name": "foo2", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 0, "hint": 0, "hint_string": "", "usage": 131072 } }
{ "name": "bar2", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 4, "hint": 0, "hint_string": "", "usage": 0 } }
{ "name": "foo", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 4, "hint": 0, "hint_string": "", "usage": 0 } }
{ "name": "foo2", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 0, "hint": 0, "hint_string": "", "usage": 131072 } }
{ "name": "foo_void", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 0, "hint": 0, "hint_string": "", "usage": 6 } }
{ "name": "bar", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 4, "hint": 0, "hint_string": "", "usage": 0 } }
{ "name": "foo5", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 0, "hint": 0, "hint_string": "", "usage": 6 } }

Script res://CustomResourceTestClass.gd
{ "name": "foo", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 4, "hint": 0, "hint_string": "", "usage": 0 } }
{ "name": "foo2", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 0, "hint": 0, "hint_string": "", "usage": 131072 } }
{ "name": "foo_void", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 0, "hint": 0, "hint_string": "", "usage": 6 } }
{ "name": "bar", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 4, "hint": 0, "hint_string": "", "usage": 0 } }
{ "name": "foo5", "args": [], "default_args": [], "flags": 1, "id": 0, "return": { "name": "", "class_name": &"", "type": 0, "hint": 0, "hint_string": "", "usage": 6 } }
```

### Steps to reproduce

Load the attached project and run the test scene.

### Minimal reproduction project (MRP)

[script_methods.zip](https://github.com/user-attachments/files/17026664/script_methods.zip)