Sign in to follow this  
Division

Mix C# and JavaScript good or bad? Variable-Storage differs?

Recommended Posts

Hello,

First question: My team and I want to use C# for the server-side programming and JavaScript for the client-sided things. Is this possible and good to go?

 

Second question: Is the storage between JS and C# different? - Because:


When I wanted to to the following:

player.Vehicle.SetData("test", "Testing123");

I had an event in my client-side (JavaScript) to get this data but the call was

player.vehicle.getVariable('test');

The result was undefined.
 

Is there an equalient function as vehicle.getData in JavaScript?

What am I missing?

Share this post


Link to post
Share on other sites

You want to set SetSharedData instead of SetData on the server side if you want to access that data from clientside

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Sign in to follow this  

  • Recently Browsing   0 members

    No registered users viewing this page.