Skip to content

Instantly share code, notes, and snippets.

View asmwarrior's full-sized avatar

ollydbg asmwarrior

View GitHub Profile
@asmwarrior
asmwarrior / opengl-codeblocks.cpp
Created April 17, 2023 00:56
use opengl under codeblocks
#include <GL/glew.h>
#include <GLFW/glfw3.h>
#include <iostream>
#include <glm/glm.hpp>
#include <glm/gtc/matrix_transform.hpp>
#include <glm/gtc/type_ptr.hpp>
const char* vertexShaderSource = R"glsl(
#version 330 core
@asmwarrior
asmwarrior / TkinterExcel.py
Created April 11, 2023 09:57 — forked from RamonWill/TkinterExcel.py
The code from my video on how to view an excel file or Pandas Dataframe inside Tkinter (with comments)
# Youtube Link: https://www.youtube.com/watch?v=PgLjwl6Br0k
import tkinter as tk
from tkinter import filedialog, messagebox, ttk
import pandas as pd
# initalise the tkinter GUI
root = tk.Tk()
@asmwarrior
asmwarrior / wizard.script
Created March 30, 2023 11:08
wxWidgets for msys2
////////////////////////////////////////////////////////////////////////////////
//
// wxWidgets project wizard
//
////////////////////////////////////////////////////////////////////////////////
// globals
WizType <- wizProject;
WxPath <- _T("");
WantPCH <- false;
@asmwarrior
asmwarrior / lexer.cpp
Created January 31, 2023 01:38 — forked from arrieta/lexer.cpp
Simple C++ Lexer
// A simple Lexer meant to demonstrate a few theoretical concepts. It can
// support several parser concepts and is very fast (though speed is not its
// design goal).
//
// J. Arrieta, Nabla Zero Labs
//
// This code is released under the MIT License.
//
// Copyright 2018 Nabla Zero Labs
//
@asmwarrior
asmwarrior / Recursive-descent-backtracking.js
Created January 11, 2023 08:53 — forked from DmitrySoshnikov/Recursive-descent-backtracking.js
Recursive descent parser with simple backtracking
/**
* = Recursive descent parser =
*
* MIT Style License
* By Dmitry Soshnikov <dmitry.soshnikov@gmail.com>
*
* In this short lecture we'll cover the basic (non-predictive, backtracking)
* recursive descent parsing algorithm.
*
* Recursive descent is an LL parser: scan from left to right, doing
@asmwarrior
asmwarrior / event_system.cpp
Created July 28, 2022 06:01
code I copy and modified from this link: c++ - ECS Event/Messaging implementation - Code Review Stack Exchange — https://codereview.stackexchange.com/questions/79211/ecs-event-messaging-implementation
#include <iostream>
#include <cstdlib>
#include <functional>
#include <vector>
struct BaseEvent
{
virtual ~BaseEvent() {}
protected:
static size_t getNextType();
@asmwarrior
asmwarrior / ConvertUTF-8.py
Created July 20, 2022 10:22 — forked from smccutchen/ConvertUTF-8.py
Convert multiple files to UTF-8 encoding with Notepad++
# 2016-2017 Soverance Studios.
# Scott McCutchen
# This file will search all files and folders within a given directory, and use Notepad++ to convert their encoding to UTF-8 without Byte Order Marks
#
# This file must be run using the PythonScript plugin from within Notepad++, which is available through the Notepad++ Plugin Manager
#
# You must have Python 2.7 installed
#
# Additionally, this script can only exist and be run from within the Notepad++ user's working directory, the default of which is here:
@asmwarrior
asmwarrior / mingw-copy-deps.sh
Created March 3, 2022 13:15 — forked from h0tw1r3/mingw-copy-deps.sh
Recursively copy windows binary (dll/exe) dependencies from a sysroot (mingw toolchain) to the binaries directory.
#!/usr/bin/env bash
#
# Copyright: © 2015 Jeffrey Clark <https://github.com/h0tw1r3/>
# License: GPLv3 (http://www.gnu.org/licenses/gpl-3.0.html)
#
set -o errtrace
error() {
echo "ERROR in $0 : line $1 exit code $2"
exit $2
@asmwarrior
asmwarrior / phrases.ini
Created February 20, 2022 09:51 — forked from tualatrix/phrases.ini
搜狗拼音输入法--自定义短语配置文件 for Mac,放在 /Library/Input Methods/SogouInput.app/Contents/Resources/phrases.ini 下即可
; 搜狗拼音输入法--自定义短语配置文件
;
; 说明:
; 1、自定义短语支持多行、空格、指定位置。
; 2、每条自定义短语最多支持30000个汉字,总共支持100000行内容。
; 3、自定义短语的格式如下:
;
; 单行的格式:
; 字符串+英文逗号+数字(指定排序位置)=短语
;
@asmwarrior
asmwarrior / lwarp-tips.md
Created February 16, 2022 14:58 — forked from DominikPeters/lwarp-tips.md
Some tips for using lwarp for Latex to HTML conversion

Replace natbib by biblatex to get citation links

\usepackage[backend=bibtex, style=authoryear-comp, natbib=true, sortcites=false]{biblatex}
\addbibresource{main.bib}

% optional if you want (Smith 1776) instead of (Smith, 1776)
\renewcommand*{\nameyeardelim}{\addspace}

\begin{document}