Warning: Use of undefined constant MIGRATION_WRITE_NEW - assumed 'MIGRATION_WRITE_NEW' (this will throw an Error in a future version of PHP) in /users/botf2/www/wiki/LocalSettings.php on line 152

Warning: session_name() [function.session-name]: Cannot change session name when headers already sent in /users/botf2/www/wiki/includes/Setup.php on line 522

Warning: Cannot modify header information - headers already sent by (output started at /users/botf2/www/wiki/LocalSettings.php:152) in /users/botf2/www/wiki/includes/Feed.php on line 230

Warning: Cannot modify header information - headers already sent by (output started at /users/botf2/www/wiki/LocalSettings.php:152) in /users/botf2/www/wiki/includes/WebResponse.php on line 38

Warning: Cannot modify header information - headers already sent by (output started at /users/botf2/www/wiki/LocalSettings.php:152) in /users/botf2/www/wiki/includes/WebResponse.php on line 38

Warning: Cannot modify header information - headers already sent by (output started at /users/botf2/www/wiki/LocalSettings.php:152) in /users/botf2/www/wiki/includes/WebResponse.php on line 38
http://botf2.square7.ch/wiki/api.php?action=feedcontributions&feedformat=atom&user=Reginald BotF2-Wiki - User contributions [en] 2026-04-17T18:51:09Z User contributions MediaWiki 1.22.2 http://botf2.square7.ch/wiki/index.php?title=System_Requirements System Requirements 2023-02-11T12:48:18Z <p>Reginald: </p> <hr /> <div><br /> <br /> &lt;span style=&quot;color:red&quot;&gt;Check your installed programs: just press Win-Key+R and input &quot;appwiz.cpl&quot; + ENTER.&lt;/span&gt;<br /> <br /> Check:<br /> *Microsoft .NET Framework 4.https://dotnet.microsoft.com/en-us/download/dotnet-framework - also update to latest Windows version<br /> *Microsoft Visual C++ 2008 Redistributable (1,7 MB) &lt;span style=&quot;color:red&quot;&gt;(needed !)&lt;/span&gt;<br /> *Microsoft Visual C++ 2010 Redistributable (5 MB) https://support.microsoft.com/de-de/help/2977003/the-latest-supported-visual-c-downloads<br /> *Microsoft XNA Framework (7 MB)<br /> <br /> <br /> The currently requirements are:<br /> <br /> *'''&lt;span style=&quot;color:red&quot;&gt;Microsoft .NET Framework 4.6.2 Extended ([http://en.wikipedia.org/wiki/.NET_Framework Wikipedia]) -&gt; manual installing is necessary -&gt;&lt;/span&gt;''' [http://botf2.square7.ch/wiki/index.php?title=Problem#check_your_.Net-Version Check and download here]<br /> <br /> <br /> Summary: any usual Windows PC<br /> *Intel Core Processor (not to old)<br /> *512mb RAM<br /> *[[Windows]] (tm): Windows XP up to Windows 8.1 (if you have problems, just see [[Problem#Windows problem]])<br /> *DirectX 9-compatible video card with Pixel Shader 2.0+ and Vertex Shader 1.1+ support<br /> *Desktop resolution of at least 1024x768 (1280x768 or higher is strongly recommended)<br /> *[[DirectX]] 9 or greater<br /> ----<br /> Due to other programs also use the next parts the game requires (e.g. Zone Alarm free: Microsoft .NET Redistributable, Microsoft VC++ Redistributable (x86) http://www.windowsuninstaller.org/forums/viewtopic.php?f=8&amp;t=743#p1158) some might be already installed on your PC. This might be the reason why some persons can ran Supremacy without great installing all the requirements, and others have to install all the stuff.<br /> ----<br /> &lt;span style=&quot;color:red&quot;&gt;Many reports are on missing XNA.&lt;/span&gt; Just mention this requirement:<br /> *Microsoft XNA Framework v3.1 Redistributable http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> Without it, the game isn't able to load the 3d models that you can see in the shipyard, resulting in crashes.<br /> <br /> ----<br /> <br /> If BotF2 still not runs then...<br /> <br /> Lloyd James wrote: To run BotF2, you need ALL of the following installed:<br /> *Microsoft .NET Framework ''4.5.1'' (note: you want the full framework, not the &quot;Client Profile&quot;; after it's installed, you should see both the &quot;Client Profile&quot; and &quot;Extended Profile&quot; listed in your control panel. Also note that the latest version of .Net is 4.5, and future game versions *might* need the more recent versions) http://www.microsoft.com/de-de/download/details.aspx?id=40779<br /> *Microsoft DirectX Runtime<br /> *Microsoft XNA Framework v3.1 Redistributable http://www.microsoft.com/en-us/download/details.aspx?id=15163, v4.0 might also work http://www.microsoft.com/en-us/download/details.aspx?id=20914<br /> *Microsoft Visual C++ 2008 Redistributable (1,7 MB) &lt;span style=&quot;color:red&quot;&gt;(needed !)&lt;/span&gt;<br /> *Microsoft Visual C++ 2010 Redistributable (5 MB)<br /> <br /> All of these can be found via Google. Simply copy-and-paste them and select the first link that appears.</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Category:Races Category:Races 2023-01-14T14:09:47Z <p>Reginald: </p> <hr /> <div>also or better called: &gt;&gt;[[Civilizations]]<br /> <br /> playable: [[Major]]s like [[Federation]] - [[Romulans]] - [[Klingons]] - [[Cardassians]] - [[Dominion]] - [[Borg]] - [[Terran Empire]]<br /> <br /> not playable: [[Minor]]s <br /> ----<br /> (you can check https://intl.startrek.com/database or at minor's Wiki-site there are links to [http://en.memory-alpha.org Memory Alpha])</div> Reginald http://botf2.square7.ch/wiki/index.php?title=%C2%BBRamatians »Ramatians 2022-11-13T11:08:55Z <p>Reginald: </p> <hr /> <div>{|class=&quot;wikitable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Race<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Image<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Insignia<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Type<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Planet<br /> <br /> |- <br /> |style=text-align:center|[http://en.memory-alpha.org/wiki/Ramatisian Ramatians]&lt;br&gt;&lt;br&gt;(indeed Ramatis III natives - unnamed species)<br /> |style=text-align:left bgcolor=&quot;black&quot;|&lt;img size=&quot;150&quot;&gt;http://botf2.square7.ch/wiki-files/images/Races/ramatians.png&lt;/img&gt;<br /> |style=text-align:left bgcolor=&quot;black&quot;|&lt;img size=&quot;100&quot;&gt;http://botf2.square7.ch/wiki-files/images/Insignias/ramatians.png&lt;/img&gt;<br /> |style=text-align:left|<br /> Many of the Ramatian people lack the gene that makes hearing possible. The ruling family have devised a method of communication involving a telepathic interpretative 'chorus' - a harmonious mental waveform that resonates with the different facets of personality, which they interpret as communicative thought patterns. Because of this skill they are able to delve deeply into the thought structures of almost any mind, perceiving thought, simplifying, amongst many cross-cultural and lingual boundaries, first contact negotiations, and mediation.<br /> <br /> |style=text-align:center|Terran<br /> |style=text-align:left bgcolor=&quot;black&quot;|&lt;img size=&quot;150&quot;&gt;http://botf2.square7.ch/wiki-files/images/Planets/no.png&lt;/img&gt;<br /> <br /> |}<br /> <br /> == Buildings ==<br /> {|class=&quot;wikitable&quot; width=&quot;100%&quot;<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Building<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Image<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Tech<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; width=&quot;50%&quot;|Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> |- <br /> |style=text-align:center|RAMATIAN_HALL_OF_MEDIATORS<br /> <br /> |style=text-align:center bgcolor=&quot;black&quot;|&lt;img size=&quot;150&quot;&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/ramatian_hall_of_mediators.png&lt;/img&gt; <br /> |style=text-align:center| <br /> |style=text-align:left| <br /> In these halls, experts in diplomacy, translation and thought melds bring disparate minds together in conciliation and understanding. The mediators are the most skilled and gifted individuals in their field.<br /> <br /> |style=text-align:left| <br /> http://botf2.square7.ch/b2_db/Buildings.php <br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> <br /> [[Category:Races]] [[Category:Building]] [[Category:Ships]]</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Galaxy_Panel Galaxy Panel 2022-09-24T13:47:52Z <p>Reginald: /* Other Maps */</p> <hr /> <div>== Intro ==<br /> [[category:GUI]]<br /> <br /> *&gt;&gt; see also [[Manual#Galaxy Panel]]<br /> <br /> <br /> &lt;img size=957&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/1---Galaxy/1---GalaxyPanel_Described.jpg&lt;/img&gt;<br /> <br /> <br /> == Territory ==<br /> <br /> *https://bitbucket.org/mstrobel/supremacy/issue/317/disputed-territory (issue/317)<br /> <br /> == Other Maps ==<br /> <br /> * Coordinates https://memory-alpha.fandom.com/wiki/Coordinates<br /> <br /> * https://memory-alpha.fandom.com/wiki/Map:The_explored_galaxy<br /> <br /> * https://sp1np0rtal.github.io/stfc-galaxy-map/</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Galaxy_Panel Galaxy Panel 2022-09-17T12:22:18Z <p>Reginald: /* Other Maps */</p> <hr /> <div>== Intro ==<br /> [[category:GUI]]<br /> <br /> *&gt;&gt; see also [[Manual#Galaxy Panel]]<br /> <br /> <br /> &lt;img size=957&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/1---Galaxy/1---GalaxyPanel_Described.jpg&lt;/img&gt;<br /> <br /> <br /> == Territory ==<br /> <br /> *https://bitbucket.org/mstrobel/supremacy/issue/317/disputed-territory (issue/317)<br /> <br /> == Other Maps ==<br /> <br /> * https://memory-alpha.fandom.com/wiki/Map:The_explored_galaxy<br /> <br /> * https://sp1np0rtal.github.io/stfc-galaxy-map/</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Galaxy_Panel Galaxy Panel 2022-09-17T11:58:10Z <p>Reginald: </p> <hr /> <div>== Intro ==<br /> [[category:GUI]]<br /> <br /> *&gt;&gt; see also [[Manual#Galaxy Panel]]<br /> <br /> <br /> &lt;img size=957&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/1---Galaxy/1---GalaxyPanel_Described.jpg&lt;/img&gt;<br /> <br /> <br /> == Territory ==<br /> <br /> *https://bitbucket.org/mstrobel/supremacy/issue/317/disputed-territory (issue/317)<br /> <br /> == Other Maps ==<br /> <br /> * https://sp1np0rtal.github.io/stfc-galaxy-map/</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Model Model 2022-05-07T07:45:23Z <p>Reginald: </p> <hr /> <div>\Resources\Models are used for display at Ship Building, '''but at the moment only a few models are available (e.g. Federation Colony Ship I)'''.<br /> <br /> &gt;&gt; http://botf2.square7.ch/wiki-files/Models/Models.zip<br /> <br /> <br /> If no model is done it is shown: NO MODEL AVAILABLE. For having a look to the ship just go to [[Encyclopedia]].<br /> <br /> <br /> *Microsoft XNA Game Studio 4.0 (free, needs Visual Studio 2010) http://www.microsoft.com/en-us/download/confirmation.aspx?id=23714<br /> <br /> <br /> For having a look to the models you can install [http://gruaz.net/?page_id=407 GameTools], direct download [http://teapot-studio.com/products/gametools/gametools_setup.exe here]. <br /> In addition it will install XNA which also may solve some problems.<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/GameToolsSetup.png&lt;/img&gt;<br /> <br /> <br /> == XNB ==<br /> <br /> *http://pcsupport.about.com/od/fileextensions/f/xnbfile.htm</div> Reginald http://botf2.square7.ch/wiki/index.php?title=3D_Model 3D Model 2022-03-05T13:50:39Z <p>Reginald: /* Intro */</p> <hr /> <div>[[Category:3D Combat Engine]]<br /> = Intro =<br /> <br /> = How to bring in =</div> Reginald http://botf2.square7.ch/wiki/index.php?title=3D_Model 3D Model 2022-03-05T13:50:16Z <p>Reginald: Created page with &quot;Category:3D Combat Engine = Intro =&quot;</p> <hr /> <div>[[Category:3D Combat Engine]]<br /> = Intro =</div> Reginald http://botf2.square7.ch/wiki/index.php?title=MediaWiki:Sidebar MediaWiki:Sidebar 2022-03-05T13:49:34Z <p>Reginald: </p> <hr /> <div>* SEARCH<br /> * navigation<br /> ** mainpage|Home<br /> ** http://botf2.square7.ch/homepage/|Download via HP<br /> ** http://star-trek-supremacy.proboards.com/ |Forum BotF2<br /> ** https://www.facebook.com/groups/29948496855/ |Facebook<br /> ** http://www.botf2.star-trek-games.com/|ForumSTGames(gone)<br /> ** Screenshots|(some) Screenshots<br /> ** Videos|Videos<br /> ** http://botf2.square7.ch/wiki/index.php?title=Manual|Manual<br /> ** http://botf2.square7.ch/homepage/|Homepage<br /> ** http://botf2.square7.ch/|Database<br /> ** System Requirements|System Requirements<br /> ** http://doodle.com/itssissaig7rq4at|Doodle<br /> ** Source Code#Source Code|Bitbucket<br /> ** http://botf2.square7.ch/wiki/index.php?title=Special:AllPages&amp;from=AI&amp;to=~All_Pages |A-Z (without races)<br /> ** special:categories|Categories<br /> *** Category:GUI|- GUI<br /> *** Category:How to play|- How to play<br /> *** Category:Races|- Races<br /> *** Category:Ships|- Ships<br /> *** Category:Images|- Images<br /> *** Category:Screenshots|- Screenshots<br /> *** Category:3D Combat Engine|- 3D Combat Engine<br /> ****Blender|--- Blender<br /> ****Unity|--- Unity<br /> ****3D Model|--- 3D Model<br /> ** recentchanges-url|recentchanges<br /> * TOOLBOX<br /> * LANGUAGES<br /> * OTHERS<br /> ** Special:WantedPages|Wanted Pages<br /> ** to do list (Wiki)|to do list</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Borg Borg 2021-09-26T06:20:06Z <p>Reginald: </p> <hr /> <div>__NOTOC__<br /> <br /> == &lt;span style=&quot;color:green&quot;&gt; Borg ==<br /> <br /> in 2016 we hope to make Borg playable as a major/empire race. If so, indeed there are some differences to the other empires in game mechanics:<br /> *Borg doesn't have colony ships. To own a sector just build a station in that sector (instead of colonizing). <br /> *if a colony is inhabitant you can assimilate it by assaulting the system. Don't forget to use transport ships, transporting borg drones for assimilation. Without that you will just bombard the colony. <br /> <br /> Than minor race &quot;[[»Borg|Borg]]&quot; is thrown out of the game.<br /> <br /> {| width=&quot;80%&quot; bgcolor=&quot;lightgreen&quot; style=&quot;border:2px solid #7d85e6;padding:1em;padding-top:0.5em;&quot;<br /> <br /> |valign=&quot;center&quot; align=&quot;center&quot; | &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Civilizations/borgcollective.png&lt;/img&gt;<br /> <br /> | width=&quot;1%&quot; bgcolor=&quot;#b3b8f4&quot; | <br /> <br /> | bgcolor=&quot;#fafafa&quot; width=&quot;90%&quot; - valign=&quot;top&quot;| <br /> &quot;We are the Borg. You will be assimilated. Resistance is futile.&quot;<br /> <br /> The Borg are/were a pseudo-species of cybernetic beings, or cyborgs, from the Delta Quadrant. No single individual truly existed within the Borg Collective (with the possible sole exception of the Borg Queen), as all Borg were linked into a hive mind. Their ultimate goal was the attainment of 'perfection' through the forcible assimilation of diverse sentient species, technologies, and knowledge. As a result, the Borg were among the most powerful and feared entities in the galaxy, without really being a true species at all.<br /> The precise origins of the Borg are unclear. As of 1484 AD, they were reported as controlling only a handful of systems in the Delta Quadrant, but by 2373, they had assimilated thousands of worlds. In addition to this stronghold in the Delta Quadrant, the Borg also dispatched vessels throughout the galaxy via transwarp conduits.<br /> The Borg Collective population is at the very least made up several trillion humanoid and non-humanoid species referred to as drones. Through the use of their cybernetic implants, the Borg interacted by sharing one another's thoughts in a hive mind. Upon assimilation, these trillions of &quot;voices&quot; would overwhelm the drone, stifling individual thought and resistance to the Collective's will. To some drones these voices could eventually become a source of comfort, and their absence a source of pain.<br /> <br /> Borg philosophy was governed by a primary directive to add the biological and technological distinctiveness of other species to that of the Borg. In this manner the Collective sought to achieve its definition of perfection; all other pursuits were deemed irrelevant. Accordingly, Borg drones did not engage in any activities except their duties and regeneration. Individual drones have demonstrated puzzlement at other species' unwillingness to be assimilated, the drones believing in the superiority of their way of life.<br /> <br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/1---Galaxy/Systems/BorgCollective.png&lt;/img&gt;<br /> <br /> |-<br /> |bgcolor=&quot;lightgreen&quot; align=&quot;middle&quot; | &lt;img size=120&gt;http://botf2.square7.ch/wiki-files/images/Insignias/BORGCOLLECTIVE.png&lt;/img&gt;<br /> | <br /> | bgcolor=&quot;#fafafa&quot; | <br /> <br /> *Civilization Key=&quot;BORG&quot;<br /> <br /> *Race: '''BORGCOLLECTIVE'''<br /> *ShortName: '''Borg'''<br /> *LongName: '''Borg Collective'''<br /> <br /> <br /> *HomeSystem: '''borg collective''' <br /> <br /> *Color: '''Blue'''<br /> *HomeQuadrant: '''Alpha'''<br /> *CivilizationType: '''Empire'''<br /> *TechCurve: '''TechCurve6'''<br /> <br /> |-<br /> |bgcolor=&quot;lightgreen&quot; align=&quot;middle&quot; | &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/ProductionFacilities/borg_alcove.png&lt;/img&gt;&lt;br&gt;<br /> <br /> &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/ProductionFacilities/borg_nanobot_factory_SMALL.png&lt;/img&gt;&lt;br&gt;<br /> <br /> &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/ProductionFacilities/borg_process_node_SMALL.png&lt;/img&gt;&lt;br&gt;<br /> | <br /> | bgcolor=&quot;#fafafa&quot; | <br /> <br /> <br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/2-2-System-Structures/2-2-System-Borg-SomeStructures.jpg&lt;/img&gt;<br /> |}<br /> <br /> == Ships ==<br /> <br /> see &gt;&gt; [[»Borg|Borg]]<br /> <br /> *http://memory-alpha.wikia.com/wiki/Borg_starships<br /> <br /> == Playing Borg ==<br /> <br /> Playing Borg is hard balanced between being a hostile race and having some disadvantages. <br /> <br /> *Borg don't have colony ships so build transport ships and assault foreign systems. Don't forget to declare war before to that race using [[Embassy]] screen.<br /> *Borg ships are quite strong in ship-to-ship-combat (advantage)<br /> *[[Moon Habitation]] (or in real building Complexes) is a strong advantage getting a lot of borg drones. Hopefully your starting system &quot;borg nebula&quot; has one or more moons as well. <br /> *<br /> <br /> === Starting Tech Level EARLY ===<br /> <br /> *for ship building you need to build some energy reactors first and save energy as far as you can (turn off Shield Generator)<br /> <br /> === Starting Tech Level SUPREME ===<br /> <br /> <br /> <br /> [[Category:Races]]</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Cardassians Cardassians 2021-09-26T06:14:24Z <p>Reginald: /* Cardassian Union */</p> <hr /> <div>== &lt;span style=&quot;color:DarkGoldenrod&quot;&gt;Cardassian Union ==<br /> {| width=&quot;80%&quot; bgcolor=&quot;grey&quot; style=&quot;border:2px solid DarkGoldenrod;padding:1em;padding-top:0.5em;&quot;<br /> <br /> |valign=&quot;top&quot; align=&quot;center&quot; | &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Civilizations/cardassians.png&lt;/img&gt;<br /> <br /> | width=&quot;1%&quot; | <br /> <br /> | bgcolor=&quot;#fafafa&quot; width=&quot;90%&quot; - valign=&quot;top&quot;| <br /> The Cardassians use any means necessary to ensure the absolute loyalty of their subjects. A national indoctrination, mixed with effective control methods, promotes an unconditional belief in the Cardassian systems and work ethics, which results in exceptional industrial and mining capacity. These state-promoted plants clearly work far more effectively than their food and energy installations however, and their research advances at a slow rate. Their intelligence services, the Obsidian Order, are also very efficient, and are considered to be as dangerous as their military, both in the acts of espionage and sabotage. Cardassian ships continue the principle of community-controlled actions in space. Individually not very efficient, they are developed to attack in tight formations.<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/1---Galaxy/Systems/Cardassia.png&lt;/img&gt;<br /> <br /> |-<br /> | align=&quot;middle&quot; | &lt;img size=120&gt;http://botf2.square7.ch/wiki-files/images/Insignias/cardassians.png&lt;/img&gt;<br /> | <br /> | bgcolor=&quot;#fafafa&quot; |<br /> *Race: '''CARDASSIANS'''<br /> *ShortName: '''Cardassians'''<br /> *LongName: '''Cardassian Union'''<br /> <br /> <br /> *HomeSystem: '''Cardassia''' (pop: 305, growth: 3,6%): (3) Cardassia Prime<br /> *Color: '''DarkGoldenrod'''<br /> *HomeQuadrant: '''Alpha'''<br /> *CivilizationType: '''Empire'''<br /> *TechCurve: '''TechCurve6'''<br /> <br /> |-<br /> | align=&quot;middle&quot; | &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/card_detapa_council.png&lt;/img&gt;&lt;br&gt;Detapa Council<br /> <br /> &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/card_the_obsidian_order.png&lt;/img&gt;&lt;br&gt;The Obsidian Order<br /> <br /> &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/card_forced_labour_farms.png&lt;/img&gt;&lt;br&gt;Forced-Labour Farms<br /> | <br /> | bgcolor=&quot;#fafafa&quot; |<br /> &quot;The Cardassians are a humanoid species from the Alpha Quadrant. They are native to the planet Cardassia Prime, capital world of the Cardassian Union, and are ruled by an oppressive military dictatorship. However, in its ancient history, before Cardassia was ruled by the military, the Cardassian people were known as the Hebitians, a society known for their fine art and beautiful architecture. But the Hebitian civilization was wasteful, and fell into decay from a chronic lack of natural resources; millions of Hebitians starved to death. The planet was subjected to decades of utter anarchy, eventually resulting in the extinction of Hebitian society.<br /> <br /> In a last attempt at survival, the few remaining Hebitians turned to the military to solve their problems, who quickly developed efficient new spacefaring technologies to allow resources to be acquired from distant planets and systems. Renaming themselves the Cardassian Union, the Cardassians quickly came to be a military power in their own right, brutally, but efficiently, subjugating entire systems in their unquenchable thirst for natural resources.<br /> <br /> To this day, the Cardassians are ruled by an oppressive military government where efficiency and absolute loyalty are the only things that matter.&quot;<br /> <br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/2-2-System-Structures/2-2-System-Cardassia-SomeStructures.jpg&lt;/img&gt;<br /> |}<br /> <br /> [[Category:Races]]</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Klingons Klingons 2021-09-26T06:13:51Z <p>Reginald: /* Klingon Empire */</p> <hr /> <div>== &lt;span style=&quot;color:Crimson&quot;&gt;Klingon Empire ==<br /> {| width=&quot;80%&quot; bgcolor=&quot;Crimson&quot; style=&quot;border:2px solid red;padding:1em;padding-top:0.5em;&quot;<br /> <br /> |valign=&quot;top&quot; align=&quot;center&quot; | &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Civilizations/klingons.png&lt;/img&gt;<br /> <br /> | width=&quot;1%&quot; | <br /> <br /> | bgcolor=&quot;#fafafa&quot; width=&quot;90%&quot; - valign=&quot;top&quot;| <br /> The Klingons are some of the most feared warriors in the galaxy. Their quest for glory and honour in battle makes them masters in the field of combat; be it in ground or space-based combat, their weapons arm quickly and strike hard. Some of their battleships possess cloaking devices, with which the Klingons strike from the shadows at their prey. Their vigorous industrial forges process countless masses of raw materials, keeping their resource-hungry war machine running, whilst gigantic hunting parties guarantee the population's food supply. However, all things that do not directly serve battle are of lower importance to them and thus are less effective. The Klingons consider espionage a cowardly and dishonourable act, but are willing to defend themselves through internal security as necessary.<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/1---Galaxy/Systems/QonoS.png&lt;/img&gt;<br /> <br /> |-<br /> | align=&quot;middle&quot; | &lt;img size=120&gt;http://botf2.square7.ch/wiki-files/images/Insignias/klingons.png&lt;/img&gt;<br /> | <br /> | bgcolor=&quot;#fafafa&quot; | <br /> *Race: '''KLINGONS'''<br /> *ShortName: '''Klingons'''<br /> *LongName: '''Klingon Empire'''<br /> <br /> <br /> *HomeSystem: '''Qo'noS''' (pop: 305, growth: 3,5%)<br /> *Color: '''Crimson'''<br /> *HomeQuadrant: '''Beta'''<br /> *CivilizationType: '''Empire'''<br /> *TechCurve: '''TechCurve6'''<br /> <br /> |-<br /> | align=&quot;middle&quot; | &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/kling_great_hall.png&lt;/img&gt;&lt;br&gt;Great Hall<br /> <br /> &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/kling_hall_of_warriors.png&lt;/img&gt;&lt;br&gt;Hall of Warriors<br /> | <br /> | bgcolor=&quot;#fafafa&quot; | <br /> The Klingons (Klingonese: tlhIngan) are a humanoid warrior species that originates from the jungle planet Qo'noS (pronounced Kronos). One of the major powers of the galaxy, the Klingons are a proud, tradition-bound people who value honour and combat. The aggressive Klingon culture has made them an interstellar military power that is to be respected and feared. Klingons believe that they have the instinctive ability to look an opponent in the eye and see the intent to kill. Those that have such intent rarely get the chance to do so - unless they are another Klingon.<br /> <br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/2-2-System-Structures/2-2-System-QonoS-SomeStructures.jpg&lt;/img&gt;<br /> |}<br /> <br /> <br /> <br /> Not part of BotF2:<br /> *Klingon War Song http://www.youtube.com/watch?v=WBZ2MEBTYJs<br /> *Klingon Drinking Song http://www.youtube.com/watch?v=cTuD6xf-ync<br /> <br /> [[Category:Races]]</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Romulans Romulans 2021-09-26T06:13:07Z <p>Reginald: </p> <hr /> <div>== &lt;span style=&quot;color:green&quot;&gt;Romulan Star Empire ==<br /> {| width=&quot;90%&quot; bgcolor=&quot;#efffec&quot; style=&quot;border:2px solid green;padding:1em;padding-top:0.5em;&quot;<br /> <br /> |valign=&quot;top&quot; align=&quot;center&quot; valign=&quot;center&quot; | &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/Civilizations/romulans.png&lt;/img&gt;<br /> <br /> | width=&quot;1%&quot; | <br /> <br /> | bgcolor=&quot;#fafafa&quot; width=&quot;80%&quot; - valign=&quot;top&quot;| <br /> To outsiders, the Romulans are an enigmatic race. To the Romulans, however, other races have hardly any mystery left, for their talented intelligence agency, the Tal Shiar, has solved each of those mysteries. Romulan interests are protected by a veil of secrecy and covertness, just as their ships are hidden from prying eyes by powerful cloaking technologies. Their ships move undetected in groups until they are close to their unsuspecting victim, before decloaking and destroying their target in the ambush. Reports on Romulan society show it functions on exceptional research achievements; their industry and mining efforts are not quite as effective, however. The basic supply of energy and food for the populace is sufficient to meet day-to-day needs, and is rigorously regulated to be resource-saving, as are their fleet maintenance costs; Romulan fleets expect to decimate the enemy before they have any chance at mounting a defence. There is therefore little need to equip their vessels with expensive armour plating. This should not be seen as a weakness however; Romulan ships are known equally for their manoeuverability and heavy weapons, and for their ability to disappear at will.<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/1---Galaxy/Systems/Romulus.png&lt;/img&gt;<br /> ----<br /> |-<br /> | align=&quot;middle&quot; | &lt;img size=120&gt;http://botf2.square7.ch/wiki-files/images/Insignias/romulans.png&lt;/img&gt;&lt;br&gt;&lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/rom_imperial_senate.png&lt;/img&gt;&lt;br&gt;Imperial Senate<br /> | <br /> | bgcolor=&quot;#fafafa&quot; | <br /> *Race: '''ROMULANS'''<br /> *ShortName: '''Romulans'''<br /> *LongName: '''Romulan Star Empire'''<br /> <br /> <br /> *HomeSystem: '''Romulus (pop: 355, growth: 4%)'''<br /> **(1) Romulus I: volcanic (hostile), small (25 pop.)<br /> **(2) Romulus Prime: terran (ideal), large (180 pop.)<br /> **(3) Remus: desert (marginal), large (60 pop.)<br /> **(4) Romulus IV: oceanic (comfortable), medium (90 pop.)<br /> **(5) Romulus V: Asteroids (uninhabitable), (no pop.)<br /> **(6) Romulus VI: GasGiant (uninhabitable), (no pop.)<br /> <br /> <br /> *Color: '''Green'''<br /> *HomeQuadrant: '''Beta'''<br /> *CivilizationType: '''Empire'''<br /> *TechCurve: '''TechCurve6'''<br /> ----<br /> |-<br /> | align=&quot;middle&quot; | &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/rom_tal_shiar_headquarters.png&lt;/img&gt;&lt;br&gt;Tal Shiar Headquarters<br /> <br /> &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/rom_naval_academy.png&lt;/img&gt;&lt;br&gt;Naval Academy<br /> <br /> &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/rom_imperial_affairs_network.png&lt;/img&gt;&lt;br&gt;Imperial Affairs Network<br /> | <br /> | bgcolor=&quot;#fafafa&quot; | <br /> &quot;The Romulans are a Beta Quadrant race from the planet Romulus, but are biological cousins of the Vulcans, as they are descended from those who rejected Surak's reforms during the Vulcan Time of Awakening approximately sixteen hundred years ago. The Romulan Star Empire is the Romulan state, and is one of the major powers in known space.<br /> <br /> Some theorize that the Vulcans - and therefore also the Romulans - are descended from Sargon's people, a race who possibly colonized the planet Vulcan some six million years ago. This theory, however, was later contradicted by the discovery of ancient humanoid progenitor remains on Vulcan.<br /> <br /> When Surak's reforms of embracing logical principles and rejecting emotion spread rapidly across Vulcan in the 4th century, a minority rejected Surak's ideals; they chose to depart Vulcan rather than accept his teachings. Some of the descendents of these exiles are known to have established settlements on the planets Calder II, Dessica II, Draken IV, Yadalla Prime and Barradas III. These planets later formed the core worlds of the Debrune Empire, but infighting and lack of resources quickly took their toll, and the fledgling Debrune Empire collapsed.<br /> <br /> At some point, another group settled on the twin planets that came to be known as Romulus and Remus. Whilst both planets were habitable Minshara-class planets, Romulus was stable and inviting, but Remus was tilted on an unusual axis that resulted in half of the planet being bathed in perpetual sunlight, whilst the other was shrouded in perpetual darkness. The only truly habitable zone of the planet was found near the boundary between night and day, and even in this region, conditions are harsh. But the Romulans encountered the native Reman race in this habitable zone, and quickly learned to exploit the Reman people as slaves and fearsome ground troops. The later discovery of abundant dilithium deposits on Remus eventually allowed the Romulans to develop interstellar capabilities, and solidified the union of the twin worlds. This union eventually became the foundation of an interstellar Empire that has since expanded to many worlds, reaching across much of the Beta Quadrant. That power eventually came to be known as the Romulan Star Empire.&quot;<br /> <br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/2-2-System-Structures/2-2-System-Romulus-SomeStructures.jpg&lt;/img&gt;<br /> <br /> |}<br /> <br /> [[Category:Races]]<br /> <br /> *Additions: '''Consider adding Shock Troop Center'''<br /> <br /> For the Shock Troop Centre I've been reading the various wiki sites on Remens and have taken the best bits to make this up. Hopefully it does the job or at least gives you guys what you need to write something cooler! :) <br /> The Shock Troop Centre trains Reman slaves to become excellent warriors so that they can be exploited by Romulan commanders. During war time these warriors are used as &quot;cannon fodder&quot; by the Romulan military and placed in the fiercest engagements. Their skills in combat and their imposing nature also allows them to be used a personal bodyguards for the Romulan elite.</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Federation Federation 2021-09-26T06:10:50Z <p>Reginald: /* United Federation of Planets */</p> <hr /> <div>== &lt;span style=&quot;color:#0000ff&quot;&gt; United Federation of Planets ==<br /> {| width=&quot;80%&quot; bgcolor=&quot;#b3b8f4&quot; style=&quot;border:2px solid #7d85e6;padding:1em;padding-top:0.5em;&quot;<br /> <br /> |valign=&quot;center&quot; align=&quot;center&quot; | &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Civilizations/federation.png&lt;/img&gt;<br /> <br /> | width=&quot;1%&quot; bgcolor=&quot;#b3b8f4&quot; | <br /> <br /> | bgcolor=&quot;#fafafa&quot; width=&quot;90%&quot; - valign=&quot;top&quot;| <br /> The United Federation of Planets is a coalition of worlds bound by a mutual desire for peace, the pursuit of scientific understanding, and trade. By far however, the most numerous of the Federation races is one of the founding members, the Humans of Sol. The people of the Federation live in a society based on the values of liberty and equality. Their strength lies in extremely effective research, which grants them fast access to new technologies. They are also efficient in industry, the mining of raw materials, and the production and supply of energy and vital goods to their planets. Their high-quality products come at the expense of high resource costs, however. Because of their moral convictions, they quickly show weaknesses in the field of espionage, but they make up for this with impressive, well-rounded starships, which function as well individually as in groups. Federation starships are equally likely to be seen conducting trade, exploration, humanitarian, and diplomatic missions, as they are to be seen conducting military patrols and combat manoeuvres.<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/1---Galaxy/Systems/Sol.png&lt;/img&gt;<br /> <br /> |-<br /> |bgcolor=&quot;#b3b8f4&quot; align=&quot;middle&quot; | &lt;img size=120&gt;http://botf2.square7.ch/wiki-files/images/Insignias/federation.png&lt;/img&gt;<br /> | <br /> | bgcolor=&quot;#fafafa&quot; | <br /> *Race: '''HUMANS'''<br /> *ShortName: '''Federation'''<br /> *LongName: '''United Federation of Planets'''<br /> <br /> <br /> *HomeSystem: '''Sol''' (pop: 300, growth: 3,5%): Mercury, Venus, Earth, Mars, Asteroids, Jupiter, Saturn, Uranus, Neptune, Pluto <br /> <br /> *Color: '''Blue'''<br /> *HomeQuadrant: '''Alpha'''<br /> *CivilizationType: '''Empire'''<br /> *TechCurve: '''TechCurve6'''<br /> <br /> |-<br /> |bgcolor=&quot;#b3b8f4&quot; align=&quot;middle&quot; | &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/fed_federation_council.png&lt;/img&gt;&lt;br&gt;Federation Council<br /> <br /> &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/fed_starfleet_academy.png&lt;/img&gt;&lt;br&gt;Starfleet Academy<br /> <br /> &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Buildings/fed_private_farms.png&lt;/img&gt;&lt;br&gt;Private Farms<br /> | <br /> | bgcolor=&quot;#fafafa&quot; | <br /> &quot;A founding member of the United Federation of Planets, the Humans of Earth became warp-capable in 2063, only moments before they officially experienced first contact with an alien species, the Vulcans, who by pure coincidence happened to have sent a survey vessel to explore the Sol system at the same time as Humanity's first warp flight. The Humans were still recovering from their third world war that had taken place a decade earlier - a nuclear war that had destroyed all centres of power, and wiped out two-thirds of the planetary population - and desperately welcomed the Vulcans with open arms. First contact had a profound effect on the Humans, and in just 10 years Earth began to stand on its own two feet again, and, under the careful guidance of the Vulcans, the Humans turned their attention to science and peaceful exploration amongst the stars.<br /> <br /> By the 24th century, Human society had changed from what it was for most of recorded history. On Earth, hunger, war, disease, famine, and poverty had largely been eliminated. The acquisition of wealth was no longer the primary driving force in the lives of many Humans, and a great deal of emphasis was instead placed on the importance of continued societal and self-growth. Thanks to the non-currency based New World Economy and the development of replicators, material needs had been largely satisfied. Although money was no longer in use by Humans within the Federation, they did use gold-pressed Latinum and other forms of currency (such as Bajoran litas and credits) in places where it is still needed, such as Quark's Bar on the Deep Space Nine station. The idea behind not using money is that Humans work to better themselves and the rest of Humanity. It must however be noted that all of this more specifically applies to Humans within the Sol system, as many Earth colonies are known to have developed vast cultural differences from other Humans and some have even fallen into anarchy, most notably Turkana IV.<br /> <br /> Whilst warp capability and first contact were first achieved in 2063, there were human populations on other planets prior to this date. In these cases, the Humans were usually brought there by alien species that had travelled to Earth. For instance, Native Americans are known to have been transplanted to Amerind by an unknown alien race called the Preservers some time in the 19th century. In 2268, these transplanted Humans still lived as hunter-gatherers, and Captain James T. Kirk was adopted into one of the tribes of Amerind, becoming known as the god, Kirok.<br /> <br /> The Humans are a rapidly advancing race, with an unquenchable thirst for knowledge. Whilst they are now peaceful, they will fight to the death if need be to ensure the survival of their culture, ideals, and people. Only time will tell exactly how far the Humans will go.&quot;<br /> <br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/2-2-System-Structures/2-2-System-Sol-SomeStructures.jpg&lt;/img&gt;<br /> |}<br /> <br /> [[Category:Races]]</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Terran_Empire Terran Empire 2021-09-25T11:23:32Z <p>Reginald: /* Terran Empire */</p> <hr /> <div>== &lt;span style=&quot;color:#0000ff&quot;&gt; Terran Empire ==<br /> {| width=&quot;80%&quot; bgcolor=&quot;#b3b8f4&quot; style=&quot;border:2px solid #7d85e6;padding:1em;padding-top:0.5em;&quot;<br /> <br /> |valign=&quot;center&quot; align=&quot;center&quot; | &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Civilizations/terranempire.png&lt;/img&gt;<br /> <br /> | width=&quot;1%&quot; bgcolor=&quot;#b3b8f4&quot; | <br /> <br /> | bgcolor=&quot;#fafafa&quot; width=&quot;90%&quot; - valign=&quot;top&quot;| <br /> Form a Alternate Timeline where the Federation was never founded. The terran empire is one of conquest and will kill or enslave you if you do not bend to there will.<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/1---Galaxy/Systems/Sol.png&lt;/img&gt;<br /> <br /> |-<br /> |bgcolor=&quot;#b3b8f4&quot; align=&quot;middle&quot; | &lt;img size=120&gt;http://botf2.square7.ch/wiki-files/images/Insignias/TERRANEMPIRE.png&lt;/img&gt;<br /> | <br /> | bgcolor=&quot;#fafafa&quot; | <br /> *Race: '''TERRANS'''<br /> *ShortName: '''Terran Empire'''<br /> *LongName: '''Terran Empire'''<br /> <br /> <br /> *HomeSystem: '''Sol''' (pop: 300, growth: 3,5%): Mercury, Venus, Earth, Mars, Asteroids, Jupiter, Saturn, Uranus, Neptune, Pluto <br /> <br /> *Color: '''Yellow'''<br /> *HomeQuadrant: '''Alpha'''<br /> *CivilizationType: '''Empire'''<br /> *TechCurve: '''TechCurve6'''<br /> <br /> |-<br /> |bgcolor=&quot;#b3b8f4&quot; align=&quot;middle&quot; | <br /> <br /> &lt;img size=275&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Ships/terran_cruiser_i.png&lt;/img&gt;&lt;br&gt;Terran Cruiser<br /> <br /> <br /> | <br /> | bgcolor=&quot;#fafafa&quot; | <br /> <br /> <br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/2-2-System-Structures/2-2-System-Sol-SomeStructures.jpg&lt;/img&gt;<br /> |}<br /> <br /> [[Category:Races]]</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Sound Sound 2021-08-29T11:00:56Z <p>Reginald: /* Files */</p> <hr /> <div>= Intro =<br /> <br /> *Folder: \SoundFX<br /> *Folder racespecific: \UI\subfolder e.g. \UI\Dominion\ContextMenu\mousesnd.wav (not sure if it works)<br /> <br /> On some parts only WAV works, e.g. while starting the game. After the Game is started other files like OGG / FLAC / MP3 are working in general. But always try it !<br /> <br /> *[http://botf2.square7.ch/wiki-files/SoundFX/ChatMessage.wav ChatMessage.wav]<br /> *RedAlert.wav<br /> *NewTurn.wav<br /> <br /> *\SoundFX\[[Menue|Menu]] (working)<br /> *\SoundFX\[[System Assault#GroundCombat|GroundCombat]] (working)<br /> *\SoundFX\[[Scripted Event|ScriptedEvents]] (working)<br /> *\SoundFX\[[TaskForceOrder]]s (disabled, because Game freeze quite often)<br /> <br /> <br /> <br /> Missing sound files are shown in Log.txt<br /> <br /> == FMOD ==<br /> <br /> *http://star-trek-supremacy.proboards.com/post/5322/thread<br /> <br /> [[category:Audio]]<br /> == Files ==<br /> <br /> === MP3 ===<br /> <br /> *e.g. \Resources\Music\Trek Opening.mp3<br /> <br /> === OGG ===<br /> <br /> *e.g. \Resources\Music\Dominion System.ogg<br /> <br /> === FLAC ===<br /> <br /> *e.g. \Resources\SoundFX\TaskForceOrders\BorgWeAreTheBorg.flac<br /> <br /> === WAV ===<br /> <br /> *\Resources\SoundFX\NewTurn.wav<br /> <br /> === WMA ===<br /> <br /> *e.g. \Resources\SoundFX\ScriptedEvents\ReligiousHoliday.wma<br /> <br /> == Star Trek Sounds ==<br /> <br /> * https://www.trekcore.com/audio/</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2021-05-09T12:32:11Z <p>Reginald: /* Improvement */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> * see hints for VS 2017 especially &gt;&gt; Set as Start Project &gt; SupremacyClient (View SolutionExplorer &gt; SupremacyClient &gt; right mouse click ...in the middle)<br /> <br /> ==== Improvement ====<br /> <br /> <br /> old: var handler = TurnNumberChanged;<br /> if (handler != null)<br /> handler(this, EventArgs.Empty);<br /> New: TurnNumberChanged?.Invoke(this, EventArgs.Empty);<br /> <br /> old: if (baseScheduler == null)<br /> throw new ArgumentNullException(&quot;baseScheduler&quot;);<br /> new: _baseScheduler = baseScheduler ?? throw new ArgumentNullException(&quot;baseScheduler&quot;);<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> <br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> this is out of date due to code has changed<br /> <br /> ==== Visual C++ Library ====<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ===== SupremacyNative =====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML example: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * string _text = String.Format(ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;),parameter1, parameter2;<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> * _appContext.LocalPlayer.Empire<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> if not available, try &quot;Quick actions&quot; -&gt; using Supremacy.Utility;<br /> <br /> GameLog.Core.GameData.DebugFormat(&quot;Turn {0};xx=;{1};xx=;{2};xx={3};xx={4};xx={5};xx={6};xx={7};xx={8};xx={9};&quot;<br /> , GameContext.Current.TurnNumber<br /> , xx<br /> , xx<br /> );<br /> <br /> == Dictionary ==<br /> <br /> private static Dictionary&lt;string, bool&gt; _acceptRejectDictionary = new Dictionary&lt;string, bool&gt; { { &quot;98&quot;, false } };<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2021-05-09T11:43:35Z <p>Reginald: /* VS2019 */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> * see hints for VS 2017 especially &gt;&gt; Set as Start Project &gt; SupremacyClient (View SolutionExplorer &gt; SupremacyClient &gt; right mouse click ...in the middle)<br /> <br /> ==== Improvement ====<br /> <br /> <br /> OLD: var handler = TurnNumberChanged;<br /> if (handler != null)<br /> handler(this, EventArgs.Empty);<br /> New: TurnNumberChanged?.Invoke(this, EventArgs.Empty);<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> <br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> this is out of date due to code has changed<br /> <br /> ==== Visual C++ Library ====<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ===== SupremacyNative =====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML example: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * string _text = String.Format(ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;),parameter1, parameter2;<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> * _appContext.LocalPlayer.Empire<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> if not available, try &quot;Quick actions&quot; -&gt; using Supremacy.Utility;<br /> <br /> GameLog.Core.GameData.DebugFormat(&quot;Turn {0};xx=;{1};xx=;{2};xx={3};xx={4};xx={5};xx={6};xx={7};xx={8};xx={9};&quot;<br /> , GameContext.Current.TurnNumber<br /> , xx<br /> , xx<br /> );<br /> <br /> == Dictionary ==<br /> <br /> private static Dictionary&lt;string, bool&gt; _acceptRejectDictionary = new Dictionary&lt;string, bool&gt; { { &quot;98&quot;, false } };<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2021-04-11T13:24:05Z <p>Reginald: /* LocalPlayer */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> * see hints for VS 2017 especially &gt;&gt; Set as Start Project &gt; SupremacyClient (View SolutionExplorer &gt; SupremacyClient &gt; right mouse click ...in the middle)<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> <br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> this is out of date due to code has changed<br /> <br /> ==== Visual C++ Library ====<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ===== SupremacyNative =====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML example: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * string _text = String.Format(ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;),parameter1, parameter2;<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> * _appContext.LocalPlayer.Empire<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> if not available, try &quot;Quick actions&quot; -&gt; using Supremacy.Utility;<br /> <br /> GameLog.Core.GameData.DebugFormat(&quot;Turn {0};xx=;{1};xx=;{2};xx={3};xx={4};xx={5};xx={6};xx={7};xx={8};xx={9};&quot;<br /> , GameContext.Current.TurnNumber<br /> , xx<br /> , xx<br /> );<br /> <br /> == Dictionary ==<br /> <br /> private static Dictionary&lt;string, bool&gt; _acceptRejectDictionary = new Dictionary&lt;string, bool&gt; { { &quot;98&quot;, false } };<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Ships Ships 2021-04-03T15:27:19Z <p>Reginald: /* Experience */</p> <hr /> <div><br /> = Intro =<br /> <br /> ...not completed yet...<br /> <br /> Basics please see [[Manual#MILITARY button|Manual]]<br /> <br /> = Ship's Values =<br /> <br /> please see [http://botf2.square7.ch/b2_db/Ships.php BotF2-DB]<br /> <br /> == PopulationHealth ==<br /> <br /> one part (only one?) see [[Planet#Population Health]]<br /> <br /> = Ship's Status =<br /> <br /> please see [[Manual#Ship's Status|Manual]]<br /> <br /> for game-inside details use deployment and mark the ship you want to see details of it (e.g. crew experiance)<br /> <br /> == Renaming ==<br /> <br /> please see [[Manual#RENAMING|Manual]]<br /> <br /> == Shield ==<br /> <br /> please see [[Manual#Ship's Status|Manual]]<br /> <br /> == Hull ==<br /> <br /> please see [[Manual#Ship's Status|Manual]]<br /> <br /> ==== Hull repair ====<br /> <br /> *see in code: \Mainline\SupremacyCore\Orbitals\Orbital.cs -&gt; private void RegenerateHull()<br /> **1.0% in hostile systems 1% (increase = 0.01;)<br /> **2.5% in claimed territory 2,5 % (if (claimingCiv == this.Owner)...increase = 0.025;)<br /> **5.0% in a sector with an owned starbase (if (Sector.Station != null)...increase = 0.05;)<br /> **10.0% at an owned colony (increase = 0.10;)<br /> Only the highest option is chosen.<br /> <br /> == Deuterium ==<br /> <br /> please see [[Manual#Ship's Status|Manual]] and [[Deuterium]]<br /> <br /> = Order =<br /> <br /> please see [[Manual#Ship's Orders|Manual]]<br /> <br /> == FleetOrders.cs ==<br /> <br /> public static readonly EngageOrder EngageOrder;<br /> public static readonly AvoidOrder AvoidOrder;<br /> public static readonly ColonizeOrder ColonizeOrder;<br /> public static readonly TowOrder TowOrder;<br /> public static readonly CollectDeuteriumOrder CollectDeuteriumOrder;<br /> //public static readonly EscortOrder EscortOrder;<br /> public static readonly BuildStationOrder BuildStationOrder;<br /> public static readonly ExploreOrder ExploreOrder;<br /> public static readonly AssaultSystemOrder AssaultSystemOrder;<br /> <br /> == Escort ==<br /> <br /> *disabled https://bitbucket.org/mstrobel/supremacy/issue/322/escort-functionality (issue/322)<br /> <br /> == Train Crew ==<br /> <br /> not part of BotF2, but of Supremacy (see http://www.armadafleetcommand.com/onscreen/botf/viewtopic.php?p=43880#p43880)<br /> <br /> <br /> you can only train the crew if the ship/fleet is orbiting a system with an &quot;academy&quot; building (SF Academy, Naval Academy, etc). Notice the Dominion doesn't have such a building. Some minors' special building are academies, like the Andorians, Zakdorn, etc.<br /> <br /> Ships built in systems with academies start as Regular, and Klingon crews always start with a minimum of 350XP (half the Regular threshold).<br /> <br /> BTW, crews are not yet gaining [[#Experience|experience]] from battles. I'll try to address that soon.<br /> <br /> = Range =<br /> <br /> see this discussion https://bitbucket.org/mstrobel/supremacy/issue/125/shipyard-fuel-range<br /> <br /> = Stranded =<br /> <br /> *Stranded Ships can not retreat https://bitbucket.org/mstrobel/supremacy/issue/219/stranded-ships-can-retreat<br /> <br /> = Combat =<br /> <br /> please see [[Manual#Combat|Manual]]<br /> <br /> == Damage in Combat ==<br /> <br /> *https://bitbucket.org/mstrobel/supremacy/issue/368/damage-control (issue/368)<br /> <br /> == IsBattleFleet ==<br /> <br /> *Fleet.cs Line 310: All ships are BattleFleet without: Scout, Colony, Construction, Medical, Science, Transport<br /> <br /> == NonCombatant ==<br /> <br /> *ShipClass.cs Line 19: <br /> **Colony = 0,<br /> **Construction,<br /> **Transport,<br /> **Medical<br /> <br /> = Deployment =<br /> <br /> please see [[Manual#Task Force Deployment|Manual]]<br /> <br /> = System Assault =<br /> <br /> please see [[Manual#System Assault|Manual]]<br /> <br /> *https://bitbucket.org/mstrobel/supremacy/issue/362/bypassing-obs (issue/362) ( &quot;extra&quot; round of combat between the OBs and the fleet?)<br /> <br /> *https://bitbucket.org/mstrobel/supremacy/issue/363/invasion-by-destroyed-fleets (issue/363)<br /> <br /> = Types of Ships =<br /> <br /> *The SHIPLISTS and NEW SHIP INFO (now Updated) http://www.botf2.star-trek-games.com/viewtopic.php?f=11&amp;t=1066 (search entry t=1066)<br /> <br /> *especially http://www.botf2.star-trek-games.com/viewtopic.php?p=27152#p27152<br /> <br /> <br /> Links:<br /> * BotF at Memory Beta http://memory-beta.wikia.com/wiki/Birth_of_the_Federation<br /> * Alien Ship Database at [http://www.neutralzone.de/database/Alien/index.html www.neutralzone.de]<br /> * [http://www.staryards.com/Downloads/Ships/Other/other_ships.htm Staryards.com] (last entry 2008)<br /> * http://www.moddb.com/mods/foc-alliance-star-trek-tos/images (Kenneth)<br /> <br /> == Plans ==<br /> <br /> *Spy ships -&gt; Infiltrate = get info about the whole spied civilization (don't know yet, but maybe get SystemView by double clicking their sectors for seeing their facilities and structures)<br /> **after spying the ship is destroyed (similar to colony ships). The reason is that a spy ship flies there, agents (=work capacity) integrate into the foreign race and even the ship can't be used for another civilization)<br /> <br /> = Major Ships =<br /> <br /> see [[TechObjectDatabase.xml]] and [[TextDatabase.xml]]<br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Type/Table<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Images<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Status<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Issues<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Comment<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> |- <br /> |style=text-align:left|Table: [[Colony Ship]]s<br /> |style=text-align:left|[[Ship Images#Colony_Ships]]<br /> |style=text-align:center|<br /> |style=text-align:left|Colony Ships are for colonizing (terraforming isn't implemented yet).<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|Table: [[Transport Ship]]s<br /> |style=text-align:left|[[Ship Images#Transport Ships]]<br /> |style=text-align:center|<br /> |style=text-align:left|<br /> Transport ships are for building [[Station]]s and for [[System Assault]]. Don't know whether there are some transport tasks.<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|Table: [[Medical Ship]]s<br /> |style=text-align:left|[[Ship Images#Medical Ships]]<br /> |style=text-align:center|<br /> |style=text-align:left|<br /> Medical ships are for spending health to other ships (maybe not implemented yet)[[Medical_Ship|see here]] <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|Table: [[Scout Ship]]s<br /> |style=text-align:left|[[Ship Images#Scouts]]<br /> |style=text-align:center|<br /> |style=text-align:left|<br /> Scouts are for scouting<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|Table: [[Science Ship]]s<br /> |style=text-align:left|[[Ship Images#Science Ships]]<br /> |style=text-align:center|<br /> |style=text-align:left|<br /> Science ships are <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|Table: [[Construction Ship]]s<br /> |style=text-align:left|[[Ship Images#Construction Ships]]<br /> |style=text-align:center|<br /> |style=text-align:left|<br /> Construction ships are for building [[station]]s for expand the ship's range<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|Table: [[Frigate]]<br /> |style=text-align:left|[[Ship Images#Frigate]]<br /> |style=text-align:center|<br /> |style=text-align:left|<br /> Frigate ships are <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|Table: [[Cruiser]]<br /> |style=text-align:left|[[Ship Images#Cruiser]]<br /> |style=text-align:center|<br /> |style=text-align:left|<br /> Cruiser ships are for<br /> |style=text-align:left|<br /> |style=text-align:left|also Strike Cruiser and Tactical Cruiser<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|Table: [[Destroyer]]<br /> |style=text-align:left|[[Ship Images#Destroyer]]<br /> |style=text-align:center|<br /> |style=text-align:left|<br /> Destroyer ships are for<br /> |style=text-align:left|<br /> |style=text-align:left|also Heavy Destroyer<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|Table: [[Command Ship]]<br /> |style=text-align:left|[[Ship Images#Command Ships]]<br /> |style=text-align:center|<br /> |style=text-align:left|<br /> Command ships are for<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == old lists == <br /> <br /> see [[Ships (old lists)]]<br /> <br /> = Experience = <br /> <br /> at the moment: Moving = 5 points, staying = 1 point, max = 10000 points<br /> <br /> *https://bitbucket.org/mstrobel/supremacy/issue/31/starting-crew-xp<br /> **Ships built when an academy (Starfleet Academy, Naval Academy etc) is built and powered are not starting as having a Regular crew (700 XP) like in BotF<br /> <br /> Experience Rank: see table below<br /> <br /> *Buildings PercentShipExperience: [http://botf2.square7.ch/b2_db/BuildingsPercentShipExperience.php Database-List]<br /> <br /> <br /> see also [[#Train Crew]]<br /> <br /> = Accuracy Modifier =<br /> <br /> see table below<br /> <br /> = Damage Control Modifiers =<br /> <br /> Values defined in [[Table#ShipTables.txt|ShipTables.txt]]<br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Exp.Rank<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Image<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Exp.LowerBound<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |DamageControlModifiers<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |AccuracyModifiers<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Comment<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> |- <br /> |style=text-align:center|Green<br /> |style=text-align:center|<br /> |style=text-align:center|0<br /> |style=text-align:left|1.0<br /> |style=text-align:left|0.5<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:center|Regular<br /> |style=text-align:center|<br /> |style=text-align:center|700<br /> |style=text-align:left|0.9<br /> |style=text-align:left|0.7<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:center|Veteran<br /> |style=text-align:center|<br /> |style=text-align:center|1500<br /> |style=text-align:left|0.75<br /> |style=text-align:left|0.8<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:center|Elite<br /> |style=text-align:center|<br /> |style=text-align:center|5000<br /> |style=text-align:left|0.60<br /> |style=text-align:left|0.9<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:center|Legendary<br /> |style=text-align:center|<br /> |style=text-align:center|8000<br /> |style=text-align:left|0.25<br /> |style=text-align:left|1.0<br /> |style=text-align:left|<br /> |style=text-align:right|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> = ShipBuilding =<br /> <br /> see [[Shipyard]]<br /> <br /> *Buildings: <br /> **PercentShipBuilding: [http://botf2.square7.ch/b2_db/BuildingsPercentShipExperience.php Database-List]<br /> **PercentScrapping: [http://botf2.square7.ch/b2_db/BuildingsPercentScrapping.php Database-List]<br /> ***https://bitbucket.org/mstrobel/supremacy/issue/238/percentscrapping-not-working (issue/238) [CLOSED]<br /> <br /> == Rally point ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/343/ship-rally-points<br /> <br /> = Population Support =<br /> <br /> see [[Population#Population Support]]<br /> <br /> = Minor =<br /> <br /> they are part of [[:Category:Races|the special race sites]] (still under construction). See also [[Minor]]<br /> <br /> <br /> no use yet:<br /> {| align=&quot;left&quot;|<br /> |align=&quot;center&quot;|[[Minor|&lt;span style=&quot;color:black&quot;&gt;Minor Axanar&lt;/span&gt;]]<br /> |<br /> |align=&quot;center&quot;|[[Minor|&lt;span style=&quot;color:black&quot;&gt;Minor Coridan&lt;/span&gt;]]<br /> |<br /> |align=&quot;center&quot;|[[Minor|&lt;span style=&quot;color:black&quot;&gt;Minor Kazon&lt;/span&gt;]]<br /> |<br /> |align=&quot;center&quot;|[[Minor|&lt;span style=&quot;color:black&quot;&gt;Minor Tellarite&lt;/span&gt;]]<br /> <br /> |- <br /> |style=&quot;border:5px solid grey;padding:0.1em;padding-left:0.1em;&quot; bgcolor=&quot;#000000&quot;|&lt;img size=200&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Ships/axanar_shipyard.png&lt;/img&gt; <br /> | <br /> |style=&quot;border:5px solid grey;padding:0.1em;padding-left:0.1em;&quot; bgcolor=&quot;#000000&quot;|&lt;img size=200&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Ships/coridan_shipyard.png&lt;/img&gt; <br /> | <br /> |style=&quot;border:5px solid grey;padding:0.1em;padding-left:0.1em;&quot; bgcolor=&quot;#000000&quot;|&lt;img size=200&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Ships/kazon_shipyard.png&lt;/img&gt; <br /> | <br /> |style=&quot;border:5px solid grey;padding:0.1em;padding-left:0.1em;&quot; bgcolor=&quot;#000000&quot;|&lt;img size=200&gt;http://botf2.square7.ch/wiki-files/images/TechObjects/Ships/tellarite_shipyard.png&lt;/img&gt; <br /> <br /> <br /> |}<br /> <br /> = Type4Ships =<br /> <br /> * BORG_CUBE_IV<br /> * BORG_TACTICAL_CUBE_IV<br /> * CARD_CRUISER_IV<br /> * CARD_DESTROYER_IV<br /> * DOM_CRUISER_IV<br /> * DOM_DESTROYER_IV<br /> * FED_CRUISER_IV<br /> * KLING_CRUISER_IV<br /> * KLING_DESTROYER_IV<br /> * ROM_CRUISER_IV<br /> * ROM_DESTROYER_IV<br /> * TERRAN_CRUISER_IV<br /> <br /> = Type5Ships =<br /> <br /> * BORG_CUBE_V<br /> * BORG_TACTICAL_CUBE_V<br /> * FED_CRUISER_V<br /> * TERRAN_CRUISER_V<br /> <br /> <br /> [[Category:Ships]]</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Screenshots Screenshots 2021-02-06T13:57:35Z <p>Reginald: /* some pictures */</p> <hr /> <div>= some pictures =<br /> <br /> *some more screenshots &gt; sorry, http://www.startreksupremacy.com/screenshots.html is offline<br /> <br /> == [[Start Game Panel]] ==<br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/self-explanatoryMenu.png&lt;/img&gt;<br /> <br /> <br /> <br /> == [[Galaxy Panel]] ==<br /> &lt;img size=957&gt;http://botf2.square7.ch/wiki-files/images/_Screenshots/1---Galaxy/1---GalaxyPanel_Described.jpg&lt;/img&gt;<br /> <br /> == [[Embassy Panel]] ==<br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/EmbassyPanel.png&lt;/img&gt;<br /> <br /> <br /> <br /> == [[System Structures]] ==<br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/SystemStructuresScreen.png&lt;/img&gt;<br /> <br /> == [[System Production]] ==<br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/SystemSummary.png&lt;/img&gt;<br /> <br /> == ShipMovement ==<br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/ShipMovement.png&lt;/img&gt;<br /> <br /> == Combat ==<br /> <br /> &lt;div style=&quot;border:1px solid black;width:100%;overflow-y:hidden;overflow-x:scroll;background-color:#dadada; &quot;&gt;<br /> &lt;p style=&quot;width:100%;&quot;&gt;<br /> {| class=&quot;infobox&quot;<br /> |valign=&quot;top&quot; align=&quot;center&quot; bgcolor=&quot;#fafaba&quot;| Combat<br /> |-<br /> | bgcolor=&quot;#fafafa&quot; - valign=&quot;top&quot;|<br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Combat.png&lt;/img&gt;<br /> |}<br /> &lt;/p&gt;<br /> &lt;/div&gt;<br /> <br /> <br /> == System Assault ==<br /> <br /> &lt;div style=&quot;border:1px solid black;width:100%;overflow-y:hidden;overflow-x:scroll;background-color:#dadada; &quot;&gt;<br /> &lt;p style=&quot;width:100%;&quot;&gt;<br /> {| class=&quot;infobox&quot;<br /> |valign=&quot;top&quot; align=&quot;center&quot; bgcolor=&quot;#fafaba&quot;| System Assault<br /> |-<br /> | bgcolor=&quot;#fafafa&quot; - valign=&quot;top&quot;|<br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/SystemAssaultMenu.jpg&lt;/img&gt;<br /> |}<br /> &lt;/p&gt;<br /> &lt;/div&gt;<br /> <br /> <br /> == alternativ Title.png ==<br /> <br /> &lt;div style=&quot;border:1px solid black;width:100%;overflow-y:hidden;overflow-x:scroll;background-color:#dadada; &quot;&gt;<br /> &lt;p style=&quot;width:100%;&quot;&gt;<br /> {| class=&quot;infobox&quot;<br /> |valign=&quot;top&quot; align=&quot;center&quot; bgcolor=&quot;#fafaba&quot;| Title by Captain Bashir<br /> |-<br /> | bgcolor=&quot;#fafafa&quot; - valign=&quot;top&quot;|<br /> &lt;img size=1280&gt;http://botf2.square7.ch/wiki-files/images/Backgrounds/Title_Test.jpg&lt;/img&gt;<br /> |}<br /> &lt;/p&gt;<br /> &lt;/div&gt;<br /> <br /> <br /> <br /> [[category:Screenshots]]</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-12-20T10:39:03Z <p>Reginald: /* Button */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> === Shared.xaml ===<br /> <br /> Parts and Structure of each Shared.xaml could be (but is not ..take Klingons as an example, not the Federation sharing a lot of stuff with Global.xaml)<br /> <br /> === Border ===<br /> <br /> * LCARS_BorderStyle (e.g. Chat-Window)<br /> * LCARS_ThinBorderStyle (e.g. Summary)<br /> <br /> === Button ===<br /> <br /> * GameButton - Templates: // e.g. Economy<br /> ** &lt;Trigger Property=&quot;Context&quot; Value=&quot;HorizontalGroupItem&quot;&gt;<br /> ** &lt;Trigger Property=&quot;DisplayMode&quot; Value=&quot;GroupedHorizontally&quot;&gt;<br /> ** &lt;Trigger Property=&quot;DisplayMode&quot; Value=&quot;GroupedVertically&quot;&gt;<br /> ** &lt;Trigger Property=&quot;Context&quot; Value=&quot;VerticalGroupItem&quot;&gt;<br /> ** &lt;Trigger Property=&quot;DisplayMode&quot; Value=&quot;CheckBox&quot;&gt;<br /> ** &lt;Trigger Property=&quot;DisplayMode&quot; Value=&quot;Hyperlink&quot;&gt;<br /> ** &lt;Trigger Property=&quot;DisplayMode&quot; Value=&quot;Minimal&quot;&gt;<br /> ** &lt;Trigger Property=&quot;DisplayMode&quot; Value=&quot;Tiny&quot;&gt;<br /> <br /> <br /> * LCARS_BorderButtonStyle<br /> * LCARS_BorderToggleButtonStyle&quot; // e.g. CHAT Button in GalaxyMapView<br /> * LCARS_SimpleButtonStyle // e.g. REDEPLOY-Button<br /> * LCARS_SimpleToggleButtonStyle<br /> <br /> <br /> * Default = IsEnable = Current Selection = GREEN = LCARS_Dom3Gradient_Bottom_Top<br /> * MouseOver = PINK GRADIENT = LCARS_Dom2Gradient_Bottom_Top<br /> * IsPressed = PINK = LCARS_Dom1Gradient_Bottom_Top<br /> * IsChecked<br /> <br /> === TextBrush ===<br /> <br /> Usage: {StaticResource HeaderTextBrush}<br /> *DefaultTextBrush&quot;<br /> *HeaderTextBrush&quot;<br /> *LCARS_HeaderBrush&quot;<br /> *DisabledTextBrush&quot;<br /> *SelectionBrush&quot;<br /> *BorderBrush&quot;<br /> <br /> ----<br /> <br /> * ControlTextForegroundBrushKey<br /> <br /> * HeaderTextForegroundBrushKey<br /> <br /> * DefaultTextForegroundBrushKey<br /> <br /> * ImageBorderBrushKey<br /> <br /> * DisabledTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> * InactiveHighlightBrushKey<br /> <br /> * AlertTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> SitReps are a part of CivManager of a Civilization...<br /> <br /> * SitRepEntry.cs (contains a Global SitRep-Function and special ones)<br /> <br /> * SitRepDialog.xaml ( = Dialog )<br /> * SitRepDialog.xaml.cs ( Logic for Dialog = Filter on/off )<br /> <br /> == Context Menu ==<br /> <br /> * SupremacyClient\themes\Dominion\GameContextMenu.xaml<br /> * GalaxyScreenView.xaml<br /> <br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> === Right ===<br /> <br /> * SystemProductionPanel.cs (without any xaml file !)<br /> <br /> === Left ===<br /> <br /> * ColonyHandlingListView.cs<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Resource Resource 2020-12-13T10:38:14Z <p>Reginald: /* Dilithium */</p> <hr /> <div>= Intro =<br /> <br /> [[Resource]]s like [[Duranium]] &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/rawmaterials.png&lt;/img&gt; and [[Dilithium]] &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/dilithium.png&lt;/img&gt; are desirable for ship construction. They are shown right beside the sun. (For other symbols see [[System#Symbols|here]])<br /> <br /> [[Deuterium]] &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/deuterium.png&lt;/img&gt; is another one.<br /> <br /> *These resources will primarly used for local production in a system, but unused resources are given to the global stockpile. <br /> <br /> *On the other side for system production resources out of global stockpile are used for local production. <br /> <br /> *To avoid that one system get's an advantage or an disadvantage when global stockpile is low, system's sequence is shuffled (Algorithms.RandomShuffleInPlace(colonies)).<br /> <br /> <br /> Later another resource will follow: [[Personnel]] &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/personnel.png&lt;/img&gt;<br /> <br /> <br /> Other resources are [[Food]] &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/food.png&lt;/img&gt; and [[Energy]] &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/energy.png&lt;/img&gt;<br /> <br /> = Distribution =<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/342/resources-colonies<br /> <br /> <br /> Raw Materials(Duranium), Deuterium, Dilithium is collected cross over all colonies and used by all colonies <br /> *SupremacyCore\Game\GameEngine.cs void DoProduction(GameContext game) <br /> <br /> <br /> for others (e.g. Food, Industry, Energy):<br /> *SupremacyCore\Universe\Colony.cs<br /> <br /> = Dilithium =<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/dilithium.png&lt;/img&gt;<br /> <br /> <br /> *Buildings<br /> **Dilithium: [http://botf2.square7.ch/b2_db/BuildingsDilithium.php Database-List]<br /> <br /> <br /> *https://bitbucket.org/mstrobel/supremacy/issue/75/colonies-screen-3 (issue/75)<br /> <br /> = Duranium =<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/rawmaterials.png&lt;/img&gt; Duranium -also called RawMaterials- ...<br /> <br /> *Buildings<br /> **RawMaterials + PercentRawMaterials: [http://botf2.square7.ch/b2_db/BuildingsRawMaterials.php Database-List]<br /> <br /> ==== FAQ Duranium ====<br /> '''Q: How do I get more Duranium?'''<br /> <br /> A: Systems with Asteroids can build a structure that mines additional Duranium. Some empires have structures that mine extra Duranium (Cardassians, Dominion). There's also a universal structure that allows a lot more Duranium to be mined, but with a huge Morale penalty (Core Mining Complex).<br /> <br /> = Deuterium =<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/deuterium.png&lt;/img&gt;<br /> <br /> *Buildings<br /> **Deuterium + PercentDeuterium: [http://botf2.square7.ch/b2_db/BuildingsRawMaterials.php Database-List]<br /> <br /> 2018-08-12: Add missing Deuterium Extractor for some empires<br /> <br /> = Personnel =<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/personnel.png&lt;/img&gt;<br /> <br /> *Buildings (at the moment no such building available because Personnel isn't ingame at the moment)<br /> **Personnel + PercentPersonnelLoyalty + PercentPersonnelTraining: [http://botf2.square7.ch/b2_db/BuildingsPersonnel.php Database-List]<br /> <br /> = Food =<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/food.png&lt;/img&gt; see [[Food]]<br /> <br /> *Buildings<br /> **Food + PercentFood: [http://botf2.square7.ch/b2_db/BuildingsFood.php Database-List]<br /> <br /> = Energy =<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/Resources/energy.png&lt;/img&gt;<br /> <br /> *Buildings<br /> **Energy + PercentEnergy: [http://botf2.square7.ch/b2_db/BuildingsEnergy.php Database-List]<br /> <br /> == Energy shortage ==<br /> <br /> *https://bitbucket.org/mstrobel/supremacy/issue/24/energy-shortages (issue/24): OBs are shut down last, power shortages should be most critical (and happen mostly) during bombardments, where OBs are more important. (Shipyards energy is also critical due to range extender)</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-12-06T12:39:17Z <p>Reginald: /* Theme */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> === Shared.xaml ===<br /> <br /> Parts and Structure of each Shared.xaml could be (but is not ..take Klingons as an example, not the Federation sharing a lot of stuff with Global.xaml)<br /> <br /> === Border ===<br /> <br /> * LCARS_BorderStyle (e.g. Chat-Window)<br /> * LCARS_ThinBorderStyle (e.g. Summary)<br /> <br /> === Button ===<br /> <br /> * GameButton // e.g. Economy<br /> ** Style <br /> ** Normal = just Text rectangle<br /> ** Tiny<br /> ** <br /> * LCARS_BorderButtonStyle<br /> * LCARS_BorderToggleButtonStyle&quot; // e.g. CHAT Button in GalaxyMapView<br /> * LCARS_SimpleButtonStyle // e.g. REDEPLOY-Button<br /> * LCARS_SimpleToggleButtonStyle<br /> <br /> <br /> * Default = IsEnable = Current Selection = GREEN = LCARS_Dom3Gradient_Bottom_Top<br /> * MouseOver = PINK GRADIENT = LCARS_Dom2Gradient_Bottom_Top<br /> * IsPressed = PINK = LCARS_Dom1Gradient_Bottom_Top<br /> * IsChecked<br /> <br /> === TextBrush ===<br /> <br /> Usage: {StaticResource HeaderTextBrush}<br /> *DefaultTextBrush&quot;<br /> *HeaderTextBrush&quot;<br /> *LCARS_HeaderBrush&quot;<br /> *DisabledTextBrush&quot;<br /> *SelectionBrush&quot;<br /> *BorderBrush&quot;<br /> <br /> ----<br /> <br /> * ControlTextForegroundBrushKey<br /> <br /> * HeaderTextForegroundBrushKey<br /> <br /> * DefaultTextForegroundBrushKey<br /> <br /> * ImageBorderBrushKey<br /> <br /> * DisabledTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> * InactiveHighlightBrushKey<br /> <br /> * AlertTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> SitReps are a part of CivManager of a Civilization...<br /> <br /> * SitRepEntry.cs (contains a Global SitRep-Function and special ones)<br /> <br /> * SitRepDialog.xaml ( = Dialog )<br /> * SitRepDialog.xaml.cs ( Logic for Dialog = Filter on/off )<br /> <br /> == Context Menu ==<br /> <br /> * SupremacyClient\themes\Dominion\GameContextMenu.xaml<br /> * GalaxyScreenView.xaml<br /> <br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> === Right ===<br /> <br /> * SystemProductionPanel.cs (without any xaml file !)<br /> <br /> === Left ===<br /> <br /> * ColonyHandlingListView.cs<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2020-12-05T10:06:40Z <p>Reginald: /* Visual Studio */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> * see hints for VS 2017 especially &gt;&gt; Set as Start Project &gt; SupremacyClient (View SolutionExplorer &gt; SupremacyClient &gt; right mouse click ...in the middle)<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> <br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> this is out of date due to code has changed<br /> <br /> ==== Visual C++ Library ====<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ===== SupremacyNative =====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML example: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * string _text = String.Format(ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;),parameter1, parameter2;<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> if not available, try &quot;Quick actions&quot; -&gt; using Supremacy.Utility;<br /> <br /> GameLog.Core.GameData.DebugFormat(&quot;Turn {0};xx=;{1};xx=;{2};xx={3};xx={4};xx={5};xx={6};xx={7};xx={8};xx={9};&quot;<br /> , GameContext.Current.TurnNumber<br /> , xx<br /> , xx<br /> );<br /> <br /> == Dictionary ==<br /> <br /> private static Dictionary&lt;string, bool&gt; _acceptRejectDictionary = new Dictionary&lt;string, bool&gt; { { &quot;98&quot;, false } };<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2020-12-05T10:02:39Z <p>Reginald: /* Visual Studio */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> <br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> this is out of date due to code has changed<br /> <br /> ==== Visual C++ Library ====<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ===== SupremacyNative =====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML example: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * string _text = String.Format(ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;),parameter1, parameter2;<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> if not available, try &quot;Quick actions&quot; -&gt; using Supremacy.Utility;<br /> <br /> GameLog.Core.GameData.DebugFormat(&quot;Turn {0};xx=;{1};xx=;{2};xx={3};xx={4};xx={5};xx={6};xx={7};xx={8};xx={9};&quot;<br /> , GameContext.Current.TurnNumber<br /> , xx<br /> , xx<br /> );<br /> <br /> == Dictionary ==<br /> <br /> private static Dictionary&lt;string, bool&gt; _acceptRejectDictionary = new Dictionary&lt;string, bool&gt; { { &quot;98&quot;, false } };<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-11-22T15:48:33Z <p>Reginald: /* Button */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> === Border ===<br /> <br /> * LCARS_BorderStyle (e.g. Chat-Window)<br /> * LCARS_ThinBorderStyle (e.g. Summary)<br /> <br /> === Button ===<br /> <br /> * GameButton // e.g. Economy<br /> ** Style <br /> ** Normal = just Text rectangle<br /> ** Tiny<br /> ** <br /> * LCARS_BorderButtonStyle<br /> * LCARS_BorderToggleButtonStyle&quot; // e.g. CHAT Button in GalaxyMapView<br /> * LCARS_SimpleButtonStyle // e.g. REDEPLOY-Button<br /> * LCARS_SimpleToggleButtonStyle<br /> <br /> <br /> * Default = IsEnable = Current Selection = GREEN = LCARS_Dom3Gradient_Bottom_Top<br /> * MouseOver = PINK GRADIENT = LCARS_Dom2Gradient_Bottom_Top<br /> * IsPressed = PINK = LCARS_Dom1Gradient_Bottom_Top<br /> * IsChecked<br /> <br /> === TextBrush ===<br /> <br /> Usage: {StaticResource HeaderTextBrush}<br /> *DefaultTextBrush&quot;<br /> *HeaderTextBrush&quot;<br /> *LCARS_HeaderBrush&quot;<br /> *DisabledTextBrush&quot;<br /> *SelectionBrush&quot;<br /> *BorderBrush&quot;<br /> <br /> ----<br /> <br /> * ControlTextForegroundBrushKey<br /> <br /> * HeaderTextForegroundBrushKey<br /> <br /> * DefaultTextForegroundBrushKey<br /> <br /> * ImageBorderBrushKey<br /> <br /> * DisabledTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> * InactiveHighlightBrushKey<br /> <br /> * AlertTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> SitReps are a part of CivManager of a Civilization...<br /> <br /> * SitRepEntry.cs (contains a Global SitRep-Function and special ones)<br /> <br /> * SitRepDialog.xaml ( = Dialog )<br /> * SitRepDialog.xaml.cs ( Logic for Dialog = Filter on/off )<br /> <br /> == Context Menu ==<br /> <br /> * SupremacyClient\themes\Dominion\GameContextMenu.xaml<br /> * GalaxyScreenView.xaml<br /> <br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> === Right ===<br /> <br /> * SystemProductionPanel.cs (without any xaml file !)<br /> <br /> === Left ===<br /> <br /> * ColonyHandlingListView.cs<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-11-22T15:18:23Z <p>Reginald: /* TextBrush */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> === Border ===<br /> <br /> * LCARS_BorderStyle (e.g. Chat-Window)<br /> * LCARS_ThinBorderStyle (e.g. Summary)<br /> <br /> === Button ===<br /> <br /> * GameButton // e.g. Economy<br /> * LCARS_BorderButtonStyle<br /> * LCARS_BorderToggleButtonStyle&quot; // e.g. CHAT Button in GalaxyMapView<br /> * LCARS_SimpleButtonStyle // e.g. REDEPLOY-Button<br /> * LCARS_SimpleToggleButtonStyle<br /> <br /> <br /> * Default = IsEnable = Current Selection = GREEN = LCARS_Dom3Gradient_Bottom_Top<br /> * MouseOver = PINK GRADIENT = LCARS_Dom2Gradient_Bottom_Top<br /> * IsPressed = PINK = LCARS_Dom1Gradient_Bottom_Top<br /> * IsChecked<br /> <br /> === TextBrush ===<br /> <br /> Usage: {StaticResource HeaderTextBrush}<br /> *DefaultTextBrush&quot;<br /> *HeaderTextBrush&quot;<br /> *LCARS_HeaderBrush&quot;<br /> *DisabledTextBrush&quot;<br /> *SelectionBrush&quot;<br /> *BorderBrush&quot;<br /> <br /> ----<br /> <br /> * ControlTextForegroundBrushKey<br /> <br /> * HeaderTextForegroundBrushKey<br /> <br /> * DefaultTextForegroundBrushKey<br /> <br /> * ImageBorderBrushKey<br /> <br /> * DisabledTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> * InactiveHighlightBrushKey<br /> <br /> * AlertTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> SitReps are a part of CivManager of a Civilization...<br /> <br /> * SitRepEntry.cs (contains a Global SitRep-Function and special ones)<br /> <br /> * SitRepDialog.xaml ( = Dialog )<br /> * SitRepDialog.xaml.cs ( Logic for Dialog = Filter on/off )<br /> <br /> == Context Menu ==<br /> <br /> * SupremacyClient\themes\Dominion\GameContextMenu.xaml<br /> * GalaxyScreenView.xaml<br /> <br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> === Right ===<br /> <br /> * SystemProductionPanel.cs (without any xaml file !)<br /> <br /> === Left ===<br /> <br /> * ColonyHandlingListView.cs<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Data Data 2020-11-01T12:30:45Z <p>Reginald: /* CivilizationManager */</p> <hr /> <div>== Intro ==<br /> <br /> == CivilizationManager ==<br /> <br /> in code often &quot;civManager&quot;<br /> <br /> * all out of [[#Civilization]] and managed data (see next)<br /> <br /> * Owner (for minors) <br /> * Colonies (counted)<br /> * Population (total)<br /> <br /> * Credits<br /> * Credits last Turn<br /> * Maintenance<br /> * Tax<br /> * Trade Route Income (total?)<br /> * Empire Morale<br /> * Research (Percent + Values in total + current production)<br /> * Intel Production (total)<br /> * Intel Defense<br /> * Intel Attack<br /> * Dilithium total / last turn<br /> * Deuterium total / last turn<br /> * Duranium total / last turn<br /> <br /> == Civilization ==<br /> <br /> contains FIX data out of Civilizations.xml like (Federation as example)<br /> * Race&gt;HUMANS<br /> * ShortName&gt;Federation<br /> * LongName&gt;United Federation of Planets<br /> * ShortNameArtCap&gt;The Federation<br /> * ShortNameArtDir&gt;the Federation<br /> * ShortNameFromThe&gt;from the Federation<br /> * ShortNameToThe&gt;to the Federation<br /> * LongNameArtCap&gt;The United Federation of Planets<br /> * LongNameArtDir&gt;the United Federation of Planets<br /> * LongNameFromThe&gt;from the United Federation of Planets<br /> * LongNameOfTheGreater&gt;of the greater United Federation of Planets&lt;/LongNameOfTheGreater&gt;<br /> * DiplomacyReport&gt; ...<br /> * HomeSystemName&gt;Sol<br /> * Color&gt;Blue<br /> * HomeQuadrant&gt;Alpha<br /> * CivilizationType&gt;Empire<br /> * Traits&gt;Compassion,Materialistic,Peaceful<br /> * IndustryToCreditsConversionRatio&gt;50<br /> * TechCurve&gt;TechCurve6<br /> * ShipPrefix&gt;USS</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Data Data 2020-11-01T12:04:25Z <p>Reginald: Created page with &quot;== Intro == == CivilizationManager == in code often &quot;civManager&quot; * all out of #Civilization and managed data (see next) * Owner (for minors) * Colonies (counted) * Po...&quot;</p> <hr /> <div>== Intro ==<br /> <br /> == CivilizationManager ==<br /> <br /> in code often &quot;civManager&quot;<br /> <br /> * all out of [[#Civilization]] and managed data (see next)<br /> <br /> * Owner (for minors) <br /> * Colonies (counted)<br /> * Population (total)<br /> <br /> * Credits<br /> * Credits last Turn<br /> * Maintenance<br /> * Tax<br /> * Trade Route Income (total?)<br /> * Empire Morale<br /> * Research<br /> * Intel Production (total)<br /> * Intel Defense<br /> * Intel Attack<br /> * Dilithium total / last turn<br /> * Deuterium total / last turn<br /> * Duranium total / last turn<br /> <br /> <br /> == Civilization ==<br /> <br /> contains FIX data out of Civilizations.xml like (Federation as example)<br /> * Race&gt;HUMANS<br /> * ShortName&gt;Federation<br /> * LongName&gt;United Federation of Planets<br /> * ShortNameArtCap&gt;The Federation<br /> * ShortNameArtDir&gt;the Federation<br /> * ShortNameFromThe&gt;from the Federation<br /> * ShortNameToThe&gt;to the Federation<br /> * LongNameArtCap&gt;The United Federation of Planets<br /> * LongNameArtDir&gt;the United Federation of Planets<br /> * LongNameFromThe&gt;from the United Federation of Planets<br /> * LongNameOfTheGreater&gt;of the greater United Federation of Planets&lt;/LongNameOfTheGreater&gt;<br /> * DiplomacyReport&gt; ...<br /> * HomeSystemName&gt;Sol<br /> * Color&gt;Blue<br /> * HomeQuadrant&gt;Alpha<br /> * CivilizationType&gt;Empire<br /> * Traits&gt;Compassion,Materialistic,Peaceful<br /> * IndustryToCreditsConversionRatio&gt;50<br /> * TechCurve&gt;TechCurve6<br /> * ShipPrefix&gt;USS</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2020-10-31T13:28:51Z <p>Reginald: /* MessageBox (Windows Style) */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === Visual C++ Library ===<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ==== SupremacyNative ====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML example: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * string _text = String.Format(ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;),parameter1, parameter2;<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> if not available, try &quot;Quick actions&quot; -&gt; using Supremacy.Utility;<br /> <br /> GameLog.Core.GameData.DebugFormat(&quot;Turn {0};xx=;{1};xx=;{2};xx={3};xx={4};xx={5};xx={6};xx={7};xx={8};xx={9};&quot;<br /> , GameContext.Current.TurnNumber<br /> , xx<br /> , xx<br /> );<br /> <br /> == Dictionary ==<br /> <br /> private static Dictionary&lt;string, bool&gt; _acceptRejectDictionary = new Dictionary&lt;string, bool&gt; { { &quot;98&quot;, false } };<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-31T10:34:36Z <p>Reginald: /* SUMMARY */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> === Border ===<br /> <br /> * LCARS_BorderStyle (e.g. Chat-Window)<br /> * LCARS_ThinBorderStyle (e.g. Summary)<br /> <br /> === Button ===<br /> <br /> * GameButton // e.g. Economy<br /> * LCARS_BorderButtonStyle<br /> * LCARS_BorderToggleButtonStyle&quot; // e.g. CHAT Button in GalaxyMapView<br /> * LCARS_SimpleButtonStyle // e.g. REDEPLOY-Button<br /> * LCARS_SimpleToggleButtonStyle<br /> <br /> <br /> * Default = IsEnable = Current Selection = GREEN = LCARS_Dom3Gradient_Bottom_Top<br /> * MouseOver = PINK GRADIENT = LCARS_Dom2Gradient_Bottom_Top<br /> * IsPressed = PINK = LCARS_Dom1Gradient_Bottom_Top<br /> * IsChecked<br /> <br /> === TextBrush ===<br /> <br /> * ControlTextForegroundBrushKey<br /> <br /> * HeaderTextForegroundBrushKey<br /> <br /> * DefaultTextForegroundBrushKey<br /> <br /> * ImageBorderBrushKey<br /> <br /> * DisabledTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> * InactiveHighlightBrushKey<br /> <br /> * AlertTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> SitReps are a part of CivManager of a Civilization...<br /> <br /> * SitRepEntry.cs (contains a Global SitRep-Function and special ones)<br /> <br /> * SitRepDialog.xaml ( = Dialog )<br /> * SitRepDialog.xaml.cs ( Logic for Dialog = Filter on/off )<br /> <br /> == Context Menu ==<br /> <br /> * SupremacyClient\themes\Dominion\GameContextMenu.xaml<br /> * GalaxyScreenView.xaml<br /> <br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> === Right ===<br /> <br /> * SystemProductionPanel.cs (without any xaml file !)<br /> <br /> === Left ===<br /> <br /> * ColonyHandlingListView.cs<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2020-10-24T10:54:13Z <p>Reginald: /* GameLog */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === Visual C++ Library ===<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ==== SupremacyNative ====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML example: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * string _text = String.Format(ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;),parameter1, parameter2;<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> if not available, try &quot;Quick actions&quot; -&gt; using Supremacy.Utility;<br /> <br /> GameLog.Core.GameData.DebugFormat(&quot;Turn {0};xx=;{1};xx=;{2};xx={3};xx={4};xx={5};xx={6};xx={7};xx={8};xx={9};&quot;<br /> , GameContext.Current.TurnNumber<br /> , xx<br /> , xx<br /> );<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-18T12:21:12Z <p>Reginald: /* Theme */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> === Border ===<br /> <br /> * LCARS_BorderStyle (e.g. Chat-Window)<br /> * LCARS_ThinBorderStyle (e.g. Summary)<br /> <br /> === Button ===<br /> <br /> * GameButton // e.g. Economy<br /> * LCARS_BorderButtonStyle<br /> * LCARS_BorderToggleButtonStyle&quot; // e.g. CHAT Button in GalaxyMapView<br /> * LCARS_SimpleButtonStyle // e.g. REDEPLOY-Button<br /> * LCARS_SimpleToggleButtonStyle<br /> <br /> <br /> * Default = IsEnable = Current Selection = GREEN = LCARS_Dom3Gradient_Bottom_Top<br /> * MouseOver = PINK GRADIENT = LCARS_Dom2Gradient_Bottom_Top<br /> * IsPressed = PINK = LCARS_Dom1Gradient_Bottom_Top<br /> * IsChecked<br /> <br /> === TextBrush ===<br /> <br /> * ControlTextForegroundBrushKey<br /> <br /> * HeaderTextForegroundBrushKey<br /> <br /> * DefaultTextForegroundBrushKey<br /> <br /> * ImageBorderBrushKey<br /> <br /> * DisabledTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> * InactiveHighlightBrushKey<br /> <br /> * AlertTextForegroundBrushKey<br /> <br /> * HighlightBrushKey<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == Context Menu ==<br /> <br /> * SupremacyClient\themes\Dominion\GameContextMenu.xaml<br /> * GalaxyScreenView.xaml<br /> <br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> === Right ===<br /> <br /> * SystemProductionPanel.cs (without any xaml file !)<br /> <br /> === Left ===<br /> <br /> * ColonyHandlingListView.cs<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-18T09:53:35Z <p>Reginald: /* F2 */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> === Border ===<br /> <br /> * LCARS_BorderStyle (e.g. Chat-Window)<br /> * LCARS_ThinBorderStyle (e.g. Summary)<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == Context Menu ==<br /> <br /> * SupremacyClient\themes\Dominion\GameContextMenu.xaml<br /> * GalaxyScreenView.xaml<br /> <br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> === Right ===<br /> <br /> * SystemProductionPanel.cs (without any xaml file !)<br /> <br /> === Left ===<br /> <br /> * ColonyHandlingListView.cs<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-18T09:19:52Z <p>Reginald: /* F2 */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> === Border ===<br /> <br /> * LCARS_BorderStyle (e.g. Chat-Window)<br /> * LCARS_ThinBorderStyle (e.g. Summary)<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == Context Menu ==<br /> <br /> * SupremacyClient\themes\Dominion\GameContextMenu.xaml<br /> * GalaxyScreenView.xaml<br /> <br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> * SystemProductionPanel.cs (without any xaml file !)<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-11T10:46:26Z <p>Reginald: /* Bottom View */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> === Border ===<br /> <br /> * LCARS_BorderStyle (e.g. Chat-Window)<br /> * LCARS_ThinBorderStyle (e.g. Summary)<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == Context Menu ==<br /> <br /> * SupremacyClient\themes\Dominion\GameContextMenu.xaml<br /> * GalaxyScreenView.xaml<br /> <br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-04T13:57:26Z <p>Reginald: /* Theme */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> === Border ===<br /> <br /> * LCARS_BorderStyle (e.g. Chat-Window)<br /> * LCARS_ThinBorderStyle (e.g. Summary)<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-04T13:49:17Z <p>Reginald: /* Colour */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Theme ==<br /> <br /> * Themes are appearance of each Empire's UI.<br /> <br /> Common stuff is content of Global.xaml<br /> <br /> Empire's themes are defined in Shared.xaml<br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-04T13:47:29Z <p>Reginald: </p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Colour ==<br /> <br /> === LightBlue ===<br /> * Research<br /> * Dilithium<br /> <br /> === Red ===<br /> * Deuterium<br /> <br /> === Silver ===<br /> * Intelligence<br /> <br /> === Gray ===<br /> * Duranium = Rax Materials<br /> <br /> === Goldrod ===<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-04T13:46:48Z <p>Reginald: /* Borg */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Colour ==<br /> <br /> == LightBlue ==<br /> * Research<br /> * Dilithium<br /> <br /> == Red ==<br /> * Deuterium<br /> <br /> == Silver ==<br /> * Intelligence<br /> <br /> == Gray ==<br /> * Duranium = Rax Materials<br /> <br /> == Goldrod ==<br /> * Energy<br /> * Total Population in EmpireInfo<br /> <br /> === Borg ===<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-04T13:00:27Z <p>Reginald: </p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Borg ==<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> <br /> <br /> == F2 ==<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-04T11:39:24Z <p>Reginald: /* F1 */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Borg ==<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> == Bottom View ==<br /> <br /> various parts are filled in<br /> <br /> === PlanetsViewRegion ===<br /> <br /> * \SupremacyUI\StarSystemPanel.cs<br /> <br /> === AssignedShipListRegion ===<br /> <br /> * AssignedShipListRegion<br /> <br /> === PART_ChatPanel ===<br /> <br /> * PART_ChatPanel<br /> <br /> == F2 ==<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=UI UI 2020-10-04T09:57:23Z <p>Reginald: /* F1 */</p> <hr /> <div>== Intro ==<br /> <br /> some words to UI....<br /> <br /> * starting a game starts every of the five screens at the same time ! (Map/System/...)<br /> <br /> * inside the screens it is mostly jumping to the last selected tab (e.g. System: Production or Shipbuilding)<br /> ** these complete screens are done by different parts:<br /> ***left top: Template like SystemInfo<br /> ***left bottom: Template like BuildQueue<br /> ***right: ProductionScreen<br /> ***right bottom: Planets...<br /> <br /> <br /> == Borg ==<br /> <br /> *LCARS_GreenTextBrush<br /> <br /> *DarkGreen<br /> <br /> == ClientApp ==<br /> <br /> * SupremacyClient\ClientApp.xaml.cs - this is the main app - starting at &quot;EntryPoint&quot;<br /> * SupremacyClient\ClientWindow.xaml.cs - this is the main window<br /> <br /> == MultiplayerSetupScreen ==<br /> <br /> * MultiplayerSetupScreen.xaml + MultiplayerSetupScreen.xaml.cs<br /> <br /> == SUMMARY ==<br /> <br /> * SitRepEntry.cs<br /> <br /> == F1 ==<br /> <br /> * GalaxyScreenView.xaml (Race specific)<br /> <br /> * Expander EmpireInfo &gt; EmpireInfoView.xaml<br /> <br /> == F2 ==<br /> <br /> == F3 ==<br /> <br /> * NewDiplomacyScreen.xaml + NewDiplomacyScreen.xaml.cs<br /> * DiplomacyScreenViewModel.cs<br /> * \SupremacyCore\Diplomacy\DiplomacyHelper.cs<br /> * DiplomatAI.cs<br /> * ForeignPowerViewModel.cs<br /> <br /> * DiplomacyMessageViewModel.cs and more<br /> <br /> <br /> * AcceptProposalVisitor.cs<br /> * RejectProposalVisitor.cs<br /> <br /> == F4 ==<br /> <br /> == F5 ==<br /> <br /> * AssetsScreen.xaml + AssetsScreen.xaml.cs<br /> ** TAB: Colonies -&gt; a) Headline directly in AssetsScreen.xaml<br /> ** TAB: Colonies -&gt; b) ColonyList =&quot;{Binding Path=Colonies} -&gt; SystemListItem.xaml (+.cs)<br /> *<br /> ** TAB: SpyReport -&gt; b) <br /> <br /> * AssetsScreenPresentationModel.cs<br /> <br /> <br /> * ActiveAgreementViewModel.cs<br /> <br /> == F11 ==<br /> <br /> * File:CheatMenu.xaml + File:CheatMenu.xaml.cs<br /> <br /> == CTRL+F11 ==<br /> <br /> * FakeDialog.xaml + FakeDialog.xaml.cs<br /> <br /> == ClientSettings ==<br /> <br /> * ClientSettings.cs - stuff is written into file &gt; ClientSettings.xaml<br /> <br /> === CTRL+O ===<br /> <br /> * ClientOptionsDialog.xaml + ClientOptionsDialog.xaml.cs<br /> <br /> ==== File:ClientOptionsDialog.xaml ====<br /> <br /> * File:ClientOptionsDialog.xaml<br /> <br /> === CTRL+Z ===<br /> <br /> * ClientTracesDialog.xaml + ClientTracesDialog.xaml.cs<br /> <br /> ==== File:TracesOptionsPage.xaml ====<br /> <br /> * File:TracesOptionsPage.xaml + File:TracesOptionsPage.xaml.cs<br /> <br /> == GameOptionsPanel ==<br /> <br /> at Starting<br /> <br /> * GameOptionsPanel.xaml + GameOptionsPanel.xaml.cs<br /> <br /> == LoadGameDialog ==<br /> <br /> * LoadGameDialog.xaml.cs<br /> <br /> * SavedGameHeader.cs ( Header checks the save game version if the file is compatible)<br /> <br /> == Files ==<br /> <br /> * ClientSettings.xaml<br /> <br /> == Important Code Files ==<br /> <br /> * ClientModule.cs ... starts the App and 'ends' at StartScreen..<br /> <br /> * ClientOptions ... like Music Volume<br /> <br /> * GameEngine.cs ... start for example a SinglePlayerGame or MultiPlayerGame<br /> ** Do....<br /> <br /> * GameOptions like GalaxySize<br /> <br /> * SupremacyCore\Game\CivilizationManager.cs ... handling Empires and other Civilizations<br /> <br /> === Sector ===<br /> ** contains a System, Nebulas are also a System<br /> ** a system might contain a Colony (which is a inhabitanted system)<br /> ** a colony might have Planets (and them moons)<br /> <br /> * Colony.cs ... doing stuff for a single Colony<br /> <br /> === Civilization ===<br /> <br /> * CivilizationManager.cs &gt; contains the civilizations (current credits and more)<br /> * Civilization.cs &gt; only stuff from Civilization.xaml like Name<br /> <br /> === SAVELOAD ===<br /> <br /> * SavedGameHeader.cs = Header (Name of saved file, version nummer (!!) and more)<br /> * SavedGameManager.cs = saving Game</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2020-10-03T11:59:35Z <p>Reginald: /* en.txt */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === Visual C++ Library ===<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ==== SupremacyNative ====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML example: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * string _text = String.Format(ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;),parameter1, parameter2;<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> GameLog.Client.GameData.DebugFormat(&quot;Civilization.cs: isBorgPlayable={0}, _throwOutRace={1}, _civType before: {2}&quot;, isBorgPlayable, _throwOutRace, _civType);<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2020-10-03T11:59:22Z <p>Reginald: /* en.txt */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === Visual C++ Library ===<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ==== SupremacyNative ====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML expample: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * string _text = String.Format(ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;),parameter1, parameter2;<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> GameLog.Client.GameData.DebugFormat(&quot;Civilization.cs: isBorgPlayable={0}, _throwOutRace={1}, _civType before: {2}&quot;, isBorgPlayable, _throwOutRace, _civType);<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2020-10-03T11:39:15Z <p>Reginald: /* en.txt */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === Visual C++ Library ===<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ==== SupremacyNative ====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML expample: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * String.Format(ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;),parameter1, parameter2;<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> GameLog.Client.GameData.DebugFormat(&quot;Civilization.cs: isBorgPlayable={0}, _throwOutRace={1}, _civType before: {2}&quot;, isBorgPlayable, _throwOutRace, _civType);<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2020-10-03T11:33:31Z <p>Reginald: /* Contexts */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === Visual C++ Library ===<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ==== SupremacyNative ====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == Text ==<br /> === en.txt ===<br /> * XAML expample: Text=&quot;{s:StringResource EMPIRES_HEADER}&quot;<br /> * ResourceManager.GetString(&quot;KEY_IN-EN_TXT&quot;,parameter);<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> GameLog.Client.GameData.DebugFormat(&quot;Civilization.cs: isBorgPlayable={0}, _throwOutRace={1}, _civType before: {2}&quot;, isBorgPlayable, _throwOutRace, _civType);<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald http://botf2.square7.ch/wiki/index.php?title=System_Requirements System Requirements 2020-09-06T06:36:05Z <p>Reginald: </p> <hr /> <div><br /> <br /> &lt;span style=&quot;color:red&quot;&gt;Check your installed programs: just press Win-Key+R and input &quot;appwiz.cpl&quot; + ENTER.&lt;/span&gt;<br /> <br /> Check:<br /> *Microsoft .NET Framework 4.6.2 http://www.microsoft.com/de-de/download/details.aspx?id=40779 - also update to latest Win10 version<br /> *Microsoft Visual C++ 2008 Redistributable (1,7 MB) &lt;span style=&quot;color:red&quot;&gt;(needed !)&lt;/span&gt;<br /> *Microsoft Visual C++ 2010 Redistributable (5 MB) https://support.microsoft.com/de-de/help/2977003/the-latest-supported-visual-c-downloads<br /> *Microsoft XNA Framework (7 MB)<br /> <br /> <br /> The currently requirements are:<br /> <br /> *'''&lt;span style=&quot;color:red&quot;&gt;Microsoft .NET Framework 4.6.2 Extended ([http://en.wikipedia.org/wiki/.NET_Framework Wikipedia]) -&gt; manual installing is necessary -&gt;&lt;/span&gt;''' [http://botf2.square7.ch/wiki/index.php?title=Problem#check_your_.Net-Version Check and download here]<br /> <br /> <br /> Summary: any usual Windows PC<br /> *Intel Core Processor (not to old)<br /> *512mb RAM<br /> *[[Windows]] (tm): Windows XP up to Windows 8.1 (if you have problems, just see [[Problem#Windows problem]])<br /> *DirectX 9-compatible video card with Pixel Shader 2.0+ and Vertex Shader 1.1+ support<br /> *Desktop resolution of at least 1024x768 (1280x768 or higher is strongly recommended)<br /> *[[DirectX]] 9 or greater<br /> ----<br /> Due to other programs also use the next parts the game requires (e.g. Zone Alarm free: Microsoft .NET Redistributable, Microsoft VC++ Redistributable (x86) http://www.windowsuninstaller.org/forums/viewtopic.php?f=8&amp;t=743#p1158) some might be already installed on your PC. This might be the reason why some persons can ran Supremacy without great installing all the requirements, and others have to install all the stuff.<br /> ----<br /> &lt;span style=&quot;color:red&quot;&gt;Many reports are on missing XNA.&lt;/span&gt; Just mention this requirement:<br /> *Microsoft XNA Framework v3.1 Redistributable http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> Without it, the game isn't able to load the 3d models that you can see in the shipyard, resulting in crashes.<br /> <br /> ----<br /> <br /> If BotF2 still not runs then...<br /> <br /> Lloyd James wrote: To run BotF2, you need ALL of the following installed:<br /> *Microsoft .NET Framework ''4.5.1'' (note: you want the full framework, not the &quot;Client Profile&quot;; after it's installed, you should see both the &quot;Client Profile&quot; and &quot;Extended Profile&quot; listed in your control panel. Also note that the latest version of .Net is 4.5, and future game versions *might* need the more recent versions) http://www.microsoft.com/de-de/download/details.aspx?id=40779<br /> *Microsoft DirectX Runtime<br /> *Microsoft XNA Framework v3.1 Redistributable http://www.microsoft.com/en-us/download/details.aspx?id=15163, v4.0 might also work http://www.microsoft.com/en-us/download/details.aspx?id=20914<br /> *Microsoft Visual C++ 2008 Redistributable (1,7 MB) &lt;span style=&quot;color:red&quot;&gt;(needed !)&lt;/span&gt;<br /> *Microsoft Visual C++ 2010 Redistributable (5 MB)<br /> <br /> All of these can be found via Google. Simply copy-and-paste them and select the first link that appears.</div> Reginald http://botf2.square7.ch/wiki/index.php?title=Source_Code Source Code 2020-09-05T15:13:12Z <p>Reginald: /* VS2019 */</p> <hr /> <div>== Source Code ==<br /> <br /> http://guganeshan.com/blog/setting-up-git-and-tortoisegit-with-bitbucket-step-by-step.html<br /> <br /> === official ===<br /> <br /> * code is now at https://github.com/BotF2/BotF2.git<br /> <br /> <br /> *last source code https://bitbucket.org/mstrobel/supremacy/overview (it's in C#, also named CSharp. [[#Visual Studio]] is used for coding.)<br /> **Mike's Post: build in [http://www.microsoft.com/downloads/dlx/en-us/ThankYou.aspx?FamilyID=75568AA6-8107-475D-948A-EF22627E57A5 VS2010] with .NET 4.0. You may need the [http://en.csharp-online.net/Download_Free_Microsoft_Visual_CSharp_.NET#Download_Microsoft_Visual_Studio_Async_Community_Technology_Preview_.28CTP.29 C# Async CTP]. http://bote2.square7.ch/forum/viewtopic.php?p=70790#p70790<br /> **http://bote2.square7.ch/forum/viewtopic.php?p=70781#p70781 <br /> *** Supremacy.Game.GameEngine is where you'll find most of the game logic. That's where most of the turn processing happens.<br /> *** The SupremacyCore project is where you'll find the foundation of the game. <br /> *** SupremacyService is just the game server (all the important bits it interacts with are in SupremacyCore). <br /> *** SupremacyClientComponents is UI infrastructure. <br /> *** SupremacyUI and SupremacyWPF are older UI infrastructure stuff, much of which has been phased out and replaced by newer and better stuff in SupremacyClientComponents. The most interesting stuff in SupremacyUI is GalaxyGridPanel, which draws the galactic map. It also has the spinning planet views. <br /> *** Supremacy.Xna is where the XNA/3D stuff is located--it's not used heavily yet, but it has some effects for the invasion screen, a newer star renderer, a 3D spinning ship renderer, etc. <br /> *** Supremacy.Scripting is an expression language parser/compiler. <br /> *** SupremacyClient is the main graphical client and has most of the game screen implementations.<br /> <br /> *old source code can be taken from here: http://supremacy.codeplex.com/ (last upload from MStrobel at 03.01.2011)<br /> <br /> ==== ClientContext vs AppContext ====<br /> <br /> taken from https://bitbucket.org/kflanagan/supremacydev/commits/0d562ce676425cd5da19cfdbcf1b6c18c7d0d135<br /> <br /> *IClientContext is used by SupremacyCore to interface clients participating on a game, both local and over network. The IClientContext further includes an interface to IGameContext which gives access to the game data itself inside the '''SupremacyClient app''' <br /> *However there should be an option to also include local properties not known to the Core, which is why this is done alternatively another context would have to be introduced for local data, but then still all the client code would have to be updated to make use of it<br /> <br /> <br /> ==== .XAML files ====<br /> <br /> In Windows Presentation Foundation (WPF), a windows app framework used by Supremacy, XAML forms a user interface markup language to define UI elements, data binding, events, and other features.<br /> <br /> Info resources:<br /> <br /> *MS Article: [https://msdn.microsoft.com/en-us/library/ms745683(v=vs.110).aspx XAML Styling and Templating]<br /> <br /> *Youtube video: [https://www.youtube.com/watch?v=0qE5hyuU9hE Introduction to XAML] (26min)<br /> <br /> == Bitbucket ==<br /> <br /> *https://confluence.atlassian.com/display/BITBUCKET/Maintaining+a+Mercurial+Repository<br /> <br /> == Changes ==<br /> <br /> see [[ChangeLog|here]] or https://bitbucket.org/mstrobel/supremacy/commits/branch/default<br /> <br /> === 2016 ===<br /> <br /> ==== XAML ====<br /> <br /> *January 2016 [Planned]: Hope to get Major Race specific UI build through use of generic XAML files.<br /> * ClientApp.xaml.cs has the code to direct UI to race specific folders of xaml files in SupremacyClient/themes/{0}<br /> <br /> Looking at SystemScreen.xaml, Global.xaml and ClientModules.cs in Themes/SupremacyClient <br /> See also generic.xaml in SupremacyClientComponents/Themes/InfoCard Theme.xaml Default.xaml Icons.xaml ClientApp.xaml.cs SystemScreen.xaml<br /> <br /> <br /> 1/17/16: Found that Mikes code in ClientApp.xaml.cs will already select for Major race. Need new folders for each major race in SupremacyClient/themes/(major race), edit paths to Resources in the .xaml files found in each races set of .xaml files. File names in SupremacyClient/themes/(major race) are not unique but content in Resources is. Now you can edit files in Resources for unique UI.<br /> <br /> 2/13/16: <br /> <br /> &lt;Polygon<br /> Points=&quot;300,200 400,125 400,275 300,200&quot;<br /> Stroke=&quot;Purple&quot;<br /> StrokeThickness=&quot;2&quot;&gt;<br /> &lt;Polygon.Fill&gt;<br /> &lt;SolidColorBrush Color=&quot;Blue&quot; Opacity=&quot;0.4&quot;/&gt;<br /> &lt;/Polygon.Fill&gt;<br /> &lt;/Polygon&gt; <br /> <br /> Makes a left pointing triangle, purple outline and blue body<br /> <br /> === 2015 ===<br /> <br /> *'''Animation.cs''' (animation of opening screen): This is where we can set the number of images, frames, and the rate they play at, currently all images in 30 seconds. We may want that to run faster. The images you will make for the ship de-cloaking will be located in Resources / Images / Animation.<br /> * \supremacyclient\'''ClientModule.cs''': <br /> **Found a place to add the right mouse click instructions for the Panel Access Menu. A thing called the statusWindow held the text &quot;loading&quot; while you wait for a game to load. Added the information there for new players<br /> <br /> *FMOD is partly replace by AudioEngine.cs and others - just find it out<br /> <br /> === 2014 ===<br /> <br /> == some code ==<br /> <br /> for Theme and UI see &gt;&gt; '''[[Theme]]'''<br /> <br /> === miscellaneous ===<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs<br /> <br /> *\Mainline\SupremacyUI\SystemProductionPanel.cs<br /> <br /> *\Mainline\SupremacyCore\Orbitals\FleetOrders.cs -&gt; all items inside a sector<br /> <br /> *Mainline\SupremacyClient\GameContextMenu.cs (Access Popup Menu - or use F1 to F5)<br /> <br /> *\Mainline\SupremacyClientComponents\Controls\InfoCard\InfoCard.cs (-&gt; Tooltips ??)<br /> **\Mainline\SupremacyClient\themes\Federation\InfoCard.xaml -&gt; &lt;Setter Property=&quot;Width&quot; Value=&quot;500&quot; /&gt; (BEFORE: 250)<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyPlanetaryBuildQueueView.xaml - Colonies Screen Content<br /> <br /> *\Mainline\SupremacyCore\Universe\Colony.cs<br /> *\Mainline\SupremacyClient\Views\ColonyScreen\ColonyStructureListView.xaml<br /> **Size of this area: 720 x 240<br /> <br /> <br /> *\Mainline\SupremacyClient\Views\GalaxyScreen\TaskForceListView.xaml<br /> <br /> === Version Number ===<br /> <br /> Look for version number control in AssemblyInfo.cs<br /> <br /> your hard disk code folder BotF2\SupremacyClient\Properties\AssemblyInfo.cs<br /> <br /> ---<br /> example code: (put in your current star date)<br /> <br /> *[assembly: AssemblyVersion(&quot;2018.11.20.0&quot;)]<br /> *[assembly: AssemblyFileVersion(&quot;2018.11.20.0&quot;)]<br /> <br /> === Ships ===<br /> <br /> *\Fleets.cs<br /> *\FleetOrder.cs (without a &quot;s&quot; - beware of it)<br /> *\FleetOrders.cs<br /> <br /> *\mainline\supremacyclientcomponents\views\galaxyscreen\galaxyscreenpresenter.cs TaskForcesList<br /> <br /> <br /> ==== Building Ships ====<br /> <br /> *Cancelling -&gt; Breakpoint at Line 185 at OnShipyardBuildProjectsChanged() \Mainline\SupremacyClientComponents\Views\ColonyScreen\ColonyScreenPresentationModel.cs<br /> <br /> === Sounds ===<br /> <br /> *\Mainline\SupremacyClient\AudioEngine.cs (for Music), for Sounds &gt;&gt; SoundPlayerAction is used (search for \Resources\UI\Federation\SoundsButtonClick.wav) <br /> *and in \Mainline\SupremacyClientComponents\Views\SystemAssaultScreen\SystemAssaultScreenViewModel.cs -&gt; Uri is used (e.g. CombatLaser.wav)<br /> <br /> <br /> === Galaxy Generator ===<br /> <br /> *\Mainline\SupremacyCore\Universe\GalaxyGenerator.cs<br /> <br /> <br /> === Values ===<br /> *CivID: 0 = Federation...<br /> <br /> === TurnPhase ===<br /> <br /> WaitOnPlayers = 0,<br /> PreTurnOperations,<br /> ResetObjects,<br /> FleetMovement,<br /> Combat,<br /> PopulationGrowth,<br /> PersonnelTraining,<br /> Research,<br /> Scrapping,<br /> Maintenance,<br /> ShipProduction,<br /> Production,<br /> Trade,<br /> Morale,<br /> MapUpdates,<br /> PostTurnOperations,<br /> SendUpdates,<br /> Diplomacy,<br /> WaitOnAIPlayers<br /> <br /> === older list === <br /> <br /> {|class=&quot;wikitable sortable&quot; <br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |where<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Folder<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |File<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Function<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Date<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Description<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom1<br /> ! bgcolor=&quot;#dadada&quot; style=&quot;border:4px solid #999999;padding:0.2em;padding-top:0.2em;&quot; |Custom2<br /> <br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameContext.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> initialising game<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> Raw Materials, Deuterium, Dilithium is collected cross over all colonies and used by all colonies<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Game<br /> |style=text-align:center|GameEngine.cs<br /> |style=text-align:center|DoShipProduction(GameContext game)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> <br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Combat<br /> |style=text-align:center|InvasionArena.cs<br /> |style=text-align:center|<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> SystemAssault<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Orbital<br /> |style=text-align:center|Shipyard.cs<br /> |style=text-align:center|GetBuildOutput(int slot)<br /> |style=text-align:center| [https://bitbucket.org/Bloodwurm/BotF2dev/commits/1aafc8f6e47e9e3b9c20de79f2d02f197c023d63 2014-01-15]<br /> |style=text-align:left|<br /> just selects output (active?) and bonus (BonusType.PercentShipBuilding), since 2014-01-15 also case PopulationRatio or IndustryRatio<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|GetProductionOutput(ProductionCategory category)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> see last line, too !<br /> *Food: minimum 10<br /> *Research: <br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *Industry: '''minimum 10 !'''<br /> float moraleMod = _morale.CurrentValue / (0.5f * MoraleHelper.MaxValue);<br /> baseOutput = (int)(moraleMod * baseOutput);<br /> *last line: return ((int)(baseOutput + (baseOutput * modifier.Efficiency)) + modifier.Bonus);<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasFoodBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasFoodBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-Core<br /> |style=text-align:center|Universe<br /> |style=text-align:center|Colony.cs<br /> |style=text-align:center|planet.HasEnergyBonus (OutputModifier)<br /> |style=text-align:center| <br /> |style=text-align:left|<br /> if (planet.HasEnergyBonus)<br /> modifier.Efficiency += 0.15f;<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |- <br /> |style=text-align:left|S-ClientComp<br /> |style=text-align:center|Views\GalaxyScreen<br /> |style=text-align:center|GalaxyScreenView.cs<br /> |style=text-align:center|GalaxyScreenView()<br /> |style=text-align:center| <br /> |style=text-align:left|GalaxyView Hotkeys Definition (see [[Hotkey]]s)<br /> |style=text-align:left|<br /> |style=text-align:left|<br /> <br /> |}<br /> <br /> == Botf2-coding-practice ==<br /> <br /> *http://star-trek-supremacy.proboards.com/thread/349/botf2-coding-practice (intern)<br /> <br /> <br /> *prepare:<br /> **...we are using SourceTree, provided by bitbucket (another option: TortoiseHg with Mercurial - to access the supremacy code repository http://tortoisehg.bitbucket.org/)<br /> **PuTTYgen - to generate a ssh key to allow using ssh protocol instead of slow https http://www.chiark.greenend.org.uk/~sgtatham/putty/download.html<br /> ***or use C:\Program Files (x86)\Atlassian\SourceTree\tools\putty..puttygen.exe....generate a key (using a phrase is not neccessary)<br /> ***copy the public key (4-5 lines) into your bitbucket account/profile under SSH Keys, label it with any title and CopyPaste<br /> **we are using Visual Studio Community 2013 Update 4 (select the Community Version) https://www.visualstudio.com/en-us/downloads/download-visual-studio-vs.aspx<br /> **we are not(!) using Visual Studio Community 2015 RC - to compile the code (ISO is recommend)....still need to check if Supremacy code compiles with it, so instead we might need to depend on VS2013 http://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs....for VS 2015 we read to create a new project, import Supremacy and go through all the issues<br /> **you also need to have an account on http://bitbucket.org<br /> **and you should have Skype installed to participate in the meetings we have <br /> <br /> *when you attempt to clone by ssh instead of https, check the following tutorial: http://confluence.atlassian.com/display/BITBUCKET/Set+up+SSH+for+Mercurial<br /> <br /> <br /> *here some simple text editors useful to edit stuff like xml files, just pick the one you prefer they all are great:<br /> **http://www.sublimetext.com/<br /> **http://www.contexteditor.org/index.php<br /> **http://notepad-plus-plus.org/ (used by reg atm)<br /> <br /> == SourceTree ==<br /> <br /> *Download &gt;&gt; https://www.sourcetreeapp.com/?v=win (or while cloning...use the link below blue Clone Button)<br /> <br /> *Tools: 3rd point: OPTIONS<br /> <br /> *SSH Client Configuration:<br /> **SSH Key: c:\....\ReginaldPutty.ppk<br /> **SSH Client: (IMPORTANT) PuTTY/Link (not SSH !!)<br /> **automatically start: yes<br /> <br /> == Visual Studio ==<br /> <br /> It's possible (and standard) to compile the game with Visual Studio. No further stuff of programs is needed, except matching Resources folder. Mention that the compiled exe is then in \Mainline\bin\Debug (or \Release).<br /> <br /> === Visual C++ Library ===<br /> <br /> IMPORTANT: As Microsoft no longer provides Visual C++ Library as standard installed component ...don't forget to select or install this manually! In VS you can recognize it if \Supremacy Native is unload (sign is greyed out a little bit)<br /> <br /> ==== SupremacyNative ====<br /> <br /> SupremacyNative is C++ coded. Sometimes there are some problems with it https://developercommunity.visualstudio.com/content/problem/312852/internal-compiler-error-in-vs158-msc1cpp-line-1518.html<br /> <br /> === VS2019 ===<br /> <br /> * meanwhile we are on VS 2019 Community version https://www.visualstudio.com/downloads<br /> <br /> === VS2017 ===<br /> <br /> In May 2017 we're trying to change to VS 2017 Community version https://www.visualstudio.com/downloads <br /> <br /> *you might want to change language at TOOLS &gt; OPTIONS &gt; ENVIROMENT &gt; INTERNATIONAL SETTINGS <br /> <br /> * first make a clean !!, maybe for each single project (10 of 10)<br /> <br /> * SOLUTION EXPLORER - right mouse click - retarget (in the middle) - select newest versions<br /> <br /> * (this should be only needed once and should be uploaded to Repository by one guy) SupremacyClient &gt; Set as start Project<br /> <br /> *after cleaning maybe use REBUILD<br /> <br /> for more see &gt;&gt; [[#Tools|here]]<br /> <br /> === VS2015 ===<br /> <br /> since April 2016 we're using VS 2015<br /> <br /> *Visual Studio '''Community''' 2015 RC - to compile the code (ISO is recommend) ... still need to check if Supremacy code compiles with it, so instead we might need VS2013. NEW: we try to go to VS 2015 now. <br /> https://www.visualstudio.com/downloads/visual-studio-2015-downloads-vs - you need the &quot;Community&quot; Version, currently (Apr 2016) version &quot;Update 2&quot;<br /> <br /> <br /> ==== VS 2015 Update 3 ====<br /> <br /> *says it does uninstall Update 2<br /> *needs update to 33 GB to install (only if every is selected) - seems to need some hours...<br /> <br /> === old VS ===<br /> <br /> *Visual Studio Community 2013 (Community version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2012 (Express version is free) http://www.visualstudio.com/downloads/download-visual-studio-vs#d-express-windows-desktop<br /> *Visual Studio Express 2008 (German) http://www.microsoft.com/de-de/download/details.aspx?id=13276<br /> <br /> === Tools ===<br /> <br /> *Indent Guides https://visualstudiogallery.msdn.microsoft.com/e792686d-542b-474a-8c55-630980e72c30 Adds vertical lines at each indent level.<br /> <br /> * Vertical tabs https://marketplace.visualstudio.com/items?itemName=VisualStudioProductTeam.ProductivityPowerPack2017<br /> <br /> *PowerShell Tools für VS 2015<br /> <br /> === Tips ===<br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; Color theme -&gt; Black<br /> <br /> *TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Detect when file is changed outside... -&gt; Yes<br /> **TOOLS &gt; OPTIONS &gt; ENVIRONMENT &gt; DOCUMENTS &gt; Reload modified files... -&gt; Yes<br /> <br /> *DEBUG &gt; OPTIONS &gt; PROJECTS... &gt; BUILD AND RUN &gt; when code=project is changed=&quot;out of date&quot; &gt; &quot;Always Build&quot; (checkbox &quot;only build ...on Run&quot; is marked)<br /> **https://www.vb-paradise.de/index.php/Thread/47935-Code-bei-Klick-auf-Debugging-starten-kompilieren-wenn-er-sich-ge%C3%A4ndert-hat/<br /> <br /> *TOOLS &gt; OPTIONS &gt; TEXT EDITOR &gt; ALL LANGUAGES &gt; Line Number (activate for all)<br /> <br /> *DEBUG &gt; SUPREMACY CLIENT PROPERTIES (last) &gt; DEBUG &gt; Start project &gt; Command line arguments: &quot;-aiexplore -SAVEDGAME:auto&quot; (if you save in Supremacy manually a game with name &quot;auto&quot; (independent from game's &quot;(autosave)&quot;, this manually saved game can be loaded at startup. <br /> **&quot;-aiexplore&quot; isn't necessary. For more see [[Command line parameter]]<br /> **if working for example on Cardassian UI just save Cardassian as &quot;auto&quot;. <br /> **when you want to change to Klingons, just retire and start Klingons. If you want to work steady on Klingons, save a Klingon's game with auto. <br /> **if you want to start a new game steady, just go Command line arguments (see above) and change the filename to an unused one like &quot;-SAVEDGAME:auto123&quot;<br /> <br /> *activate Toolbar BUILD by right mouse click on Toolbar line<br /> <br /> * Tools -&gt; Options -&gt; Debugging -&gt; Output Window -&gt; Module Load Messages -&gt; Off<br /> <br /> ==== Editor ====<br /> we're using some different editors<br /> *one option is to drag'n'drop files like xml to Visual Studio<br /> *sometimes we use Notepad++ https://notepad-plus-plus.org/download with Extension Compare (PLUGINS &gt; PLUGIN MANAGER &gt; SHOW P-Manager &gt; &quot;Compare&quot; ...install<br /> *for a black style we use Sublime http://www.sublimetext.com/2<br /> <br /> ==== Screenshot ====<br /> <br /> *reg likes Greenshot http://getgreenshot.org/ <br /> **puts an icon into task bar. There: &gt; PREFERENCES<br /> ***PREFERENCES &gt; GENERAL: reg uses for &quot;Capture region&quot; CRTL+PRNT (and no other hotkey)<br /> ***PREFERENCES &gt; OUTPUT: define a folder at &quot;Storage location&quot; and a standard file type (default is *.png)<br /> ***PREFERENCES &gt; DESTINATION: (reg's settings)<br /> ****- turn off &quot;Select destination dymnamically&quot;<br /> ****- open in image editor<br /> ****- copy to clipboard<br /> **Usage:<br /> ***press Hotkey and make Screenshot<br /> ***paste immediately anywhere OR<br /> ***work on it inside Greenshot (give red circles or mark up in any colour), give numbers, obfuscate and more<br /> ***save or save as jpg or print<br /> <br /> == Compiling ==<br /> <br /> if you have an error with &quot;Glyphs.xaml&quot;, than make sure you have copied \Resources MANUALLY into the output folders - this was changed in 2015. The output folder depends on compiling method &quot;Debug&quot; or &quot;Release&quot;, it is<br /> *for DEBUG _: (YourRepositoryFolder)\Mainline\bin\'''Debug\Resources''' or<br /> *for RELEASE: (YourRepositoryFolder)\Mainline\bin\'''Release\Resources'''<br /> <br /> it's creating:<br /> *1&gt; Supremacy.Scripting -&gt; %path_repo%\bin\Debug\lib\Supremacy.Scripting.dll<br /> *2&gt; SupremacyCore -&gt; %path_repo%\bin\Debug\lib\SupremacyCore.dll<br /> *3&gt; Supremacy.Xna -&gt; %path_repo%\bin\Debug\lib\Supremacy.Xna.dll<br /> *4&gt; SupremacyClientComponents -&gt; %path_repo%\bin\Debug\lib\SupremacyClientComponents.dll<br /> *5&gt; SupremacyWPF -&gt; %path_repo%\bin\Debug\lib\SupremacyWPF.dll<br /> *6&gt; SupremacyService -&gt; %path_repo%\bin\Debug\lib\SupremacyService.dll<br /> *7&gt; SupremacyUI -&gt; %path_repo%\bin\Debug\lib\SupremacyUI.dll<br /> <br /> == Visual C# ==<br /> <br /> build in Visual Studio<br /> <br /> &lt;img&gt;http://botf2.square7.ch/wiki-files/images/VS2015.jpg&lt;/img&gt;<br /> <br /> == SunBurn ==<br /> <br /> SunBurn is on hold for now. Kenneth was working sometimes with SunBurn...this might be a site for this http://channel9.msdn.com/coding4fun/blog/No-need-for-sunscreen-you-want-this-SunBurn-SunBurn-v2-RTMs-including-the-free-SunBurn-Framework-Edi<br /> <br /> *http://en.wikipedia.org/wiki/List_of_game_engines<br /> <br /> == .Net ==<br /> <br /> you should use latest [http://www.microsoft.com/net .Net-version] (2014: version 4.5.1)<br /> <br /> == XNA ==<br /> <br /> &quot;Could not load file or assembly 'Microsoft.Xna.Framework.dll' or one of its dependencies. The specified module could not be found.&quot;<br /> <br /> *suggestion by reg: go to \Resources\Models and rename the &quot;Models&quot;-folder to &quot;Models-SetOffline&quot; or something else (if building a ship no model is shown -as it is to most of the ships- but otherwise the game could work fine)<br /> <br /> <br /> This suggests the problem is with your XNA installation. The game uses XNA to display the 3D ship models in the shipyard. There's no way to disable the models so XNA wouldn't be needed. So to be able to play the game, i'd advise to uninstall XNA, then install the latest version. <br /> <br /> XNA 3.1 (this one you need in any case): http://www.microsoft.com/en-us/download/details.aspx?id=15163<br /> <br /> XNA 4.0 Download link: http://www.microsoft.com/en-gb/download/details.aspx?id=20914<br /> <br /> == Try ==<br /> <br /> (for boolean)<br /> <br /> try<br /> {<br /> return true;<br /> }<br /> catch (Exception e)<br /> {<br /> var errors = new System.Collections.Concurrent.ConcurrentStack&lt;Exception&gt;();<br /> errors.Push(e);<br /> return false;<br /> }<br /> finally<br /> {<br /> xxx;<br /> }<br /> ;<br /> <br /> == Contexts ==<br /> <br /> *AppContext (programm running)<br /> *GameContext.Current (Game started - so after StartScreen)<br /> *PlayerContext.Current<br /> <br /> == LocalPlayer ==<br /> <br /> *AppContext.LocalPlayer (just inside XAML-code files ??)<br /> <br /> == Civilization ==<br /> <br /> just the data out of Civilization.xml ... for more see [[#CivilizationManager]]<br /> <br /> == CivilizationManager ==<br /> <br /> CivilizationManager holds all the data like amount of credits, diplomacy, sitreps and more<br /> <br /> *GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> GameContext.Current.CivilizationManagers[LocalPlayer.EmpireID]<br /> <br /> == GameLog ==<br /> <br /> GameLog.Client.GameData.DebugFormat(&quot;Civilization.cs: isBorgPlayable={0}, _throwOutRace={1}, _civType before: {2}&quot;, isBorgPlayable, _throwOutRace, _civType);<br /> <br /> == MessageBox (Windows Style) ==<br /> <br /> MessageBox.Show(&quot;Borg turned into Expanded&quot;, &quot;WARNING&quot;, MessageBoxButton.OK);<br /> <br /> == MessageDialog (Supremacy Style) ==<br /> <br /> var result = MessageDialog.Show(&quot;Borg turned into Expanded&quot;, MessageDialogButtons.YesNo);<br /> <br /> == SoundPlaying ==<br /> <br /> * _soundPlayer.PlayFile(&quot;Resources/SoundFX/ChatMessage.wav&quot;);</div> Reginald
Warning: Cannot modify header information - headers already sent by (output started at /users/botf2/www/wiki/LocalSettings.php:152) in /users/botf2/www/wiki/includes/WebResponse.php on line 38