Skip to content

Commit b94b51e

Browse files
author
prome
committedFeb 20, 2021
ARKMod.net version
Removed some unnecessary code. Removed Pennys easter eggs. Added functions for printing engrams and tamed creatures. Edited how the output is displayed.
1 parent f2e1660 commit b94b51e

7 files changed

+83
-43
lines changed
 

‎ARKModnetLogo.ico

122 KB
Binary file not shown.

‎ASCG.ico

-264 KB
Binary file not shown.

‎App.config

+3-3
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8" ?>
22
<configuration>
3-
<startup>
4-
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1" />
5-
</startup>
3+
<startup>
4+
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.6.1" />
5+
</startup>
66
</configuration>

‎Program.cs

+47-21
Original file line numberDiff line numberDiff line change
@@ -8,19 +8,7 @@ class Program
88
{
99
static void Main(string[] args)
1010
{
11-
foreach (var arg in args)
12-
{
13-
if (arg == "-cheese")
14-
{
15-
Console.WriteLine("Fuck you cheese you little shitheel!");
16-
Console.ReadKey();
17-
}
18-
if (arg == "-Kane")
19-
{
20-
Console.WriteLine("You know you love me kane! Dont try to hide it!!!!!");
21-
Console.ReadKey();
22-
}
23-
}
11+
2412
string[] files = Directory.GetFiles(Directory.GetCurrentDirectory());
2513
int amtFiles = files.Length;
2614
int fileCount = 0;
@@ -50,11 +38,30 @@ bool isArkModFolder()
5038

5139
void MakeSpawnCodes()
5240
{
53-
string itemsHeader = "---------------------------------------------------------------------------------Item Spawn Codes---------------------------------------------------------------------------------";
54-
string dinoHeader = "---------------------------------------------------------------------------------Dino Spawn Codes---------------------------------------------------------------------------------";
41+
string author = "\nCode generated with ARKMod.net's ARK Code Generator. For latest version, visit https://arkmod.net/.\nHappy ARKing!";
42+
string engramsHeader = "\n---------------------------------------------------------------------------------Engram Names---------------------------------------------------------------------------------\n";
43+
string itemsHeader = "\n---------------------------------------------------------------------------------Item Spawncodes--------------------------------------------------------------------------------\n";
44+
string dinoHeader = "\n---------------------------------------------------------------------------------Creature Spawncodes-----------------------------------------------------------------------------\n";
45+
string dinoTHeader = "\n---------------------------------------------------------------------------------Tamed Creature Spawncodes-----------------------------------------------------------------------\n";
5546
var allItems = Directory.GetFiles(Directory.GetCurrentDirectory(), "*", SearchOption.AllDirectories);
56-
File.Delete("SpawnCodes.txt"); //this will wipe the text file so a clean set of codes can be re generated
57-
File.AppendAllText("SpawnCodes.txt", itemsHeader + Environment.NewLine);// this add the item header to show that everythign below is an item spawn code
47+
File.Delete("Output.txt"); //this will wipe the text file so a clean set of codes can be re generated
48+
File.AppendAllText("Output.txt", author + Environment.NewLine);
49+
File.AppendAllText("Output.txt", engramsHeader + Environment.NewLine);
50+
foreach (var item in allItems)
51+
{
52+
var filename = Path.GetFileNameWithoutExtension(item);
53+
54+
if (filename.StartsWith("EngramEntry"))
55+
{
56+
57+
var s = filename + "_C";
58+
59+
File.AppendAllText("Output.txt", s + Environment.NewLine);
60+
61+
Console.WriteLine(s);
62+
}
63+
}
64+
File.AppendAllText("Output.txt", itemsHeader + Environment.NewLine);// this add the item header to show that everythign below is an item spawn code
5865
foreach (var item in allItems)
5966
{
6067
var filename = Path.GetFileNameWithoutExtension(item);
@@ -64,12 +71,12 @@ void MakeSpawnCodes()
6471

6572
var s = @"admincheat GiveItem " + ((char)34) + "Blueprint'" + item.Substring(item.IndexOf("Content")).Replace(@"Content\", @"\Game\").Replace(".uasset", "." + filename).Replace(@"\", "/") + "'" + ((char)34) + " 1 1 0";
6673

67-
File.AppendAllText("SpawnCodes.txt", s + Environment.NewLine);
74+
File.AppendAllText("Output.txt", s + Environment.NewLine);
6875

6976
Console.WriteLine(s);
7077
}
7178
}
72-
File.AppendAllText("SpawnCodes.txt", dinoHeader + Environment.NewLine);
79+
File.AppendAllText("Output.txt", dinoHeader + Environment.NewLine);
7380
foreach (var item in allItems)
7481
{
7582
var filename = Path.GetFileNameWithoutExtension(item);
@@ -79,18 +86,37 @@ void MakeSpawnCodes()
7986

8087
var s = @"admincheat SpawnDino " + ((char)34) + "Blueprint'" + item.Substring(item.IndexOf("Content")).Replace(@"Content\", @"\Game\").Replace(".uasset", "." + filename).Replace(@"\", "/") + "'" + ((char)34) + " 500 0 0 120";
8188

82-
File.AppendAllText("SpawnCodes.txt", s + Environment.NewLine);
89+
File.AppendAllText("Output.txt", s + Environment.NewLine);
90+
91+
Console.WriteLine(s);
92+
93+
}
94+
}
95+
File.AppendAllText("Output.txt", dinoTHeader + Environment.NewLine);
96+
foreach (var item in allItems)
97+
{
98+
var filename = Path.GetFileNameWithoutExtension(item);
99+
100+
if (filename.Contains("Character_BP"))
101+
{
102+
103+
var s = @"admincheat GMSummon " + ((char)34) + filename + ((char)34) + " 120";
104+
105+
File.AppendAllText("Output.txt", s + Environment.NewLine);
106+
107+
Console.WriteLine(s);
83108

84109
}
85110
}
111+
File.AppendAllText("Output.txt", author + Environment.NewLine);
86112
}
87113
if (isArkModFolder())
88114
{
89115
MakeSpawnCodes();
90116
}
91117
else
92118
{
93-
Console.WriteLine("Come on dumb ass this isnt a valid mod folder. Next time try to put me in a folder with a valid game data bp smh.");
119+
Console.WriteLine("This folder dont have a PrimalGameData.");
94120
Console.ReadKey();
95121
}
96122
}

‎Properties/AssemblyInfo.cs

+8-7
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,16 @@
1-
using System.Reflection;
1+
using System.Reflection;
22
using System.Runtime.CompilerServices;
33
using System.Runtime.InteropServices;
44

55
// General Information about an assembly is controlled through the following
66
// set of attributes. Change these attribute values to modify the information
77
// associated with an assembly.
8-
[assembly: AssemblyTitle("ArkSpawnCodeGen")]
8+
[assembly: AssemblyTitle("ARK Spawncode Generator")]
99
[assembly: AssemblyDescription("")]
1010
[assembly: AssemblyConfiguration("")]
11-
[assembly: AssemblyCompany("Dr. Pennysworth")]
12-
[assembly: AssemblyProduct("ArkSpawnCodeGen")]
13-
[assembly: AssemblyCopyright("Copyright © 2017")]
11+
[assembly: AssemblyCompany("ARKMod.net")]
12+
[assembly: AssemblyProduct("ARK Spawncode Generator")]
13+
[assembly: AssemblyCopyright("ARKMod.net © 2021")]
1414
[assembly: AssemblyTrademark("")]
1515
[assembly: AssemblyCulture("")]
1616

@@ -19,8 +19,9 @@
1919
// COM, set the ComVisible attribute to true on that type.
2020
[assembly: ComVisible(false)]
2121

22-
// The following GUID is for the ID of the typelib if this project is exposed to COM
23-
[assembly: Guid("7e361a54-a631-4204-a1ae-8a6458edd60b")]
22+
// The following GUID is for the ID of the typelib if this project is exposed to COM.
23+
24+
[assembly: Guid("07d41b53-92de-4e50-ab41-5b12cf08c7e7")]
2425

2526
// Version information for an assembly consists of the following four values:
2627
//

‎README.md

+17-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,17 @@
1-
# SpawnCodeGenerator
2-
1+
# ARK Spawncode Generator
2+
3+
## Installation / Usage
4+
5+
A handy little tool that you place in the mods root-folder, execute the program and it'll create a text-file with all engrams, spawn codes for tamed and wild creatures, and spawn codes for all items.
6+
7+
## Contact / Donations / Sponsor
8+
[![Discord](https://i.imgur.com/DJdX8Sl.png)](https://discord.gg/RjNHWbX)
9+
10+
[![Donate](https://i.imgur.com/aZg9Uef.png)](https://www.paypal.com/cgi-bin/webscr?cmd=_s-xclick&hosted_button_id=VCWZQKLVK35J8)
11+
12+
[![Nitrado](https://i.imgur.com/UnEUi0X.png)](http://nitra.do/prome)
13+
14+
## License
15+
16+
This work is based on Anthonys(Dr_Pennysworth#3412) files.
17+
https://github.com/DrPennysworth/ArkSpawnCodeGen

‎ArkSpawnCodeGen.csproj ‎SpawnCodeGenerator.csproj

+8-10
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
<ProjectGuid>{7E361A54-A631-4204-A1AE-8A6458EDD60B}</ProjectGuid>
88
<OutputType>Exe</OutputType>
99
<RootNamespace>ArkSpawnCodeGen</RootNamespace>
10-
<AssemblyName>Ark Spawn Code Generator v1.1</AssemblyName>
10+
<AssemblyName>ARK Code Generator</AssemblyName>
1111
<TargetFrameworkVersion>v4.6.1</TargetFrameworkVersion>
1212
<FileAlignment>512</FileAlignment>
1313
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects>
@@ -47,13 +47,12 @@
4747
<WarningLevel>4</WarningLevel>
4848
</PropertyGroup>
4949
<PropertyGroup>
50-
<ApplicationIcon>ASCG.ico</ApplicationIcon>
50+
<ApplicationIcon>ARKModnetLogo.ico</ApplicationIcon>
5151
</PropertyGroup>
5252
<PropertyGroup>
5353
<SignAssembly>true</SignAssembly>
5454
</PropertyGroup>
5555
<PropertyGroup>
56-
<AssemblyOriginatorKeyFile>Dr_Pennysworths.pfx</AssemblyOriginatorKeyFile>
5756
</PropertyGroup>
5857
<ItemGroup>
5958
<Reference Include="System" />
@@ -69,13 +68,6 @@
6968
<Compile Include="Program.cs" />
7069
<Compile Include="Properties\AssemblyInfo.cs" />
7170
</ItemGroup>
72-
<ItemGroup>
73-
<None Include="App.config" />
74-
<None Include="Dr_Pennysworths.pfx" />
75-
</ItemGroup>
76-
<ItemGroup>
77-
<Content Include="ASCG.ico" />
78-
</ItemGroup>
7971
<ItemGroup>
8072
<BootstrapperPackage Include=".NETFramework,Version=v4.6.1">
8173
<Visible>False</Visible>
@@ -88,5 +80,11 @@
8880
<Install>false</Install>
8981
</BootstrapperPackage>
9082
</ItemGroup>
83+
<ItemGroup>
84+
<None Include="App.config" />
85+
</ItemGroup>
86+
<ItemGroup>
87+
<Content Include="ARKModnetLogo.ico" />
88+
</ItemGroup>
9189
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
9290
</Project>

0 commit comments

Comments
 (0)
Please sign in to comment.