Skip to content

Instantly share code, notes, and snippets.

View zecereal's full-sized avatar
🎯
Focusing

Jackrit Yangsung zecereal

🎯
Focusing
View GitHub Profile
@ascorbic
ascorbic / App.tsx
Last active April 19, 2025 03:18
Spine/React demo
import React, { useState, useEffect, useCallback } from "react";
import * as PIXI from "pixi.js";
import { Stage } from "@inlet/react-pixi";
import Spine from "./Spine";
window.PIXI = PIXI;
const mixes = [
{
// this function recieves balance which is not really in this unit scope.
// so we dont need to care what balance.getBalance() does.
static double getBalanceWithDecimalPoint(Balance balance, int dp) throws NegativeBalanceException {
if (balance.getBalance() < 0) {
throw new NegativeBalanceException();
}
System.out.println("Converting to " + dp + "decimal point");
return balance.getBalance();
}
@punneng
punneng / DbHeper.java
Last active December 11, 2017 16:04
pre-test and post-test
/*
* To change this license header, choose License Headers in Project Properties.
* To change this template file, choose Tools | Templates
* and open the template in the editor.
*/
package com.mycompany.mavenproject1;
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.SQLException;
@Hertzole
Hertzole / SceneObject.cs
Last active May 4, 2024 13:04
Unity scene object to easily assign scenes in the inspector.
using UnityEngine;
#if UNITY_EDITOR
using UnityEditor;
#endif
[System.Serializable]
public class SceneObject
{
[SerializeField]
private string m_SceneName;