Skip to content
This repository was archived by the owner on Jan 6, 2022. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -42,3 +42,4 @@ user.props
3rd/SteamSDK/release/x64
3rd/VRage.Native/debug/x64
3rd/VRage.Native/release/x64
packages
Binary file added 3rd/HavokWrapper_SE/release/x64/HavokWrapper.dll
Binary file not shown.
226 changes: 166 additions & 60 deletions Sources/Sandbox.Game/Game/Screens/MyGuiScreenScenario.cs

Large diffs are not rendered by default.

26 changes: 10 additions & 16 deletions Sources/Sandbox.Game/Game/Screens/MyGuiScreenScenarioBase.cs
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
using Sandbox.Common;
using Sandbox.Common.ObjectBuilders;
using Sandbox.Engine.Networking;
using Sandbox.Engine.Utils;
using Sandbox.Game.GameSystems;
using Sandbox.Game.Gui;
using Sandbox.Game.Localization;
using Sandbox.Engine.Utils;
using Sandbox.Game.World;
using Sandbox.Graphics.GUI;
using System;
Expand Down Expand Up @@ -36,8 +30,8 @@ protected enum StateEnum
protected MyLayoutTable m_sideMenuLayout;
protected MyLayoutTable m_buttonsLayout;

protected int m_selectedRow;
protected int m_selectedRowIndex;

protected const float MARGIN_TOP = 0.1f;
protected const float MARGIN_LEFT = 0.42f;
protected const string WORKSHOP_PATH_TAG = "workshop";
Expand Down Expand Up @@ -96,7 +90,7 @@ protected virtual void BuildControls()
m_sideMenuLayout = new MyLayoutTable(this, originL, layoutSize);
m_sideMenuLayout.SetColumnWidthsNormalized(columnWidthLabel, columnWidthControl);
m_sideMenuLayout.SetRowHeightsNormalized(rowHeight, rowHeight, rowHeight, rowHeight, rowHeight);

m_sideMenuLayout.Add(nameLabel, MyAlignH.Left, MyAlignV.Top, 0, 0);
m_sideMenuLayout.Add(m_nameTextbox, MyAlignH.Left, MyAlignV.Top, 0, 1);
m_sideMenuLayout.Add(descriptionLabel, MyAlignH.Left, MyAlignV.Top, 1, 0);
Expand Down Expand Up @@ -133,8 +127,8 @@ protected virtual void BuildControls()
{
int buttonRowCount = 2;
int buttonColumnCount = 4;
Vector2 buttonSize = new Vector2(300f / 1600f, 70f / 1200f);
Vector2 buttonsOrigin = m_size.Value / 2 - new Vector2(0.83f, 0.16f);
Vector2 buttonSize = new Vector2(320f / 1600f, 70f / 1200f);
Vector2 buttonsOrigin = m_size.Value / 2 - new Vector2(0.865f, 0.16f);
Vector2 buttonOffset = new Vector2(0.01f, 0.01f);
Vector2 buttonLayoutSize = new Vector2((buttonSize.X + buttonOffset.X) * (buttonColumnCount), (buttonSize.Y + buttonOffset.Y) * (buttonRowCount));
m_buttonsLayout = new MyLayoutTable(this, buttonsOrigin, buttonLayoutSize);
Expand Down Expand Up @@ -225,7 +219,7 @@ private void OnCancelButtonClick(object sender)

protected virtual void OnTableItemSelected(MyGuiControlTable sender, MyGuiControlTable.EventArgs eventArgs)
{
m_selectedRow = eventArgs.RowIndex;
m_selectedRowIndex = eventArgs.RowIndex;
FillRight();
}

Expand Down Expand Up @@ -322,12 +316,12 @@ protected void RefreshGameList(bool tutorials = false)
// Select row with same world ID as we had before refresh.
if (index == selectedIndex)
{
m_selectedRow = index;
m_selectedRowIndex = index;
m_scenarioTable.SelectedRow = row;
}
}

m_scenarioTable.SelectedRowIndex = m_selectedRow;
m_scenarioTable.SelectedRowIndex = m_selectedRowIndex;
m_scenarioTable.ScrollToSelection();
FillRight();
}
Expand All @@ -337,7 +331,7 @@ protected Tuple<string, MyWorldInfo> FindSave(MyGuiControlTable.Row row)
return (Tuple<string, MyWorldInfo>)(row.UserData);
}


