Skip to content

Instantly share code, notes, and snippets.

@tenpn
tenpn / SymbolicationEnabler.cs
Last active January 11, 2016 06:31 — forked from capyvara/gist:5230032
SymolicationEnabler unity post-processor
/*
The MIT License (MIT)
Copyright (c) 2014 Andrew Fray, Marcelo Oliveira
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
npc_fisherman_recipe:
model: npc_fisherman
needsToBeCrafted:
recipe:
- [biome2_plant_ingredient, 2]
replacedBy: npc_fisherman
isAnNPC:
clickSpeech: NPCCrafting_npc_fisherman
tree:
model: special_treasure
harvestable:
for: players
reward: coins
canBeDepletedPerPlayer:
health: 1
@tenpn
tenpn / CustomSingleContextFactory.cs
Created November 22, 2017 10:33
fixed CustomSingleContextFactory
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using TenPN.DecisionFlex;
using System;
public class CustomSingleContextFactory : SingleContextFactory
{
public override IContext SingleContext(Logging loggingSetting)
@tenpn
tenpn / execute-shell-command-on-buffer
Created April 12, 2012 14:03
emacs function to execute a shell command with the current buffer filename as an argument
;; eg when in a text file, (execute-shell-command-on-buffer "p4 edit %s") will check out the file in perforce
(defun execute-shell-command-on-buffer (shell-command-text)
(interactive "MShell command:")
(shell-command (format shell-command-text (shell-quote-argument buffer-file-name)))
)
@tenpn
tenpn / LogSeverityTracker.cs
Created September 12, 2020 19:57
Unity Test Framework provides LogAsset to validate the output of the log, but at this time it only lets you prescribe what should appear. We don't care about Debug.Log() output, but want to know if there was anything worse than that. Particularly, in our case, we'd like to fail for warnings as well as errors. Too many "benign" warnings can hide …
using UnityEngine;
using System.Collections.Generic;
using UnityEngine.TestTools;
using NUnit.Framework;
using System.Linq;
namespace Roll7
{
/// <summary>
/// This tracker will assert for both warnings and errors.
@tenpn
tenpn / output_log.txt
Created September 1, 2023 11:40 — forked from HugsLibRecordKeeper/output_log.txt
Rimworld output log published using HugsLib
Log uploaded on Friday, September 1, 2023, 4:36:55 AM
Loaded mods:
Prepatcher(zetrith.prepatcher): 0DataAssembly(1.0.0), 0Harmony(2.2.2), 0PrepatcherAPI(1.1.1), PrepatcherImpl(1.0.0), Prestarter(1.0.0)
Harmony(brrainz.harmony)[mv:1.5.0.0]: 0Harmony(2.2.2), HarmonyMod(1.5.0)
Fishery - Modding Library(bs.fishery): 1Fishery(0.3.800.85), System.Runtime.CompilerServices.Unsafe(av:6.0.0,fv:6.0.21.52210)
Core(Ludeon.RimWorld): (no assemblies)
Performance Fish(bs.performance): 0PrepatcherAPI(1.1.1), 1Fishery(0.3.800.85), PerformanceFish(0.3.800.85), System.Runtime.CompilerServices.Unsafe(av:6.0.0,fv:6.0.21.52210)
Startup impact 1.4(automatic.startupimpact): 0Harmony(2.2.2), Assembly-CSharp-firstpass(0.0.0), StartupImpact(1.1.8369.39377), UnityEngine.SubsystemsModule(0.0.0)
Royalty(Ludeon.RimWorld.Royalty): (no assemblies)
Ideology(Ludeon.RimWorld.Ideology): (no assemblies)
struct FWidget
{
FWidget() : Name() {}
FWidget(FString Name) : Name(Name) {}
FWidget(FWidget Other) : Name(Other.Name) {}
void ProcessIntensity(float Intensity) { /** **/ }
FString Name;
}
struct FWidget
{
FWidget() : Name() {}
FWidget(FString Name) : Name(Name) {}
FWidget(const FWidget& Other) : Name(Other.Name) {}
void ProcessIntensity(float Intensity) { /** **/ }
FString Name;
}