Question by
codedbythet · Aug 19, 2021 at 03:27 AM ·
c#scripting problemprefabscripting beginnercollision2d
Adding prefab object on collision to a another script
I am looking for a way that when an object is collided with a player, it adds that object prefab to a player script
In this case the object is a weapon and when collided with the player, the weapon prefab tag loads the prefab weapon to the player weapon script.
Comment
Your answer
![](https://koobas.hobune.stream/wayback/20220613041838im_/https://answers.unity.com/themes/thub/images/avi.jpg)
Follow this Question
Related Questions
Delete prefab clone when collided with the player, Unity 2D 1 Answer
arrow from text to object - complete beginner 0 Answers
OnTriggerEnter2D problem 1 Answer
Can Someone Explain Why Message does not show Anything In Inspector 0 Answers
How to make a thrown object land on a certain point e.g a thrown spear landing on its tip 0 Answers