This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const std = @import("std"); | |
const User = @import("../models/user.zig").User; | |
const String = @import("string").String; | |
const SharedAllocator = @import("allocator.zig"); | |
const Config = @import("../models/config.zig").Config; | |
pub fn getUserData(username: []const u8) !?User { | |
const allocator = SharedAllocator.getAllocator(); | |
const parsed = try Config.readConfig(allocator); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://nachtimwald.com/2019/04/12/thread-pool-in-c/ | |
#include "tpool.h" | |
#include <pthread.h> | |
#include <stdbool.h> | |
#include <stddef.h> | |
#include <stdlib.h> | |
struct tpool_work { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const std = @import("std"); | |
var allocator: std.mem.Allocator = undefined; | |
const Self = @This(); | |
pub fn init(a: std.mem.Allocator) void { | |
allocator = a; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
[CreateAssetMenu(fileName = "Immortality", menuName = "Powerup/Immortality")] | |
public class Immortality : Powerup | |
{ | |
[SerializeField] | |
private PowerupStats speedBoost; | |
public float GetSpeedBoost() | |
{ | |
return speedBoost.GetValue(currentLevel); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEngine.SceneManagement; | |
using UnityEngine.UI; | |
public class GameManager : MonoBehaviour | |
{ | |
public static GameManager instance; | |
public Text scoreText; | |
public Text coinScoreText; | |
public Text highScoreText; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
using UnityEngine.SceneManagement; | |
using UnityEngine.UI; | |
public class GameManager : MonoBehaviour | |
{ | |
public static GameManager instance; | |
public Text scoreText; | |
public Text coinScoreText; | |
public Text highScoreText; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using UnityEngine; | |
public class CoinController : MonoBehaviour | |
{ | |
private Transform player; | |
private void Start() | |
{ | |
player = GameObject.FindGameObjectWithTag("Player").transform; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import collections | |
import base64 | |
import hmac | |
import hashlib | |
import requests | |
import urllib.parse | |
import requests | |
import json | |
from typing import Dict, List, Tuple |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from typing import Tuple | |
import mammoth | |
import os | |
import string | |
import random | |
import argparse | |
def generate_unique_filename(): | |
letters = string.ascii_lowercase |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const fs = require("fs"); | |
const express = require("express"); | |
const bodyParser = require("body-parser"); | |
const app = express(); | |
app.use(bodyParser.json({ extended: true })); | |
const port = 8080; |
NewerOlder