Skip to content

Instantly share code, notes, and snippets.

@Yves-G
Yves-G / crashtest.cpp
Created June 12, 2016 21:16
Reproduces a crash related to SSBOs and binding in recent versions of the AMD graphics driver. Build instructions in a comment in the file.
/*
* Copyright © 2012-2013 Graham Sellers
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
@Yves-G
Yves-G / territory type translation differences
Created April 20, 2014 12:31
territory type translation differences
diff --git a/binaries/data/mods/public/simulation/components/BuildRestrictions.js b/binaries/data/mods/public/simulation/components/BuildRestrictions.js
index 8315082..8552b12 100644
--- a/binaries/data/mods/public/simulation/components/BuildRestrictions.js
+++ b/binaries/data/mods/public/simulation/components/BuildRestrictions.js
@@ -176,12 +176,16 @@ BuildRestrictions.prototype.CheckPlacement = function()
var territoryFail = true;
var territoryType = "";
if (isAlly && !this.HasTerritory("ally"))
+ // Translation: territoryType being displayed in a translated sentence in the form: "House cannot be built in %(territoryType)s territory.".
territoryType = markForTranslationWithContext("Territory type", "ally");
@Yves-G
Yves-G / locale detection and menu
Created April 19, 2014 08:33
patch implementing an advanced locale selection menu and improved automatic locale detection
diff --git a/binaries/data/mods/public/gui/locale/locale.js b/binaries/data/mods/public/gui/locale/locale.js
index 7e10cc3..2a6f02f 100644
--- a/binaries/data/mods/public/gui/locale/locale.js
+++ b/binaries/data/mods/public/gui/locale/locale.js
@@ -2,8 +2,18 @@ function init()
{
var languageList = Engine.GetGUIObjectByName("languageList");
languageList.list = Engine.GetSupportedLocaleDisplayNames();
- languageList.list_data = Engine.GetSupportedLocaleCodes();
- languageList.selected = Engine.GetCurrentLocaleIndex();