Skip to content

Instantly share code, notes, and snippets.

View Atlante45's full-sized avatar

Clement Brisset Atlante45

  • Discord
  • San Francisco, CA
View GitHub Profile

Keybase proof

I hereby claim:

  • I am atlante45 on github.
  • I am atlante45 (https://keybase.io/atlante45) on keybase.
  • I have a public key whose fingerprint is 20B1 0A75 2B2B 9D89 1005 1E6C C52F EBF0 FDE6 DDBA

To claim this, I am signing this object:

@Atlante45
Atlante45 / hasher.sh
Last active January 4, 2018 02:44
small script that processes a large amount of files to add to an Asset Server
#/bin/sh
input="$(dirname $0)/input"
output="$(dirname $0)/output"
if [ ! -d "$input" ]; then
echo "Missing input folder: $input";
exit;
fi
if [ ! -d "$output" ]; then
@Atlante45
Atlante45 / testScript.js
Created July 18, 2018 23:09
Simple test script
console.log("Test Script starting.");
var counter = 0;
Script.setInterval(function() {
console.log("Counter is now: " + (++counter));
}, 1000);
//
// BetterClientSimulationBotFromRecording.js
// examples
//
// Created by Brad Hefta-Gaub on 2/6/17.
// Copyright 2017 High Fidelity, Inc.
//
// Distributed under the Apache License, Version 2.0.
// See the accompanying file LICENSE or http://www.apache.org/licenses/LICENSE-2.0.html
//
Agent.isAvatar = false;
var count = 0;
Script.update.connect(function(dt) {
count += dt;
if (count > 5) {
console.log("Update");
count = 0;
}
});
function getAvatarWithName(name) {
var avatars = AvatarList.getAvatarIdentifiers();
for (i in avatars) {
if (AvatarList.getAvatar(avatars[i]).displayName == name) {
return avatars[i];
}
}
return null;
}
var soundURL = "http://hifi-public.s3.amazonaws.com/birarda/medium-crowd.wav";
var injector = null;
var sound = null;
function startInjector() {
injector = Audio.playSound(sound, {
position: MyAvatar.position,
volume: 0.5,
localOnly: false,
loop: false
var soundURL = "http://hifi-public.s3.amazonaws.com/birarda/medium-crowd.wav";
var injector = null;
var sound = null;
function startInjector() {
injector = Audio.playSound(sound, {
position: MyAvatar.position,
volume: 0.5,
localOnly: false,
loop: true
@Atlante45
Atlante45 / pre-push
Created January 18, 2019 18:21
git pre-push hook that prevent accidental pushes to upstream (Add it to .git/hooks)
#!/bin/sh
remote="$1"
url="$2"
bold=$(tput bold)
normal=$(tput sgr0)
yellow='\033[1;33m'
red='\033[0;31m'
default='\033[0m'
@Atlante45
Atlante45 / reload-failing-server-scripts.js
Created January 30, 2019 23:17
Tracks down and reloads failing entity server scripts.
var entitiesWithServerScripts = 0
function callbackClosure(i, callback) {
return function() {
return callback(i);
}
}
var interval = Script.setInterval(function() {
console.log("Checks pending:", entitiesWithServerScripts)