When model with scripts is duplicated, only one of them is fully functional

Basically, I’m creating this combat game involving enemies that can fire at players and create shields. I’m planning on adding multiple of the same enemies, but when I duplicate the enemy, only the original enemy is fully functional (creates shields, fires at players) while the other duplicates just fire without creating any shields. I tried searching other similar forums for the same issue, but so far I haven’t had any luck finding results that actually worked for me.

Most likely the script you are using is able to find both the models. If they are by the same name the script will only use the first model. A example of this would be

game.workspace.MyModel.anchored = false

If there are multiple of “MyModel” in the workspace then only one of them would be unanchored. One way to fix this is to instead put the script inside the model and do something similar to the below.

script.parent.anchored = false

Let me know if its something else and more info if so.