Remote Resources Members Group Not Showing Export Categories Correctly.
Introduction
As a Godot Engine user, you may have encountered issues with the Remote Resources members group not showing export categories correctly. This problem can be frustrating, especially when trying to troubleshoot and optimize your project. In this article, we will delve into the issue, provide a step-by-step guide to reproduce the problem, and offer a minimal reproduction project (MRP) to help you replicate and resolve the issue.
Tested Versions
The issue has been reproduced in the following versions of the Godot Engine:
- v4.4.stable.steam (4c311cbee)
- v4.3.stable.official (77dcf97d8)
System Information
The system information for the test environment is as follows:
- Operating System: Windows 11
- Godot Engine Version: v4.4.stable.steam (4c311cbee)
- Vulkan Version: 1.3.289
- Forward Mobile: Using Device #0: NVIDIA
- Graphics Card: NVIDIA GeForce RTX 4060 Ti
Issue Description
The issue lies in the Remote Resources members group, specifically in the way it parses export categories. This problem seems to be related to an engine issue, as the Constants section appears to be working as intended.
Relevant Code
The relevant code snippets are provided below:
item.gd
extends Resource
class_name Item
enum ItemType {
ONE_HAND_MELEE,
TWO_HAND_MELEE,
ONE_HAND_RANGE,
TWO_HAND_RANGE,
CONSUMABLE }
@export var texture: Texture2D
@export var quantity: int
@export var stats: Stats
@export var _item_type: ItemType
func _init(item_type: ItemType, quantity: int, image: String) -> void:
self.stats = Stats.default(item_type)
self._item_type = item_type
self.quantity = quantity
self.texture = load(image)
Stats.gd
extends Resource
class_name Stats
enum StatModifiers {
STR,
...
}
@export_category("Weapons")
## Attack range of the item.
@export var attack_range: int
## Damage that the item will do when used in a physical attack. (magic damage is calculated elsewhere)
@export var damage: int
@export_category("Stat Modifiers")
## What `modifier`, if any should be applied to the item
@export var modifier: StatModifiers
## Value assigned to the `modifier`. This number can be negative for curses
@export var modifier_value: int
@export_category("General Stats")
## Name of the `item`. Assigned on creation
@export var name: String
## Durability of the `item`. Determines the number of uses (-1 is no durability)
@export var durability: int
func _init(type) -> void:
pass
static func default(type) -> Stats:
var stat = Stats.new(type)
match int(type):
Item.ItemType.ONE_HAND_MELEE:
stat.attack_range = 1
stat.damage = 2
stat.modifier = StatModifiers.STR
stat.modifier_value = 2
pass
Item.ItemType.TWO_HAND_MELEE:
stat.attack_range = 2
stat.damage = 5
pass
Item.ItemType.CONSUMABLE:
stat.modifier = StatModifiers.HP
stat.name = "Health Potion"
pass
return stat
Instance being viewed in Inspector
item = Item.new(Item.ItemType.ONE_HAND_MELEE, 1, "uid://bxk64jgm0mv5k")
Remote Scene Tree:
The Remote Scene Tree is provided in the form of an image, which can be viewed in the attached project.
Steps to Reproduce
To reproduce the issue, follow these steps:
Step 1: Run project, and click remote/PanelContainer
The first step is to run the project and click on the remote/PanelContainer.
Step 2: Inspect
the Slot Item Resource
The second step is to inspect the Slot Item Resource.
Step 3: `Inspect the Class object, Stats
The third step is to inspect the Class object, Stats.
Step 4: Problem is evident. Members group has incorrect parsing of the export_categories present, while Constants parses correctly.
The fourth step is to observe the problem, where the Members group has incorrect parsing of the export categories, while the Constants section parses correctly.
Minimal Reproduction Project (MRP)
The Minimal Reproduction Project (MRP) for this issue is provided in the form of a zip file, which can be downloaded from the following link:
This MRP contains the necessary files and setup to reproduce the issue, making it easier for you to replicate and resolve the problem.
Conclusion
Introduction
In our previous article, we explored the issue of the Remote Resources members group not showing export categories correctly in the Godot Engine. In this Q&A article, we will address some of the most frequently asked questions related to this issue.
Q: What is the cause of this issue?
A: The cause of this issue is related to an engine bug, specifically in the way the Remote Resources members group parses export categories. This problem seems to be specific to the Godot Engine and has been reproduced in multiple versions.
Q: Is this issue specific to a particular version of the Godot Engine?
A: Yes, this issue has been reproduced in the following versions of the Godot Engine:
- v4.4.stable.steam (4c311cbee)
- v4.3.stable.official (77dcf97d8)
Q: Can I reproduce this issue in a local project?
A: Yes, you can reproduce this issue in a local project by following the steps outlined in our previous article. The Minimal Reproduction Project (MRP) provided in the article contains the necessary files and setup to reproduce the issue.
Q: How can I resolve this issue?
A: To resolve this issue, you can try the following:
- Update to the latest version of the Godot Engine.
- Use the latest version of the Remote Resources plugin.
- Check for any conflicts with other plugins or scripts in your project.
- If none of the above solutions work, you can try creating a new project and importing your assets to see if the issue persists.
Q: Is this issue specific to the Remote Resources plugin?
A: No, this issue is not specific to the Remote Resources plugin. However, the plugin may be affected by the engine bug causing the issue.
Q: Can I get help from the Godot Engine community?
A: Yes, you can get help from the Godot Engine community by posting in the official forums or Discord channel. The community is known for its helpfulness and willingness to assist with issues like this.
Q: Is there a workaround for this issue?
A: Yes, there is a workaround for this issue. You can try using the Constants section instead of the Members group to export your categories. However, this may not be a suitable solution for all projects, and it's recommended to wait for a fix from the Godot Engine team.
Q: When can I expect a fix for this issue?
A: The Godot Engine team is working on a fix for this issue, but no official release date has been announced. We recommend keeping an eye on the official forums and Discord channel for updates on the issue.
Conclusion
In conclusion, the Q&A article provides answers to some of the most frequently asked questions related to the Remote Resources members group not showing export categories correctly in the Godot Engine. We hope this article has been helpful in providing a clear understanding of the issue and its resolution.