This file contains hidden or 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
import UIKit | |
final class SheetModalPresentationController: UIPresentationController { | |
// MARK: Private Properties | |
private let isDismissable: Bool | |
private let interactor = UIPercentDrivenInteractiveTransition() | |
private let dimmingView = UIView() | |
private var propertyAnimator: UIViewPropertyAnimator! |
This file contains hidden or 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
import Firebase | |
import Combine | |
// MARK: - CollectionReference | |
public struct CombineFIRCollection { | |
fileprivate let collection: CollectionReference | |
} | |
extension CombineFIRCollection { |
This file contains hidden or 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
--given a 2D table "tiles" with a cell for each tile on the ground, and each cell containing a list of objects | |
--in that cell,find all cells which are in line of sight between points A and T | |
--s is cellsize (square) | |
--tiles is a 2D table | |
--results will be passed back in a table | |
--so if tile[3][4] is in line of sight, then (whatever is in) tiles[3][4] will be added to the results | |
function GetTiles(T,A,s,tiles) | |
local x0,y0,x1,y1=T.x/s,T.z/s,A.x/s,A.z/s --tile positions of the two points | |
local dx = abs(x1-x0) | |
local dy = abs(y1-y0) |
This file contains hidden or 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
import SceneKit | |
import QuartzCore | |
class GameViewController: NSViewController { | |
@IBOutlet weak var gameView: GameView! | |
override func awakeFromNib(){ | |
let numSphere = 10 |
This file contains hidden or 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 the Jenkins Groovy Post build plugin to execute the following after every build | |
// https://wiki.jenkins-ci.org/display/JENKINS/Groovy+Postbuild+Plugin | |
// It would be nice not to have to specify these here... the repo name should be available within the hudson | |
// api somehow, but I didn't know how to get it. The access token should maybe be saved in a config file, and | |
// read in at runtime? | |
GITHUB_REPO_NAME = 'myusername/myreponame' | |
GITHUB_ACCESS_TOKEN = 'my_github_api_v3_access_token' |