Addition of achievement system not running the game normally

Hello everyone!



I did everything as it said on https://hackmd.io/@Mirai/Steamworks_NWjs_eng to add the achievements to my game, and I used the plugin https://rabbitteaparty.itch.io/nekogakuen-steamworksplus to add the achievement inside the game.



I tested the nwjs versions, and 0.94 was the one that when I tried to open the game on steam, didn't generate any error saying that the nw version needs to be updated. But as you can see in the video below, the game just keeps opening and closing.




The greenwork version I also checked before downloading it from the site https://github.com/greenheartgames/greenworks/releases/tag/v0.19.0 , and as you can see from the title, the version compatible with nwjs is 0.94.0, the same version I downloaded and put in the MZ folder, and I wasn't sure if it needed it or not, I also put it in the game folder... (If I'm wrong, I feel like an idiot)



Well... I don't know what else to do. I really don't.

I've tried hundreds of times to add the achievements, and every time I try to open the game, it keeps trying to start up endlessly, so I imagine something is in conflict...



I've also contacted some programmers to pay for the service of adding the achievements, but maybe it's not a good idea due to future updates, I'll need any way that works on my machine to export correctly and work as usual.



Thanks in advance to anyone who can help, but honestly, I'm at my wits' end on this subject. I'll probably give up soon, so I apologize in advance if I give up in the middle.
I haven't tried the newest version of the plugin, but neko gakuen has a Check Purchased Games parameter if you turn it on during test, it may cause the close/open problem so maybe you can turn it off during playtest.
I haven't tried on MZ but MV's playtest also has a problem that greenworks thinks you are playing RMMV. It makes sense because MV is launched using steam and playtest is called by MV. If so you need to test the game outside of the editor or launch it using steam.
Oh, it worked. Just like you said, I opened the plugin manager, and deactivated the check purchase option, and it opened normally

But the achievement isn't released...
I've added everything requested in the links I attached earlier, but did I do something wrong?

I wonder if it's necessary to use the common event ID...
Captura de tela 2025-01-15 222755.png
Like I said you need to login using steam. The API needs to get your game's steam id, but if you are running playtest, it is possible the ID is the editor's. You can upload the game on steam and run it from there if it still doesn't work.
Yes, I did that and it didn't unlock the achievement.

To test it, I tried the NekoGakuen_SteamworksPLus plugin, and it generated the error below...
Is there any chance of this error being fixed? Maybe it only works with this plugin, and not the more basic version? that I tested before whose name is “NekoGakuen_SteamworksAPI”.


The error says: Failed to load shared library: Could not find the specified module.
It means your greenworks and/or steam libraries are not in their correct places?
If you download a 64bit nw.js you need to use 64 bit version, check their documents for details.
The versions of nw and greenwork, at first I made sure to download different versions, and as expected, gave error and that was the purpose. Then I downloaded the versions compatible with MZ, because it was generating an error as I just explained, and then as I said in the first message of this post, the downloaded versions are compatible, so I can only imagine that something is missing, or in the wrong place as you said, or more likely, maybe I don't know how to understand what's missing on my own.

I've attached an image of the game's base folder, greenworks is there, and so is its lib folder... Is something missing?
So you are using 64bit version, then what's inside the lib folder?
Inside “lib” is the only file that was inside the .rar I downloaded from greenwork
1737016826365.png

Then you need steam sdk files and the correct version as well.
Steam_api64 is easy, and I already have it, but where can I find this file called “sdkencryptedappticket64.dll”?
It's inside sdk\public\steam\lib\win64
Okay. Thank you! I did what you said, but the error still appears...

Just in case, I tested it on steam but the same thing happened

The compatible NW version is already inside the game folder, and I've also replaced the files of the same version inside the rpg maker mz folder...
I don't know what it could be
Greenworks v0.19.0
NW.js v0.94.0
Steamworks SDK 1.61

Are all those versions correct?
Yes, I left everything separate in a folder



Hello Utunnels, thank you for your help. Unfortunately it didn't work.



I tried to follow the tutorial in the link below and use the SteamLink plugin, but I haven't succeeded yet. I did the tests several times on steam and nothing.






Note: At first I tried to use the plugin created by the same person from the link below, but unfortunately it didn't appear in the "Plugin command", so I tried in "Script" to write what he had said, but it didn't work either. Too bad...



And the previous error was solved when I removed the NekoGakuen plugin and tested it with SteamLink.



Well, I'm going to end the day. I've tried many times and I'm tired of not succeeding after so many attempts.

@utunnels

Thanks to your help I was able to understand part of the process that I didn't understand before.



The game opened correctly, I just don't know why the achievement isn't releasing, but whatever I give up
Good luck with your game.
By the way, "Could not find the specified module." is the message when I delete those dlls or the node file, if the translator is correct.
1737079196728.png

If I used wrong version of steam dlls, it says "The specified procedure could not be found".
So it is strange you saw that error if you have all the files in the lib folder.
It is also possible you have multiple copies of greenworks.js and the plugin(s) loads another one from another place but I can't say without seeing all your files.




I didn't use nekogakuen's plugins, because I only need the achievement function.
My setup is quite simple, just call the function ActiveAchievement to active an achievement.
1737080811820.png

For example:
1737080555989.png

My plugin code:
JavaScript:
var greenworks = null;
 try{
   greenworks = require('./greenworks');
   greenworks.init();
 }catch(ex){
   console.log(ex);
    greenworks = null;
 };


 function ActiveAchievement(achievement, success_callback, error_callback){
   try{
    success_callback = success_callback||function(){};
    error_callback = error_callback||function(){};
     greenworks.activateAchievement(achievement, success_callback, error_callback);
   }catch(ex){
     console.log('failed to active achievement: ', achievement);
     console.log(ex);
   }
 }
The problem of the module not being found was only generated when the NekoGakuen plugin was activated, and when I deactivated it, the problem disappeared...



Well, I'm going to try it again with the function to call the achievement you sent. If I'm successful, I'll be back to tell you about it.



Thanks again!
Oh my god...(≧▽≦)(≧▽≦)(≧▽≦)
It worked!!!

Marry me, Utunnels!!

The plugin I created using the code you sent above solved the problem!
The files were also correct, just as you said!

Thank you so much!!!
Just one question... In the tutorial I told you about, he said to create this “appid” file... Is that necessary...?


As a precaution, I'm going to paste it into the backup projects folder I've set aside to test, but I'd like to know if it's necessary, since it's also something I'm going to learn

Original thread: https://forums.rpgmakerweb.com/threads/addition-of-achievement-system-not-running-the-game-normally.174736/