This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extends Node2D | |
#var axiom = "F++F++F++" | |
var axiom = "A" | |
var angle_step = deg_to_rad(60) | |
var iteration = 1 | |
var step_length: float = 64 | |
var frame = Rect2(0, 0, 0, 0) | |
var rules = { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
extends Node2D | |
var axiom = "F++F++F++" | |
var angle_step = deg_to_rad(60) | |
var iteration = 1 | |
var step_length: float = 64 | |
var rules = { | |
"F": "F-F++F-F" | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
let tileString = "0100100000" + | |
"0111100110" + | |
"0111101010" + | |
"0001001000" + | |
"0011000100" + | |
"0011100010" + | |
"0011110010" + | |
"0011110010" + | |
"0001110010" + | |
"0011111100" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
private func dashedLineNode(start: CGPoint, end: CGPoint, pattern: [CGFloat] = [10, 10]) -> SKNode { | |
let bezierPath = CGMutablePath() | |
bezierPath.move(to: start) | |
bezierPath.addLine(to: end) | |
let dashed = bezierPath.copy(dashingWithPhase: pattern[0] / 2, lengths: pattern) | |
return SKShapeNode(path: dashed) | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// CameraViewController.swift | |
// Camera | |
// | |
// Created by Stephen Gurnett on 03/01/2016. | |
// Copyright © 2016 Stephen Gurnett. All rights reserved. | |
// | |
import UIKit | |
import MobileCoreServices |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using System.Collections.Generic; | |
namespace HutongGames.PlayMaker.Actions | |
{ | |
[ActionCategory(ActionCategory.GUI)] | |
[Tooltip("GUI button. Sends an Event when pressed. Optionally store the button state in a Bool Variable. Set a String var")] | |
public class GUIButtonSetStringValue : GUIButton | |
{ | |
[RequiredField] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
swing.edt { | |
frame( id: 'mainFrame', | |
title: 'title', | |
defaultCloseOperation: JFrame.EXIT_ON_CLOSE, | |
show: true, | |
size: [300, 300]) { | |
textLabel = label(text:"Drag file here", constraints:BL.NORTH) | |
mainFrame.dropTarget = [ | |
drop: { dtde -> | |
def t = dtde.transferable |