Difference between TSubclassOf<AGun> GunClass; and AGun* Gun;

I don’t know the difference between TSubclassOfAGun>GunClass; and AGun*Gun; as in the title.

I know AGun* Gun is the real Gun, but I don’t know what TSubclassOfGunClass is.

It’s essentially holding a type as a variable.

So you keep variables in AGun type?

Why do you play TSubclassOf?

If you want to pass type to a function, not an object of that type, the type itself. How would you do that?

I understand now. Thank you!

This topic was automatically closed 20 days after the last reply. New replies are no longer allowed.

Privacy & Terms