Skip to content

Instantly share code, notes, and snippets.

View saywassup's full-sized avatar
🎨

Jonatas Santos saywassup

🎨
View GitHub Profile
@raysan5
raysan5 / open_source_and_videogames.md
Last active February 15, 2025 00:33
Open Source and Videogames - Resources

open_source_and_videogames

Open Source and Videogames - Resources

This git include a list of programs, tools, engines and libraries free and open source intended to make videogames.

NOTE: This gist is a support material for the talk "Open Source and Videogames" given by me, Ramon Santamaria, on October 26th 2021 in Canòdrom, Barcelona. All the materials listed here were explained in detail in a +2 hours talk.

Contents

@saywassup
saywassup / SpriteSheet.elm
Created June 3, 2021 01:54 — forked from passiomatic/SpriteSheet.elm
GLSL fragment shader which renders a portion of a given sprite sheet
module SpriteSheet exposing (..)
import Math.Vector2 exposing (Vec2, vec2)
import WebGL exposing (Texture, Shader)
{-|
Render a portion of a sprite sheet.
-}
fragmentSpriteSheet : Shader {} { u | spriteSheet : Texture, spriteSheetSize: Vec2, spriteSize: Vec2, index : Float } { vcoord : Vec2 }
fragmentSpriteSheet =
@raysan5
raysan5 / custom_game_engines_small_study.md
Last active May 5, 2025 20:15
A small state-of-the-art study on custom engines

CUSTOM GAME ENGINES: A Small Study

a_plague_tale

A couple of weeks ago I played (and finished) A Plague Tale, a game by Asobo Studio. I was really captivated by the game, not only by the beautiful graphics but also by the story and the locations in the game. I decided to investigate a bit about the game tech and I was surprised to see it was developed with a custom engine by a relatively small studio. I know there are some companies using custom engines but it's very difficult to find a detailed market study with that kind of information curated and updated. So this article.

Nowadays lots of companies choose engines like Unreal or Unity for their games (or that's what lot of people think) because d

@paulund
paulund / google-webfont-async.php
Last active January 25, 2023 11:51
Javascript tag to load google web font async
<script type="text/javascript">
WebFontConfig = {
google: { families: [ 'Roboto' ] }
};
(function() {
var wf = document.createElement('script');
wf.src = ('https:' == document.location.protocol ? 'https' : 'http') +
'://ajax.googleapis.com/ajax/libs/webfont/1.6.26/webfont.js';
wf.type = 'text/javascript';
wf.async = 'true';
@paulirish
paulirish / thing.js
Created May 7, 2018 17:18
log the clipboard contents
document.body.innerHTML = 'Paste or drop items onto this page. View results in console.';
function getPayload(item) {
const kind = item.kind;
switch (kind) {
case 'string': return new Promise(res => item.getAsString(res));
case 'file': return Promise.resolve(item.getAsFile());
default: throw new Error('unknown item kind! ' + kind);
}

CSS units

Recommendations of unit types per media type:

Media Recommended Occasional use Infrequent use Not recommended
Screen em, rem, % px ch, ex, vw, vh, vmin, vmax cm, mm, in, pt, pc
Print em, rem, % cm, mm, in, pt, pc ch, ex px, vw, vh, vmin, vmax

Relative units

Relative units

@stevekinney
stevekinney / web-performance.md
Last active January 2, 2025 14:53
Web Performance Workshop

Web Performance

Requirements

Repositories

@gijun19
gijun19 / AnimatedRoutes.js
Created February 18, 2018 01:39
AnimeJS with React Transition Group
import React, { Component } from 'react';
import { withRouter, Switch } from 'react-router-dom';
import { TransitionGroup, Transition } from 'react-transition-group';
import anime from 'animejs';
import TransitionElements from './TransitionElements';
class AnimatedRoutes extends Component {
state = {
location: this.props.location,
transitioning: true,
@cdiggins
cdiggins / react-best-practices.md
Created January 25, 2018 16:20
React Best Practices
@faressoft
faressoft / dom_performance_reflow_repaint.md
Last active May 8, 2025 01:33
DOM Performance (Reflow & Repaint) (Summary)

DOM Performance

Rendering

  • How the browser renders the document
    • Receives the data (bytes) from the server.
    • Parses and converts into tokens (<, TagName, Attribute, AttributeValue, >).
    • Turns tokens into nodes.
    • Turns nodes into the DOM tree.
  • Builds CSSOM tree from the css rules.