Skip to content

Instantly share code, notes, and snippets.

View emelent's full-sized avatar

Roy Motloutsi emelent

View GitHub Profile
@emelent
emelent / playerJump.py
Created December 2, 2015 20:18
Player Jump Sample
import pygame
"""
Solution for reddit user found at:
https://www.reddit.com/r/pygame/comments/3uw9ja/player_jumps_but_cannot_be_seen_going_upwards/
"""
pygame.init()
HEIGHT = 360
WIDTH = 480
@emelent
emelent / pobfuscate.py
Created January 12, 2016 08:26
Password Obfuscator
#!/bin/python2
"""
Simply takes a simple, insecure alphabetic phrase
and turns it into a useable password.
Use a friendly phrase you can easily remember to generate
a password no one can ever guess.
"""
@emelent
emelent / index.html
Created December 11, 2016 14:59
User Button
<div class="user-button">
<span class="user-icon">
M
</span>
</div>
<div class="user-info">
<div class="user-icon-container">
<span class="user-icon">
M
@emelent
emelent / index.html
Created December 12, 2016 16:33
material wave-effect button
<button class="material-btn">
<div class="wave"></div>
WAVE
</button>
<button class="slide-btn">
<div class="text">SLIDE</div>
</button>
@emelent
emelent / basic-dropdown-menu.markdown
Last active December 12, 2016 22:29
Basic dropdown menu
@emelent
emelent / index.html
Created December 12, 2016 16:35
Search Box
<div class="searchbox" onClick="onClick(event)">
<input type="text" onFocus="onFocus()" onBlur="onBlur()"/>
<button>
<i class="fa fa-search" aria-hidden="true"></i>
</button>
</div>
///Singleton audio manager
class AudioManager{
constructor(){
this.sounds = {};
this.queue = [];
this.currentlyPlaying = null;
this.currentAudio = null;
this.paused = false;
}
//controller function
function Controller($timeout){
this.loadingImages = true;
this.allTheImagesHaveLoaded = () =>{
//...
this.loadingImages = false;
};
@emelent
emelent / .eslintrc.json
Created July 25, 2017 14:47
ReactJs ESLint config
{
"env": {
"browser": true,
"commonjs": true,
"es6": true,
"node": true
},
"extends": "eslint:recommended",
"parserOptions": {
"ecmaFeatures": {