Skip to content

Instantly share code, notes, and snippets.

View Cruxial0's full-sized avatar

Cruxial Cruxial0

  • Norway
  • 17:20 (UTC +02:00)
View GitHub Profile
@Cruxial0
Cruxial0 / NameListParser.cs
Created December 4, 2023 08:47
A basic file-specific parser used to parse baby names. Used for my latest game "Our Consequences".
using System.Diagnostics;
using System.Net;
using Microsoft.VisualBasic.FileIO;
using Newtonsoft.Json;
static void Main() {
Stopwatch sw = new Stopwatch();
sw.Start();
var url = "https://raw.githubusercontent.com/hadley/data-baby-names/master/baby-names.csv";
@Cruxial0
Cruxial0 / ResourceNode.cs
Created November 10, 2023 10:24
Workstation system
public class ResourceNode : Workstation
{
[SerializeField] private ResourceType resourceType;
[SerializeField] private float collectInterval = 30f;
[SerializeField] private int supply = 300;
private int _currSupply = 300;
protected override void Start() {
_currSupply = supply;
base.Start();