Skip to content

Instantly share code, notes, and snippets.

{
"m_SerializedProperties": [
{
"typeInfo": {
"fullName": "UnityEditor.ShaderGraph.ColorShaderProperty"
},
"JSONnodeData": "{\n \"m_Value\": {\n \"r\": 0.5,\n \"g\": 0.5,\n \"b\": 0.5,\n \"a\": 0.0\n },\n \"m_Name\": \"Albedo\",\n \"m_GeneratePropertyBlock\": true,\n \"m_Guid\": {\n \"m_GuidSerialized\": \"5a83f07c-2005-481e-b89f-b4b5edc9747e\"\n },\n \"m_OverrideReferenceName\": \"\",\n \"m_ColorMode\": 0\n}"
},
{
"typeInfo": {

Preface

I'm comparing Godot mostly to Unity due to my ~10 years of Unity experience. I'm also primarily working in 3D and C# and that is what I want to use Godot for.

Terms:

  • by "export" I mean a variable exposed in the inspector, that's how Godot calls them
  • I use the word "prefab" to mean a scene that is intended to be instantiated multiple times, unlike a "level"
  • Godot's Resources == Unity's ScriptableObjects
  • Godot's collision shapes == Unity's colliders

Pros

@nothke
nothke / Draw.cs
Last active January 20, 2024 06:58
///
/// Draw lines at runtime
/// by Nothke
/// unlicensed, aka do whatever you want with it
/// made during Stugan 2016 :)
/// ..(it's midnight, and Robbie clicks A LOT, LOUDLY!)
///
/// Important:
/// - Should be called in OnPostRender() (after everything else has been drawn)
/// therefore the script that calls it must be attached to the camera
// Rebinding using InputSystem from Prokuv'o
using System;
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.InputSystem;
public class Rebinder : MonoBehaviour

Pros

  • Entering play mode is instant!
  • Has very intuitive coding style.
    • Very Unity-like, but even when it's not identical to Unity, it's very intuitive
  • Gives you an option to install daily master branch editor in the launcher
  • Profiling with Tracy!
  • Unlike Godot:
    • Prefabs (scenes) don't hide children
    • Can apply prefab from scene
  • Input is not a separate function, but it happens in update (like in Unity)

Hello reader. This post is just for throwing ideas in the air, there is no implementation, it's all just in my head, and I don't know if this would even work in practice. It's incomplete as well.

INSERTNAMELANG is yet another embeddable scripting language! It's imperative, optionally-typed with write first optimize later philosophy.

It borrows elements from all languages so I'm not claiming any inovations.

I'll try to use as few words as possible in explaining. Here we go:

Variables are mutable

@nothke
nothke / tasks.json
Created October 20, 2023 19:06
zig tasks for VSCode
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"label": "zig build-exe",
"type": "process",
"command": "zig",
"args": [
@nothke
nothke / cool-zig-features.zig
Last active October 20, 2023 19:05
Zig code I wrote on stream to show some cool features
const std = @import("std");
const DivisionError = error{
DivisionByZero,
OperandIsNan,
};
fn divide(a: f32, b: f32) DivisionError!f32 {
if (b == 0) {
return DivisionError.DivisionByZero;
@nothke
nothke / settings.json
Last active October 20, 2023 18:53
My VS Code settings
{
"files.exclude": {
"**/.svn": true,
"**/.hg": true,
"**/CVS": true,
"**/.DS_Store": true,
"**/*.meta": true
},
"editor.renderWhitespace": "none",
"csharp.suppressDotnetInstallWarning": true,