Skip to content
This repository has been archived by the owner on Aug 22, 2018. It is now read-only.

Can't use GameStudio with custom-built Paradox #88

Closed
gitfool opened this issue Nov 6, 2014 · 5 comments
Closed

Can't use GameStudio with custom-built Paradox #88

gitfool opened this issue Nov 6, 2014 · 5 comments
Assignees
Milestone

Comments

@gitfool
Copy link

gitfool commented Nov 6, 2014

... when opening a project built with a custom build of Paradox and the SiliconStudioParadoxDir environment variable is also pointing to this custom build:

Paradox Version: 1.0.0-beta02
GameStudio Version: 4
Error Message: Unexpected exception
User: Sean
Current Directory: C:\ProgramData\Silicon Studio Corp\Paradox\GamePackages\Paradox.1.0.0-beta02\Bin\Windows-Direct3D11
Command Line Args: 
Exception type: InvalidCastException
Exception message: [A]SiliconStudio.Paradox.Effects.ParameterKey`1[SiliconStudio.Paradox.Graphics.SamplerState] cannot be cast to [B]SiliconStudio.Paradox.Effects.ParameterKey`1[SiliconStudio.Paradox.Graphics.SamplerState]. Type A originates from 'SiliconStudio.Paradox, Version=1.0.0.0, Culture=neutral, PublicKeyToken=bacacc89c3b6d556' in the context 'Default' at location 'C:\ProgramData\Silicon Studio Corp\Paradox\GamePackages\Paradox.1.0.0-beta02\Bin\Windows-Direct3D11\SiliconStudio.Paradox.dll'. Type B originates from 'SiliconStudio.Paradox, Version=1.0.0.0, Culture=neutral, PublicKeyToken=bacacc89c3b6d556' in the context 'Default' at location 'C:\ProgramData\Silicon Studio Corp\Paradox\GamePackages\Paradox.1.0.0-beta02\Bin\Windows-Direct3D11\SiliconStudio.Paradox.dll'.
Inner exception type: 
Inner exception message: 
StackTrace:    at SiliconStudio.Paradox.Graphics.Effect.UpdateResourceBindingKey(EffectParameterResourceData& binding)
   at SiliconStudio.Paradox.Graphics.Effect.LoadDefaultParameters()
   at SiliconStudio.Paradox.Graphics.Effect.Initialize(GraphicsDevice device, EffectBytecode byteCode, ParameterCollection usedParameters)
   at SiliconStudio.Paradox.Graphics.Effect..ctor(GraphicsDevice device, EffectBytecode bytecode, ParameterCollection usedParameters)
   at SiliconStudio.Paradox.Graphics.SimpleEffect..ctor(GraphicsDevice graphicsDevice)
   at SiliconStudio.Paradox.Graphics.GraphicsDevice..ctor(GraphicsAdapter adapter, GraphicsProfile[] profile, DeviceCreationFlags deviceCreationFlags, WindowHandle windowHandle)
   at SiliconStudio.Paradox.Graphics.GraphicsDevice.New(GraphicsAdapter adapter, DeviceCreationFlags creationFlags, WindowHandle windowHandle, GraphicsProfile[] graphicsProfiles)
   at SiliconStudio.Paradox.Games.GamePlatform.CreateDevice(GraphicsDeviceInformation deviceInformation)
   at SiliconStudio.Paradox.Games.GamePlatform.ChangeOrCreateDevice(GraphicsDevice currentDevice, GraphicsDeviceInformation deviceInformation)
   at SiliconStudio.Paradox.Games.GraphicsDeviceManager.CreateDevice(GraphicsDeviceInformation newInfo)
   at SiliconStudio.Paradox.Games.GraphicsDeviceManager.ChangeOrCreateDevice(Boolean forceCreate)
   at SiliconStudio.Paradox.Games.GraphicsDeviceManager.SiliconStudio.Paradox.Games.IGraphicsDeviceManager.CreateDevice()
   at SiliconStudio.Paradox.Games.GameBase.InitializeBeforeRun()
   at SiliconStudio.Paradox.Games.GamePlatform.OnInitCallback()
   at SiliconStudio.Paradox.Games.GameWindowDesktop.Run()
   at SiliconStudio.Paradox.Games.GamePlatform.Run(GameContext gameContext)
   at SiliconStudio.Paradox.Games.GameBase.Run(GameContext gameContext)
   at SiliconStudio.Paradox.GameStudio.ParadoxViewService.ParadoxUIThread(Object projectSession)
   at SiliconStudio.Core.Diagnostics.SafeAction.<>c__DisplayClass4.<Wrap>b__3(Object obj)

Simply changing the SiliconStudioParadoxDir environment variable back to the installed build is not sufficient to avoid the crash. The project must then be rebuilt before it successfully opens in GameStudio.

@xen2
Copy link
Contributor

xen2 commented Nov 6, 2014

Thanks for pointing that out.

It is because editor assemblies are signed, but of course your custom-built Paradox is not (internally, we usually work with non-signed version of editor so we didn't realize).

We will discuss possible solutions and let you know.

@xen2 xen2 changed the title GameStudio crashes with InvalidCastException Can't use GameStudio with custom-built Paradox Nov 6, 2014
@xen2
Copy link
Contributor

xen2 commented Nov 13, 2014

Seems like Microsoft has an official solution for that since yesterday:
https://github.com/dotnet/corefx/blob/master/docs/Developers.md

Seems good for everybody (Paradox Team and external contributors), as we would work with the same signed assemblies.

We will give it a try!

@xen2 xen2 added this to the beta04 milestone Nov 13, 2014
@xen2 xen2 self-assigned this Nov 13, 2014
@gitfool
Copy link
Author

gitfool commented Nov 13, 2014

👍

@xen2
Copy link
Contributor

xen2 commented Nov 13, 2014

Looks like it's working, so it should be in next beta!

@xen2 xen2 added the fixed label Nov 21, 2014
@xen2
Copy link
Contributor

xen2 commented Nov 25, 2014

New Paradox beta04 as published on GitHub now has open-source signing!

@xen2 xen2 closed this as completed Nov 25, 2014
xenux pushed a commit that referenced this issue Oct 9, 2015
* commit '29be7b576c162a52187d7e470e3ceeb3fa8e3603':
  [Graphics] Delete the separate alpha effect as it is not used anymore.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

2 participants