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
| class Component | |
| attr_accessor :property, :another_property | |
| end | |
| class Entity | |
| def initialize() | |
| @components = {}; |
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
| #!/usr/bin/env bash | |
| #Get Packages | |
| #the -y tells the apt-get program to | |
| #respond with "yes" to every "are you sure" question | |
| apt-get -y update | |
| apt-get install -y python2.7-dev | |
| apt-get install -y curl | |
| apt-get install -y python-pip |
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
| <!--<script type="text/javascript" src="cordova.js"></script>--> | |
| <script type="text/javascript"> | |
| if (navigator.userAgent.match(/(iPhone|iPod|iPad|Android|BlackBerry)/)) { | |
| var script = document.createElement("script"); | |
| script.type = "text/javascript"; | |
| script.src = "cordova.js"; | |
| document.getElementsByTagName("body")[0].appendChild(script); | |
| script = null; | |
| } | |
| </script> |
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 UnityEngine; | |
| using System.Collections; | |
| public class ClipToCameraBounds : MonoBehaviour { | |
| private float minPos; | |
| private float maxPos; | |
| private SpriteRenderer renderer; |
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 UnityEngine; | |
| using System.Collections; | |
| public class BulletMovement : MonoBehaviour { | |
| public float speed; | |
| // Use this for initialization | |
| void Start () { | |
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 UnityEngine; | |
| using System.Collections; | |
| public class FireBullet : MonoBehaviour { | |
| public GameObject bullet; | |
| public float maxCoolDown; | |
| private float timer; | |
| private bool canShoot; |
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
| device_token = 'example_token' | |
| ionic_private_key = 'your_ionic_private_key_here' | |
| ionic_app_id = 'your_ionic_app_id_here' | |
| form_data = { | |
| 'tokens' => [device_token], | |
| 'notification' => { | |
| 'alert' => "Hello Push World!", | |
| 'android' => { | |
| 'payload' => { |
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
| angular.module('yourTotallyAwesomeApp') | |
| .run(function($ionicPlatform, $ionicPush, $ionicUser) { | |
| $ionicPlatform.ready(function() { | |
| //A cheat check to make sure we're on a device | |
| if(window.plugins){ | |
| $ionicPush.register({ | |
| canRunActionsOnWake: true, | |
| onNotification: function(notification) { |
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
| ionic plugin add https://github.com/phonegap-build/PushPlugin.git | |
| ionic add ngCordova | |
| ionic add ionic-service-core | |
| ionic add ionic-service-push |
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
| .config(function($stateProvider, $urlRouterProvider) { | |
| $stateProvider | |
| .state('app', { | |
| url: '/app', | |
| abstract: true, | |
| templateUrl: 'templates/menu.html' | |
| }) | |
| .state('app.weather', { |
OlderNewer