Skip to content

Instantly share code, notes, and snippets.

View Xevion's full-sized avatar
⚜️
Chaos Order

Xevion Xevion

⚜️
Chaos Order
View GitHub Profile
double v1 = (radius * Math.cos(ang) + turnCon) * getMultiplier();
double v2 = (radius * Math.sin(ang) - turnCon) * getMultiplier();
double v3 = (radius * Math.sin(ang) + turnCon) * getMultiplier();
double v4 = (radius * Math.cos(ang) - turnCon) * getMultiplier();
robot.motorLeftFront.setPower(v1);
robot.motorRightFront.setPower(v2);
robot.motorLeftRear.setPower(v3);
robot.motorRightRear.setPower(v4);
let prefs = Cc["@mozilla.org/preferences-service;1"].getService(Ci.nsIPrefService);
let autocomplete = 'browser.urlbar.autoFill';
let history = 'browser.urlbar.suggest.history';
prefs.setBoolPref(history, !prefs.getBoolPref(history));
prefs.setBoolPref(autocomplete, !prefs.getBoolPref(autocomplete));
@Xevion
Xevion / office_scraper.py
Created August 8, 2020 00:11
Posting a simple scrapy based scraper for the officequotes.net site.
import json
from scrapy.linkextractors import LinkExtractor
from scrapy.spiders import CrawlSpider, Rule
urls = []
class FollowAllSpider(CrawlSpider):
name = 'follow_all'
@Xevion
Xevion / main.py
Created July 25, 2020 16:39
Custom Imgur Image Downloader
import os
import re
import json
import click
import shutil
import requests
import logging
from typing import List
from csv import DictReader
Traceback (most recent call last):
File "C:\Users\Xevion\.virtualenvs\unimatch\lib\site-packages\sqlalchemy\engine\base.py", line 1205, in _execute_context
context = constructor(dialect, self, conn, *args)
File "C:\Users\Xevion\.virtualenvs\unimatch\lib\site-packages\sqlalchemy\engine\default.py", line 865, in _init_compiled
for key in compiled_params
File "C:\Users\Xevion\.virtualenvs\unimatch\lib\site-packages\sqlalchemy\engine\default.py", line 865, in <genexpr>
for key in compiled_params
File "C:\Users\Xevion\.virtualenvs\unimatch\lib\site-packages\sqlalchemy\sql\sqltypes.py", line 2425, in process
serialized = json_serializer(value)
File "C:\Python37\lib\json\__init__.py", line 231, in dumps
PS F:\Programming\Unity\Climb> git add . --dry-run
warning: LF will be replaced by CRLF in Climb/.idea/.idea.Climb/.idea/encodings.xml.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in Climb/Assets/Grid Material.mat.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in Climb/Assets/Grid Material.mat.meta.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in Climb/Assets/GridShader.shader.meta.
The file will have its original line endings in your working directory
warning: LF will be replaced by CRLF in Climb/Assets/Plugins.meta.
# Repository
/Climb/.idea/**
# This .gitignore file should be placed at the root of your Unity project directory
#
# Get latest from https://github.com/github/gitignore/blob/master/Unity.gitignore
#
[Ll]ibrary/
[Tt]emp/
[Oo]bj/
// Upgrade NOTE: upgraded instancing buffer 'Props' to new syntax.
Shader "PDT Shaders/TestGrid" {
Properties {
_LineColor ("Line Color", Color) = (1,1,1,1)
_InactiveColor ("Cell Color", Color) = (0,1,0,1)
_ActiveColor ("Selected Color", Color) = (1,0,0,1)
[PerRendererData] _MainTex ("Albedo (RGB)", 2D) = "white" {}
[IntRange] _GridSize("Grid Size", Range(1,100)) = 10
_LineSize("Line Size", Range(0,1)) = 0.15
// Upgrade NOTE: upgraded instancing buffer 'Props' to new syntax.
Shader "PDT Shaders/TestGrid" {
Properties {
_LineColor ("Line Color", Color) = (1,1,1,1)
_InactiveColor ("Inactive Color", Color) = (0,1,0,1)
_ActiveColor ("Active Color", Color) = (1,0,0,1)
[PerRendererData] _MainTex ("Albedo (RGB)", 2D) = "white" {}
[IntRange] _GridSize("Grid Size", Range(1,100)) = 10
_LineSize("Line Size", Range(0,1)) = 0.15
{% extends "base.html" %}
{% block content %}
<div class="jumbotron bg-transparent">
<div class="container">
<div class="row">
<div class="col align-self-center">
<h1 class="jumbo-intro-head">
Lorem Ipsum
</h1>
<h6 class="jumbo-intro-sub">