Skip to content

Instantly share code, notes, and snippets.

View LuviKunG's full-sized avatar

Thanut Panichyotai LuviKunG

View GitHub Profile
@LuviKunG
LuviKunG / zip.bat
Created August 11, 2026 08:43
Windows batch file for zipping.
@echo off
setlocal
set "file_name=pack.zip"
echo Creating %file_name% ...
if exist "%file_name%" (
del "%file_name%"
)
@LuviKunG
LuviKunG / FlowLayoutGroup.cs
Created June 21, 2026 08:33
A layout group that arranges children in a wrapping flow, similar to CSS flexbox with flex-wrap.
using System.Collections.Generic;
namespace UnityEngine.UI
{
/// <summary>
/// A layout group that arranges children in a wrapping flow, similar to CSS flexbox with flex-wrap.
/// Children keep their own preferred sizes; rows wrap when they exceed the container width.
/// Supports all nine <see cref="LayoutGroup.childAlignment"/> values for both per-row horizontal
/// alignment and whole-content vertical alignment.
/// </summary>
@LuviKunG
LuviKunG / settings.json
Last active June 17, 2026 11:13
VSCode Settings for the Unity C# Project. I'm using this for my personal configs but I want to share this also.
{
"dotnet.preferCSharpExtension": true,
"files.exclude": {
"Library/": true,
"Temp/": true,
"**/Assets/**/*.meta": true,
"*.sln": true,
"*.slnx": true,
"*.csproj": true,
".vs/": true,
@LuviKunG
LuviKunG / Weight.h
Created November 30, 2025 04:51
Unreal Engine 5 C++ scripts for add items with assigning weight to pick randomly.
// Made by Thanut Panichyotai (@LuviKunG)
// https://luvikung.github.io
// Attribution 4.0 International CC BY 4.0 Deed
// https://creativecommons.org/licenses/by/4.0/deed.en
#pragma once
#include "CoreMinimal.h"
#include "UObject/GCObject.h"
#include "Containers/Map.h"
// Minecraft Item Calculator.
// Author: Thanut Panichyotai (@LuviKunG)
// https://github.com/LuviKunG
// HOW TO USE:
// Enter the max item count and item count, then press Enter.
// The program will calculate how many stacks and items are needed. Press Enter to exit.
namespace MinecraftItemCalc
{
@LuviKunG
LuviKunG / Rider_Islands_Monokai_By_LuviKunG.icls
Last active November 19, 2025 16:53
It's my JetBrains Color Scheme the Rider Islands Monokai By @LuviKunG.
<scheme name="Rider Islands Monokai" version="142" parent_scheme="Darcula">
<metaInfo>
<property name="ide">Rider</property>
<property name="ideVersion">2025.3.0.1.0.0</property>
<property name="originalScheme">Rider Islands Monokai</property>
</metaInfo>
<colors>
<option name="ADDED_LINES_COLOR" value="2C4722" />
<option name="ANNOTATIONS_COLOR" value="909090" />
<option name="BookmarkIcon.background" value="D9B72B" />
@LuviKunG
LuviKunG / SimpleSpectatorPawn.cpp
Created March 6, 2025 18:00
A simple spectator pawn class for Unreal Engine 5.X C++ which replacement of a default pawn. Using Enhanced Inputs and implement move speed changing and zooming by change camera field of view.
// Copyright 2025 Thanut Panichyotai (@LuviKunG) All Rights Reserved.
#include "SimpleSpectatorPawn.h"
#include "EnhancedInputComponent.h"
#include "EnhancedInputSubsystems.h"
ASimpleSpectatorPawn::ASimpleSpectatorPawn(const FObjectInitializer& ObjectInitializer) : Super(ObjectInitializer)
{
PrimaryActorTick.bCanEverTick = true;
@LuviKunG
LuviKunG / clean_ds_store.bat
Created August 22, 2024 17:34
Clean all '.DS_Store' that contains in the sub folders.
@echo off
for /r %%i in (.DS_Store) do (del "%%i")
pause
@LuviKunG
LuviKunG / ObjectPickerEditorWindow.cs
Last active May 19, 2024 15:11
Unity editor window that used to pick an object from the asset database such as scriptable objects or prefabs which contains specific component.
using System;
using System.Collections.Generic;
using UnityEditor;
using UnityEngine;
namespace LuviKunG.Editor
{
using UnityObject = UnityEngine.Object;
/// <summary>
@LuviKunG
LuviKunG / AssetDatabaseHelper.cs
Last active May 19, 2024 15:10
Unity Editor static class for asset database operations.
using System;
using System.Collections.Generic;
using UnityEditor;
using UnityEngine;
namespace LuviKunG.Editor
{
using UnityObject = UnityEngine.Object;
/// <summary>