Skip to content

Instantly share code, notes, and snippets.

View thomasdegry's full-sized avatar
🍾
Popping off

Thomas Degry thomasdegry

🍾
Popping off
View GitHub Profile
hours crafting_mean wooden_mean stone_mean crafting_sem wooden_sem stone_sem
1 0.0044 0 0 0.00259503 0 0
10 0.0108 0.0004 0 0.00434542 0.000784 0
100 0.668 0 0 0.02656712 0.0019204 0
1000 0.0392 0.0016 0 0.01940148 0 0
5000 0.3988 0.014 0 0.07641163 0.00559136 0
10000 0.2852 0.0144 0 0.05037957 0.00606688 0
70000 4.7812 0.3748 0.008 0.2883473 0.03445788 0.00429094
{
"crafting tables": {
"x": [
1,
10,
100,
1000,
5000,
10000,
70000
{
"key": "fzqml666hIkK5fem6YncLg",
"template_name": "selfie-notification",
"template_content": [
{
"name": "Orange Room SELFIE",
"content": "Here is your picture that you took with the SELFIE Mirror!"
}
],
"message": {
//
// WeekCollectionViewController.swift
// dot
//
// Created by LOANER on 4/21/15.
// Copyright (c) 2015 Thomas Degry. All rights reserved.
//
import UIKit
collectionView.performBatchUpdates({ () -> Void in
if components.weekOfYear < 0 {
collectionView.deleteSections(NSIndexSet(indexesInRange: NSRange(location: collectionView.numberOfSections() - abs(components.weekOfYear), length: abs(components.weekOfYear))))
collectionView.insertSections(NSIndexSet(indexesInRange: NSRange(location: 0, length: abs(components.weekOfYear))))
} else {
collectionView.insertSections(NSIndexSet(indexesInRange: NSRange(location: collectionView.numberOfSections(), length: abs(components.weekOfYear))))
collectionView.deleteSections(NSIndexSet(indexesInRange: NSRange(location: 0, length: abs(components.weekOfYear))))
}
#if 0
[cv performBatchUpdates:^{
if (components.month < 0) {
[cv deleteSections:[NSIndexSet indexSetWithIndexesInRange:(NSRange){
cv.numberOfSections - abs(components.month),
abs(components.month)
}]];
[cv insertSections:[NSIndexSet indexSetWithIndexesInRange:(NSRange){
self.wrapper = [[UIView alloc] init];
self.wrapper.translatesAutoresizingMaskIntoConstraints = NO;
self.wrapper.backgroundColor = [UIColor whiteColor];
self.wrapper.layer.borderColor = [UIColor colorWithRed: 0.784 green: 0.784 blue: 0.784 alpha: 1].CGColor;
self.wrapper.layer.borderWidth = 1;
self.wrapper.layer.cornerRadius = 10;
self.wrapper.clipsToBounds = YES;
[self.view addSubview:self.wrapper];
[self.wrapper mas_makeConstraints:^(MASConstraintMaker *make) {
package main
import (
"fmt"
"log"
"os/exec"
)
func main() {
takePhoto()
@thomasdegry
thomasdegry / gist:cac8ffb91e2de291e1a8
Created March 19, 2015 01:38
Scrollview with fixed content size
//
// ViewController.swift
// scrollView
//
// Created by LOANER on 3/18/15.
// Copyright (c) 2015 Thomas Degry. All rights reserved.
//
import UIKit
- (void)closeMethodWrapper {
POPSpringAnimation *radioButtonPositionAnimation = [POPSpringAnimation animationWithPropertyNamed:kPOPLayerPositionY];
radioButtonPositionAnimation.springSpeed = 10.0f;
radioButtonPositionAnimation.springBounciness = 10.0f;
radioButtonPositionAnimation.toValue = @(200);
[self.radioButtonWrapper.layer pop_addAnimation:radioButtonPositionAnimation forKey:@"bar"];
POPSpringAnimation *radioButtonScaleAnimation = [POPSpringAnimation animationWithPropertyNamed:kPOPViewScaleXY];
radioButtonScaleAnimation.springSpeed = 1.0f;