Skip to content

Instantly share code, notes, and snippets.

View VivianVerdant's full-sized avatar

Vivian VivianVerdant

View GitHub Profile
@VivianVerdant
VivianVerdant / wait_for_element.js
Last active April 29, 2025 22:31 — forked from mindplay-dk/waitForElement.js
wait_for_element function (wait for element matching selector)
let animationCounter = 0;
function wait_for_element(selector, func, once, parent){
parent = parent || document;
once = (once == undefined ? true : false);
if (once) {
_wait_for_element_once(parent, selector).then(func);
} else {
_wait_for_element(parent, selector, func);
}
@VivianVerdant
VivianVerdant / PixelPerfectScaling.gd
Created May 31, 2022 00:57 — forked from atomius0/PixelPerfectScaling.gd
Pixel-Perfect scaling script, ported to Godot 3.
# original code by CowThing: https://github.com/godotengine/godot/issues/6506
# port to Godot 3 and bugfixes by atomius.
# usage:
# set this script as AutoLoad (Singleton enabled)
#
# in the project settings:
# [display]
# set 'window/size/width' and 'window/size/height' to your desired render resolution.
# set 'window/size/test_width' and 'window/size/test_height' to the initial window size.