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
<!-- | |
DEVELOPED BY: OneDev Group | |
WEBSITE: https://onedevgroup.com | |
PLAY ONLINE: https://goo.gl/d8nya2 | |
FULL SOURCE CODE: https://goo.gl/GqpTAh | |
DEVELOPED FOR: https://youtu.be/fteA6mOZjXw | |
--> | |
<style type="text/css"> | |
#wrapper canvas, | |
#wrapper.playing menu { |
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> | |
... | |
</head> | |
<body> | |
<h1><?php echo 'Salam, Dünya!'; ?></h1> | |
</body> | |
</html> |
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 | |
echo 'Salam, Dünya!'; | |
?> |
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 | |
define('CONSTANT_1', 12); | |
define('CONSTANT_2', 'Kodera'); | |
define('CONSTANT_3', 'Salam, '.CONSTANT_2); | |
const CONSTANT_4 = 'Mən sabitəm'; | |
?> |
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 | |
$deyisen_1 = 10; | |
function calculate() | |
{ | |
echo $deyisen_1; | |
} | |
calculate(); | |
?> |
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 | |
$deyisen_1 = 'Qiymeti'; | |
$deyisen_2 = 35; | |
$deyisen_3 = 1 + 2; | |
?> |
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
class Rectangle { | |
public float x; | |
public float y; | |
public float width; | |
public float height; | |
public float left() { | |
return this.x; | |
} | |
public float top() { | |
return this.y; |
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
class Circle { | |
public float x; | |
public float y; | |
public float radius; | |
public void set(float x, float y, float radius) { | |
this.x = x; | |
this.y = y; | |
this.radius = radius; | |
} | |
public Circle(float x, float y, float radius) { |
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
public boolean collides(Rectangle r1, Rectangle r2) { | |
return | |
(r2.left() >= r1.left() && r2.left() <= r1.right()) || | |
(r2.right() >= r1.left() && r2.right() <= r1.right()) || | |
(r2.top() >= r1.top() && r2.top() <= r1.bottom()) || | |
(r2.bottom() >= r1.top() && r2.bottom() <= r1.bottom()); | |
} |
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 boolean clamp(float value, float min, float max) { | |
return Math.max(min, Math.min(max, value)); | |
} | |
public boolean collides(Rectangle r1, Circle c1) { | |
float cx = clamp(c1.x, r1.left(), r1.right()); | |
float cy = clamp(c1.y, r1.top(), r1.bottom()); | |
... | |
} |
OlderNewer