Hi I am a beginner and is currently making a 3D FPS game. I’m having problems on the weapon and bullet, it always sends an error prompt and it doesnt work despite the code coming from my professor and also cross-checked my other classmates’s works and theirs have worked. I have tried everything for hours but I can’t fix it.
the BulletInstance.rigidbody.teleport(BulletPosition);
is the one always erroring.
I an trying to get the sphere to be the bullet on the icing bag.
It looks like you have a template asset for your bullet. You would do something like this:
drag the template into the Hierarchy panel
select the entity in the template with the bullet render component
add rigidbody and collision components to the same entity (and configure the properties correctly)
apply the template overrides in the Inspector
delete the template from your Hierarchy
(Note that you have to do the above because there’s no dedicated template editor in the Editor…so you have to edit your template assets via the Hierarchy panel and Inspector)