🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

How to start porting the game to the Win Store?

Started by
1 comment, last by Steven Ford 3 years, 5 months ago

There is a sample from 2015 for Studio 2015, c++. I am trying to move this up to the modern era myself! Not having done it before, submit a Windows 10 Store App…how can one be sure? It is the ‘XAML DirectX 3D shooting sample’.essay writer

It looks fairly straightforward. I have a DirectX12 free hand object drawer to submit as soon as it is done. So I am interested in this topic!

Advertisement

Hi @rileydylan ,

I guess there are 2 parts to this:

  1. Why do you want to do it? If you're targeting the XBox series and you're going for the creators collection or aiming for ID@Xbox then migrating to UWP makes sense.
  2. If you're planning on targeting the PC (as a game) and you're seeing it as the sole distribution mechanism, then I might be a little more hesitant in encouraging it. Visibility isn't great.

Note that I'm writing this as someone who is on the MS store for reason number 1 and stupidly didn't release my games on Steam etc. The focusing on the MS store solo was… naïve on my part.

The TLDR version is - it's actually rather easy, use the templates - DirectX game project templates - UWP applications | Microsoft Docs

Right, now that that's over. The technical stuff. I'm, assuming that you've got a Win32 game which you want to make available on UWP? if this is the case, then yes, definitely start with the tutorials. (We use VS2017 as we needed to add Xbox live integration - part of the requirements to get it released on the X1 and we couldn't find an updated nuget package containing the necessary code).

The big technical difference between UWP and Win32 (at least from our experience) is the requirement for the game to be suspended / resumed. So for us, we needed to update our code to handle these events (our Win32 caller just gets given it once and goes from there). From what I recall, our major change was to have something like this in the OnResuming() call in the template:

// Remove anything which references the previous DX device etc.
this->_resourceCache->removeEntries([](auto key, auto entry) {
	auto standardPointer = entry.get();
	if (dynamic_cast<Borsuk::Core::Graphics::DX::Texture*>(standardPointer) != nullptr ||
		dynamic_cast<Borsuk::Core::Graphics::DX::Shaders::PixelShader*>(standardPointer) != nullptr ||
		dynamic_cast<Borsuk::Core::Graphics::DX::Shaders::VertexShader*>(standardPointer) != nullptr ||
		dynamic_cast<Borsuk::Core::Graphics::DX::Graphics2D::IAnimation*>(standardPointer) != nullptr ||
		dynamic_cast<Borsuk::Core::Graphics::DX::Fonts::SpriteFontResourceEntry*>(standardPointer) != nullptr)
		return true;

	return false; });

and

_gameOrchestrator->updateDXVariables(device,
	deviceContext,
	renderTargetView,
	depthStencilView);

These basically mean that we push data back to the GPU. Whether it's actually needed or not, I'm not 100% sure.

This topic is closed to new replies.

Advertisement