Is there an update I've missed - the wiki Steam Achievement code by Alverik no longer works for me with the current Steamworks from Github - AKA Release 20.2.0. and in Unity 2022.3.47
Alverik's Steam Achievement plug in generates an error 'The type of namespace name 'Steamworks' could not be found' - I've used it fine in older projects in alternative Unity versions, so perhaps I am missing something in my project?
I got that error too -- I had to download Steamworks from the package manager as well and add both asmdef files from that package to the ac.asmdef file on my front!
I have Steamworks downloaded/installed using the GitHub import via the package manager, and the SteamManager.cs script in my 'Scripts/Steamworks.net' folder - as i've done before in other projects. I added SteamManager.cs to the first Object in my first loaded Scene.
I've added both asmdef files from that package to the ac.asmdef file as suggested
I started a new project to test... this time in Unity 22.3.5 - added just AC, added Steamworks via GitHub, created the suggested Plugins Assembly Definition Reference files, also tried various Namespace in the SteamManager script.
I've added References to the ac.asmdef as you suggested too.
I'm using the updated base script you have linked above for the AC ActionUnlockAchievement.cs
I still get 'error CS0103: The name 'SteamManager' does not exist in the current context'
Steamworks / Steam manager seem to be running, Steam knows my game is running on clicking play in unity.. but the AC ActionUnlockAchievement.cs just can't find 'SteamManager'.
I am also keen to learn this and integrate the Steam api and achievements in my AC game, but it still seems unclear for me.
and how would it be then possible to call those achievement unlocks through AC action-list? is it possible at all without coding knowledge?
Bedroomdev.. it was really easy before... and worked for me 2 projects.
Using ActionUnlockAchievement.cs script from the AC Wiki, placed into a custom Actions folder for AC - all I had to do was define Achievement names on Steam, then in Unity, via an action (in a cutscene or similar AC action script), input the same Achievement name.
@TheBear thanks , I have Steam manager Running in First scene of my game.
Eventhough you seem to find it unfunctional recently, i would try it right now. thanks
And... should i add Steammanager(EmptyObject) to all Scenes? It means i must make it a prefab and add to all scenes or just add the component to AC game Manager?
I have doubts about it too.
I should say that Steammanager componenet empty object is only placed inmy first scene where the game loads. in my second scene I used a trigger and in its action list i called My Test Achievement with it's API name. But nothnig happens.
I supose , like i see Steam overlay in runtime, I should also see Achievements too. but i see nothing.
@ABABAB I saw your |ScreenShots and ac.ASmdef thing!!!
I can not even find such a thing in my project Folders. your screenshots except one of the AC Menu manager shot is very unknown to me. ( and i could not even get a clue why you reffer to Menu Manager?!)
Would you please tell me where i can access this inspector interface "Assembly..."?
I just imported SteamWorks.net and Replaced My APP ID with 480 in txt file. and then tried to test Achievements and it does not work.
I also get no ID in Steam achievements page. Only API name. no ID like other have such 10/1 or 1/0 .
Latest Update from me.
I got it Running.
Just Imported SteamWorks.net
then used ActionUnlockAchievements.cs but the @ChrisIceBox Updated Version which i mentioned its link above.
At this level i could not see any changes.
I closed Unity and ran it again.
Worked for me without any troubles.
Now Using achievements seems as easy as Switching Camera in AC.
Unfortunately none of the above works for me, on my current project or in an empty new created project.
I've done this before, and never had an issue so I must be missing something, or some setting that should have automatic happened - I just cant work it out..
The error I have, from the Custom AC script is... "ActionUnlockAchievement.cs(3,7): error CS0246: The type or namespace name 'Steamworks' could not be found (are you missing a using directive or an assembly reference?)"
I have Steamworks installed via GIT, I've the current SteamManager.cs and have tried older. I have made references to Steamworks in a Steamworks.asmdef in a Plugins folder, and I've added those same Steamworks references to the AC.asmdef. I have SteamManager.cs linked to my first scenes first object, and I have tried attaching to the AC GameEngine prefab.
Whenever I search 'Steamworkscould not be found' etc i read advice to create an assembly reference, which I've done, but nothing changed... unless I did it wrong.
Comments
I haven't used it myself, but there is a Steam achievement Action available on the AC wiki:
https://adventure-creator.fandom.com/wiki/Unlock_Steam_Achievement_(AC_Action)
@ChrisIceBox Ah I think that link might be broken it seems
Copy/paste it - the auto-linking didn't work properly.
Ah! Hadn't realized part of the URL was grayed at the end -- Thanks Chris, it's working now!
Is there an update I've missed - the wiki Steam Achievement code by Alverik no longer works for me with the current Steamworks from Github - AKA Release 20.2.0. and in Unity 2022.3.47
Alverik's Steam Achievement plug in generates an error 'The type of namespace name 'Steamworks' could not be found' - I've used it fine in older projects in alternative Unity versions, so perhaps I am missing something in my project?
@TheBear
I got that error too -- I had to download Steamworks from the package manager as well and add both asmdef files from that package to the ac.asmdef file on my front!
https://drive.google.com/file/d/1_PC19vwxfrBTIUkonMLNfPDUjC33lSGP/view?usp=sharing
I've done the above, thanks for the suggestion on the AC asmdef..... and now i've got the error...
"The name 'SteamManager' does not exist in the current context" ?
I have Steamworks downloaded/installed using the GitHub import via the package manager, and the SteamManager.cs script in my 'Scripts/Steamworks.net' folder - as i've done before in other projects. I added SteamManager.cs to the first Object in my first loaded Scene.
I've added both asmdef files from that package to the ac.asmdef file as suggested
What am I missing?
@TheBear Sorry this got lost in the cracks -- did you figure it out by any chance?
Let me screenshot what I have just in case!
https://drive.google.com/file/d/1L5k16MjWlOR274BXddW0F3lRhzLg2cE8/view?usp=drive_link
https://drive.google.com/file/d/1-aytQMORv-BsicTri7fpntVEf1_xGAUt/view?usp=sharing
This is the base script I used as well:
https://drive.google.com/file/d/1CGrkNPbt0RZrdYR0RswysRrsZ9py0kw1/view?usp=drive_link
Sadly still unable to get this working.
I started a new project to test... this time in Unity 22.3.5 - added just AC, added Steamworks via GitHub, created the suggested Plugins Assembly Definition Reference files, also tried various Namespace in the SteamManager script.
I've added References to the ac.asmdef as you suggested too.
I'm using the updated base script you have linked above for the AC ActionUnlockAchievement.cs
I still get 'error CS0103: The name 'SteamManager' does not exist in the current context'
Steamworks / Steam manager seem to be running, Steam knows my game is running on clicking play in unity.. but the AC ActionUnlockAchievement.cs just can't find 'SteamManager'.
I am also keen to learn this and integrate the Steam api and achievements in my AC game, but it still seems unclear for me.
and how would it be then possible to call those achievement unlocks through AC action-list? is it possible at all without coding knowledge?
Bedroomdev.. it was really easy before... and worked for me 2 projects.
Using ActionUnlockAchievement.cs script from the AC Wiki, placed into a custom Actions folder for AC - all I had to do was define Achievement names on Steam, then in Unity, via an action (in a cutscene or similar AC action script), input the same Achievement name.
(This was after installing the Steamworks and SteamManager to your unity project. using - https://steamworks.github.io/installation/ )
However, I now can't get ActionUnlockAchievement.cs to work.
@TheBear if you don't mind me asking, can I see screenshots of the error you are getting?
Also another thing -- did you upload your game build to steam and try from there? Or are you just using Unity?
I'm also wondering if you've seen these just as sanity in case --
https://github.com/rlabrecque/Steamworks.NET/issues/642
https://stackoverflow.com/questions/73861855/importing-a-namespace-from-unity-packages-c-sharp-the-type-or-namespace-name
@TheBear thanks , I have Steam manager Running in First scene of my game.
Eventhough you seem to find it unfunctional recently, i would try it right now. thanks
And... should i add Steammanager(EmptyObject) to all Scenes? It means i must make it a prefab and add to all scenes or just add the component to AC game Manager?
I have doubts about it too.
Ok I tested To use Achievements.
I used Updated Script ActionUnlockAchievement by @ChrisIceBox himself which is Here: https://adventurecreator.org/forum/discussion/13128/ac-steam-achievements-not-working-any-more-mac-only
I should say that Steammanager componenet empty object is only placed inmy first scene where the game loads. in my second scene I used a trigger and in its action list i called My Test Achievement with it's API name. But nothnig happens.
I supose , like i see Steam overlay in runtime, I should also see Achievements too. but i see nothing.
@ABABAB I saw your |ScreenShots and ac.ASmdef thing!!!
I can not even find such a thing in my project Folders. your screenshots except one of the AC Menu manager shot is very unknown to me. ( and i could not even get a clue why you reffer to Menu Manager?!)
Would you please tell me where i can access this inspector interface "Assembly..."?
I just imported SteamWorks.net and Replaced My APP ID with 480 in txt file. and then tried to test Achievements and it does not work.
I also get no ID in Steam achievements page. Only API name. no ID like other have such 10/1 or 1/0 .
Latest Update from me.
I got it Running.
Just Imported SteamWorks.net
then used ActionUnlockAchievements.cs but the @ChrisIceBox Updated Version which i mentioned its link above.
At this level i could not see any changes.
I closed Unity and ran it again.
Worked for me without any troubles.
Now Using achievements seems as easy as Switching Camera in AC.
Whoohoo! So happy to hear it @Bedroomdev !
I hope @TheBear this solution can also work for your project?
Unfortunately none of the above works for me, on my current project or in an empty new created project.
I've done this before, and never had an issue so I must be missing something, or some setting that should have automatic happened - I just cant work it out..
The error I have, from the Custom AC script is... "ActionUnlockAchievement.cs(3,7): error CS0246: The type or namespace name 'Steamworks' could not be found (are you missing a using directive or an assembly reference?)"
I have Steamworks installed via GIT, I've the current SteamManager.cs and have tried older. I have made references to Steamworks in a Steamworks.asmdef in a Plugins folder, and I've added those same Steamworks references to the AC.asmdef. I have SteamManager.cs linked to my first scenes first object, and I have tried attaching to the AC GameEngine prefab.
Whenever I search 'Steamworkscould not be found' etc i read advice to create an assembly reference, which I've done, but nothing changed... unless I did it wrong.