consulo / consulo-unity3d

Frameworks: Unity3D
Apache License 2.0
103 stars 10 forks source link

Steamworks Dependency Not Detected #199

Closed TheYellowArchitect closed 3 years ago

TheYellowArchitect commented 3 years ago

The code in Consulo, using Steamworks; library's functions is full of errors, yet, it compiles normally, as expected in Unity, and the logic works (code below shows steam username, and also unlocks achievements - it works) I tried clicking "Re-Import Unity Project" as suggested here https://github.com/consulo/consulo-unity3d/issues/194 but it didn't work

Image of the project folder consulo 14

Image of the manifest.json (no idea why it's so empty) Computer

Trying to find declaration of Steamworks; -> "Cannot find declaration"

Link to Steamworks library and how I installed it https://steamworks.github.io/installation/ I did Option A, aka downloaded the unity package, and imported it. It works properly btw, the issue is that Consulo doesn't detect the library/dependency, making it very hard to code :(

Specs Windows 7 x64 Unity 2018.1.1f1 Consulo 2020.12

Minor note that I don't use Consulo plugin for Unity, but this is no problem for me, as I just ctrl+shift+N to edit any file, then compiling in Unity like normal :)

Any idea how to fix this? I can post everything you wish if it helps :)

VISTALL commented 3 years ago

Hello. You called Re-Import Unity project?

VISTALL commented 3 years ago

I will try reproduce this bug

TheYellowArchitect commented 3 years ago

Hello. You called Re-Import Unity project?

Yup, at the root of the project 14

I will try reproduce this bug

Well, it is a bizzare bug, and probably related to packages or something I cannot code until I fix this so tell me if you want anything I can help with :+1:

VISTALL commented 3 years ago

Can you find file 'isteamfriends.cs' and open it in Consulo?

TheYellowArchitect commented 3 years ago

14

VISTALL commented 3 years ago

Oh. Steam API protected by desktop defines, which is not provided when UnityEditor is not resolved (Editor plugin).

You can add variable by hand here (https://klikr.org/99cd13aea3be698a6b84cfa939f3.png)

Or use plugin (https://consulo.help/plugins/consulo.unity3d/using_consulo_as_external_editor/) and reimport.

TheYellowArchitect commented 3 years ago

Or use plugin (https://consulo.help/plugins/consulo.unity3d/using_consulo_as_external_editor/) and reimport.

I cannot use plugin because of an old issue, but it's no issue, so I went to put variable by hand

Any suggestion? Did I do something wrong? Perhaps it wants Steamworks with caps?

https://user-images.githubusercontent.com/25630803/114198833-9eec3380-9908-11eb-8b2d-e3626d5bf49f.mp4

VISTALL commented 3 years ago

Add 'UNITY_STANDALONE_WIN'

VISTALL commented 3 years ago

there

#if !(UNITY_STANDALONE_WIN || UNITY_STANDALONE_LINUX || UNITY_STANDALONE_OSX || STEAMWORKS_WIN || STEAMWORKS_LIN_OSX)
    #define DISABLESTEAMWORKS
#endif

protectors

UNITY_STANDALONE_WIN || UNITY_STANDALONE_LINUX || UNITY_STANDALONE_OSX || STEAMWORKS_WIN || STEAMWORKS_LIN_OSX

TheYellowArchitect commented 3 years ago

14

Bless you dude. Every time I have any issue with Consulo, you reply instantly to fix, yet you are just 1 person, and are not even paid for this. Incredible respect, and thank you for assisting me yet again <3

VISTALL commented 3 years ago

Thanks. But you need always add it on each reimport :(

TheYellowArchitect commented 3 years ago

It's alright, definitely better than not being able to code at all :heart: You won me a day of coding (I didn't expect a reply since tomorrow) so spending 1 minute for each re-import is already worth it xaxaxaxa

VISTALL commented 3 years ago

Hello. I add some hacky method for adding custom defines.(works for last nigthly builds)

file

Assets/consulo.rsp

with lines

-define:UNITY_ANDROID