Skip to content

Instantly share code, notes, and snippets.

@tkymx
tkymx / day.swift
Created May 7, 2017 08:18
getToDay 何日前かを指定して日付をstringで取得、DateManager 日付と体重の組を管理(コンストラクタで乱数組作成)
func getToDay(day : Double = 0) -> String {
let now = Date( timeInterval: 60*60*24*day, since: Date() as Date )
let formatter = DateFormatter()
formatter.dateFormat = "yyyy-MM-dd"
return formatter.string(from: now as Date)
}
@tkymx
tkymx / BasePage.cs
Created February 17, 2021 05:04
Timeline の実験
using System.Collections;
using System.Collections.Generic;
using UnityEngine;
using UnityEngine.AddressableAssets;
using UnityEngine.Timeline;
using System;
[Serializable]
public class PageTransitionInfo
{
@tkymx
tkymx / TimelineAssetClone.cs
Created March 7, 2021 08:27
CloneTimelineAsset の複製
private class TimelinePrivateMethodAndField : ITimelinePrivateMethodAndField
{
private readonly MethodInfo _timelineAddMethod;
private readonly MethodInfo _timelineRemoveMethod;
private readonly MethodInfo _trackAddMethod;
private readonly MethodInfo _trackRemoveMethod;
private readonly FieldInfo _trackParentField;
public TimelinePrivateMethodAndField()
{