A Pen by Jason Malatia on CodePen.
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<title>Simple React App</title> | |
<script src="https://unpkg.com/react@15/dist/react.min.js"> </script> | |
<script src="https://unpkg.com/react-dom@15/dist/react-dom.min.js"></script> | |
<script src="https://unpkg.com/[email protected]/babel.min.js"></script> | |
</head> | |
<body> | |
<div id="root"></div> |
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 val paintBlock = Paint().apply { | |
style = Paint.Style.STROKE | |
color = Color.BLUE | |
strokeWidth = 220F | |
} | |
var position_x_block = (0F - 100F) | |
var random_y = 0 |
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 fun drawGameBlock(canvas: Canvas?) { | |
var startX = (width - 300).toFloat() | |
var startY = (height / 2 - 160).toFloat() | |
var stopX = startX | |
val stopY = 0F | |
canvas?.drawLine(startX, startY, stopX, stopY, paintBlock) | |
canvas?.drawLine(startX, startY + 300F, stopX, height.toFloat(), paintBlock) |
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
var fallUpAnimation: ValueAnimator? = null | |
private fun fallUp() { | |
fallDawnAnimation.cancel() | |
if (fallUpAnimation != null) { | |
if (fallUpAnimation!!.isRunning) { | |
fallUpAnimation!!.cancel() | |
} | |
} |
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
var circle_height = 0 | |
var paint = Paint().apply { | |
style = Paint.Style.FILL | |
color = Color.BLUE | |
} | |
lateinit var fallDawnAnimation: ValueAnimator |
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
import android.content.Context | |
import android.graphics.Canvas | |
import android.graphics.Color | |
import android.graphics.Paint | |
import android.util.AttributeSet | |
import android.view.View | |
class FluppyBirdView @JvmOverloads constructor( | |
context: Context, attrs: AttributeSet? = null, defStyleAttr: Int = 0 | |
) : View(context, attrs, defStyleAttr) { |
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
curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer |
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
<?php | |
// Output screenshot: | |
// http://cl.ly/NsqF | |
// ------------------------------------------------------- | |
include_once 'console.php'; | |
// ::log method usage | |
// ------------------------------------------------------- | |
Console::log('Im Red!', 'red'); |
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
<?php | |
namespace App\Console\Commands; | |
use Illuminate\Support\Str; | |
use Illuminate\Console\GeneratorCommand; | |
class TestMakeCommand extends GeneratorCommand | |
{ | |
/** |