Skip to content

Instantly share code, notes, and snippets.

View FossilizedCarlos's full-sized avatar
🎯
Focusing on SwiftUI and learning R.

Carlos E. Barboza FossilizedCarlos

🎯
Focusing on SwiftUI and learning R.
View GitHub Profile
@FossilizedCarlos
FossilizedCarlos / SpriteKit-SwiftUI-Metaballs.swift
Created June 16, 2025 15:03 — forked from twostraws/SpriteKit-SwiftUI-Metaballs.swift
A 30-minute hack to recreate the "iBeer" effect using SpriteKit, SwiftUI, and metaballs.
//
// A 30-minute hack to recreate the "iBeer" effect using SpriteKit, SwiftUI, and metaballs.
// The effect is created by having hundreds of physics-enabled balls in a SpriteKit scene,
// all drawing nothing. These balls are then read back out by SwiftUI in a TimelineView, and
// drawn using blur and alpha threshold filters to make them appear to be a liquid.
// The SpriteKit scene then has its gravity changed dynamically using the accelerometer,
// meaning that the "liquid" splashes around as you tilt your phone.
//
// Created by Paul Hudson
// https://www.hackingwithswift.com/license

How to use a PS3 controller on Mac OS X 10.7 (Lion)

  1. Open Apple menu -> System Preferences -> Bluetooth and disable Bluetooth on Mac as well as any other nearby Macs or devices which will try to pair with and confuse the controller.

  2. Reset PS3 controller by inserting paperclip into pinhole near L2 button.

  3. Connect PS3 controller to Mac with USB cable.

  4. Enable Bluetooth.