MaRvZ Posted January 12, 2019 Share Posted January 12, 2019 Hello everyone, is there a way to sync the data between the C# bridge backend and the js frontend like the "setSyncedData" function in GT-MP? Greets! MaRvZ Link to comment Share on other sites More sharing options...
trickory Posted January 13, 2019 Share Posted January 13, 2019 https://wiki.gtanet.work/index.php?title=SetEntitySharedData You can also use OOP methods instead of this static one. Link to comment Share on other sites More sharing options...
MaRvZ Posted January 16, 2019 Author Share Posted January 16, 2019 Does this work between bride c# and rage js? Link to comment Share on other sites More sharing options...
TobseN Posted January 23, 2019 Share Posted January 23, 2019 https://wiki.gtanet.work/index.php?title=SetEntitySharedData This don't works. I tested it. Use player.setdata Link to comment Share on other sites More sharing options...
Xabi Posted January 24, 2019 Share Posted January 24, 2019 8 hours ago, TobseN said: https://wiki.gtanet.work/index.php?title=SetEntitySharedData This don't works. I tested it. Use player.setdata It would be player.SetSharedData, which is exactly the same as SetEntitySharedData(player, data) Both ways work. 1 Link to comment Share on other sites More sharing options...
MaRvZ Posted January 26, 2019 Author Share Posted January 26, 2019 How do I get the data set in C# in the js code? Link to comment Share on other sites More sharing options...
Flashrex Posted January 27, 2019 Share Posted January 27, 2019 Server-Side C#: player.SetSharedData("ExampleData", example); Client-Side js: var example = mp.players.local.player.getVariable('ExampleData'); 3 Link to comment Share on other sites More sharing options...
DonnerGaming Posted June 19, 2022 Share Posted June 19, 2022 wie funktioniert dies in der neueren Rage version? Link to comment Share on other sites More sharing options...
DevMarvin Posted August 24, 2022 Share Posted August 24, 2022 Genau so wie oben beschrieben. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now