protected virtual MyGuiHighlightTexture GetIcon(Tuple<string, MyWorldInfo> save)
{
return MyGuiConstants.TEXTURE_ICON_BLUEPRINTS_LOCAL;
Expand Down
36 changes: 18 additions & 18 deletions Sources/VRage.Network/MyRakNetConnectionException.cs
Original file line number Diff line number Diff line change
@@ -1,20 +1,20 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
//using System;
//using System.Collections.Generic;
//using System.Linq;
//using System.Text;

namespace VRage.Network
{
public class MyRakNetConnectionException : Exception
{
#if !XB1
public readonly ConnectionAttemptResultEnum ConnectionResult;
//namespace VRage.Network
//{
// public class MyRakNetConnectionException : Exception
// {
//#if !XB1
// public readonly ConnectionAttemptResultEnum ConnectionResult;

public MyRakNetConnectionException(string message, ConnectionAttemptResultEnum connectionResult, Exception innerException = null)
: base(message, innerException)
{
ConnectionResult = connectionResult;
}
#endif
}
}
// public MyRakNetConnectionException(string message, ConnectionAttemptResultEnum connectionResult, Exception innerException = null)
// : base(message, innerException)
// {
// ConnectionResult = connectionResult;
// }
//#endif
// }
//}
38 changes: 19 additions & 19 deletions Sources/VRage.Network/MyRakNetStartupException.cs
Original file line number Diff line number Diff line change
@@ -1,21 +1,21 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using VRage.Network;
//using System;
//using System.Collections.Generic;
//using System.Linq;
//using System.Text;
//using VRage.Network;

namespace VRage.Network
{
public class MyRakNetStartupException : Exception
{
#if !XB1
public readonly StartupResultEnum StartupResult;
//namespace VRage.Network
//{
// public class MyRakNetStartupException : Exception
// {
//#if !XB1
// public readonly StartupResultEnum StartupResult;

public MyRakNetStartupException(string message, StartupResultEnum startupResult, Exception innerException = null)
: base(message, innerException)
{
StartupResult = startupResult;
}
#endif
}
}
// public MyRakNetStartupException(string message, StartupResultEnum startupResult, Exception innerException = null)
// : base(message, innerException)
// {
// StartupResult = startupResult;
// }
//#endif
// }
//}
26 changes: 18 additions & 8 deletions Sources/VRage.Scripting/VRage.Scripting.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -33,20 +33,23 @@
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.CodeAnalysis">
<HintPath>..\..\3rd\Microsoft.CodeAnalysis\Microsoft.CodeAnalysis.dll</HintPath>
<Reference Include="Microsoft.CodeAnalysis, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\..\packages\Microsoft.CodeAnalysis.Common.1.2.0\lib\net45\Microsoft.CodeAnalysis.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Microsoft.CodeAnalysis.CSharp">
<HintPath>..\..\3rd\Microsoft.CodeAnalysis\Microsoft.CodeAnalysis.CSharp.dll</HintPath>
<Reference Include="Microsoft.CodeAnalysis.CSharp, Version=1.2.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
<HintPath>..\..\packages\Microsoft.CodeAnalysis.CSharp.1.2.0\lib\net45\Microsoft.CodeAnalysis.CSharp.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System" />
<Reference Include="System.Collections.Immutable, Version=1.1.37.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\3rd\Microsoft.CodeAnalysis\System.Collections.Immutable.dll</HintPath>
<HintPath>..\..\packages\System.Collections.Immutable.1.1.37\lib\dotnet\System.Collections.Immutable.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System.Core" />
<Reference Include="System.Reflection.Metadata">
<HintPath>..\..\3rd\Microsoft.CodeAnalysis\System.Reflection.Metadata.dll</HintPath>
<Reference Include="System.Reflection.Metadata, Version=1.2.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a, processorArchitecture=MSIL">
<HintPath>..\..\packages\System.Reflection.Metadata.1.2.0\lib\portable-net45+win8\System.Reflection.Metadata.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="System.Xml.Linq" />
<Reference Include="System.Data.DataSetExtensions" />
Expand Down Expand Up @@ -86,6 +89,13 @@
<ItemGroup>
<Folder Include="ModAPI\" />
</ItemGroup>
<ItemGroup>
<None Include="packages.config" />
</ItemGroup>
<ItemGroup>
<Analyzer Include="..\..\packages\Microsoft.CodeAnalysis.Analyzers.1.1.0\analyzers\dotnet\cs\Microsoft.CodeAnalysis.Analyzers.dll" />
<Analyzer Include="..\..\packages\Microsoft.CodeAnalysis.Analyzers.1.1.0\analyzers\dotnet\cs\Microsoft.CodeAnalysis.CSharp.Analyzers.dll" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
Expand Down
16 changes: 16 additions & 0 deletions Sources/VRage.Scripting/packages.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Microsoft.CodeAnalysis.Analyzers" version="1.1.0" targetFramework="net461" />
<package id="Microsoft.CodeAnalysis.Common" version="1.2.0" targetFramework="net461" />
<package id="Microsoft.CodeAnalysis.CSharp" version="1.2.0" targetFramework="net461" />
<package id="System.Collections" version="4.0.0" targetFramework="net461" />
<package id="System.Collections.Immutable" version="1.1.37" targetFramework="net461" />
<package id="System.Diagnostics.Debug" version="4.0.0" targetFramework="net461" />
<package id="System.Globalization" version="4.0.0" targetFramework="net461" />
<package id="System.Linq" version="4.0.0" targetFramework="net461" />
<package id="System.Reflection.Metadata" version="1.2.0" targetFramework="net461" />
<package id="System.Resources.ResourceManager" version="4.0.0" targetFramework="net461" />
<package id="System.Runtime" version="4.0.0" targetFramework="net461" />
<package id="System.Runtime.Extensions" version="4.0.0" targetFramework="net461" />
<package id="System.Threading" version="4.0.0" targetFramework="net461" />
</packages>
5 changes: 3 additions & 2 deletions SpaceEngineers.sln
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@

Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 2013
VisualStudioVersion = 12.0.40629.0
# Visual Studio 14
VisualStudioVersion = 14.0.25420.1
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SpaceEngineers", "Sources\SpaceEngineers\SpaceEngineers.csproj", "{5CD034C8-A242-4BD6-94F4-F20C655A69E8}"
ProjectSection(ProjectDependencies) = postProject
Expand Down Expand Up @@ -72,6 +72,7 @@ EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Configuration", "Configuration", "{BB2E2FD7-114E-441E-A282-643353F31A64}"
ProjectSection(SolutionItems) = preProject
global.props = global.props
user.props = user.props
EndProjectSection
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "VRage.Game", "Sources\VRage.Game\VRage.Game.csproj", "{4539B5F0-3316-40E6-B032-9FBCAFAAC5BE}"
Expand Down