Hi, I am trying to make a workbench mechanic, but I want to cast my weapons for the status of ammo and current damage for each weapon. How can I do this without errors for reference?
If you could give me an answer to that, I would appreciate it.
If all your weapons are children of a base weapon class, you shouldn’t need to cast to all children. Just cast to the parent class. The parent class should have the vars for damage, ammo count/capacity, ammo type, and such.