(fixed) Copy and paste verse actor, verse script error

Summary

Did copy and paste the same script, then tried to rename a new duplicate verse actor, worked at first, before it all turned red.

Now its all red in VScode and getting errors from everything. even with fortnite’s verse files (although they have not been touched and does not affect pushing changes and the game).

Please select what you are reporting on:

Verse

What Type of Bug are you experiencing?

Verse

Steps to Reproduce

Mess around with deleting/changing similar “verse actors”? Maybe creating issues around extentions and revision control? Had no issues with the code beforehand or if VScode did some small change that is not seen in the script.

Expected Result

Replace other Verse Actor with new named actor and script.

Observed Result

Getting errors everywhere

VScode, verse error:
“The class (/invaliddomain/testingfeatures/Assets/Custom_gun:)BubbleGunDamageDevice in package testingfeatures is ambiguous with this definition:\ (3532)
class (/invaliddomain/testingfeatures/Assets/Custom_gun:)BubbleGunDamageDevice in package testingfeatures”,

Platform(s)

Win10, most recent VScode + UEFN editor

Additional Notes

"An error occurred while communicating with the game servers (failed to cook module 17c09a77-4ec4-44e1-177c-e8a2839c1527 (artifact 31025584-d65d-4c75-ac01-1cd65bded91c:pc) (cookJobId 20338ba5-d2d8-422d-b807-4b0f19a2f0b9) with error code errors.com.epicgames.cookplugin.versebuildscripterror).

VerseBuild: Error: /FortniteGame/Plugins/GameFeatures/17c09a77-4ec4-44e1-177c-e8a2839c1527/Content/Assets/Custom_gun/BubbleGunDamageDevice.verse(10,26, 52,1): Script error 3532: The class (/invaliddomain/testingfeatures/Assets/Custom_gun:)BubbleGunDamageDevice in package 17c09a77-4ec4-44e1-177c-e8a2839c1527 is ambiguous with this definition:
class (/invaliddomain/testingfeatures/Assets/Custom_gun:)BubbleGunDamageDevice in package 17c09a77-4ec4-44e1-177c-e8a2839c1527

VerseBuild: Error: /FortniteGame/Plugins/GameFeatures/17c09a77-4ec4-44e1-177c-e8a2839c1527/Content/Assets/Custom_gun/BubbleGunDamageDevice.verse(10,26, 52,1) : Script error 3532: The class (/invaliddomain/testingfeatures/Assets/Custom_gun:)BubbleGunDamageDevice in package 17c09a77-4ec4-44e1-177c-e8a2839c1527 is ambiguous with this definition:
class (/invaliddomain/testingfeatures/Assets/Custom_gun:)BubbleGunDamageDevice in package 17c09a77-4ec4-44e1-177c-e8a2839c1527

LogSolLoadCompiler: Error: Forcing exit after Verse compilation failure due to command line parameter -ExitOnVerseCompileFailure"

Only on restarting UEFN (multiple times), now gets verse build error that was not shown before (only on trying to start session before).

What s the first (top-most) error that you get in your copied Verse file? Hover over the first red underlined area to see it.

think it starts from the beginning, from class and red all the way down in the script. Its confusing as it worked perfectly fine before.

Search all your Verse code (shift-ctrl-f on Windows) and see if you have two BubbleGunDamageDevice definitions. That’s what VS code seems to think is happening.

1 Like

ah I see, so one can’t have inactive and active scripts? Thanks a lot, caused quite the mess everywhere, even when removed it before, now everything has calmed down and was easier to work with.

seems like this was half the issue, as it works now, even more stuff seems to be working now compared to at the start with only 1 script. Also suddenly all the red was gone, before I did anything, just thought that was odd. At least removing that duplicate script helped, even though I thought it had to be in the scene to work as an “actor-like” type.

I think all scripts are active, unless they are commented out. You can copy and paste code, as long as you rename things to avoid duplicates.