Skip to content

Instantly share code, notes, and snippets.

View DarkStoorM's full-sized avatar

Bartosz Sieprawski DarkStoorM

View GitHub Profile
@DarkStoorM
DarkStoorM / ExecutionTimeMeasurement.php
Last active July 8, 2021 09:51
measure PHP code execution time
<?php
/*
|--------------------------------------------------------------------------
| Execution Time Measurement
|--------------------------------------------------------------------------
|
| Requires PHP 8
|
| This is a simple execution time measurement class for blocks of code and callables
@DarkStoorM
DarkStoorM / ObjectPooler.cs
Last active October 15, 2018 15:26
Unity Simple Object Pooler
/* Based on Unity Tutorials, a bit modified */
using System.Collections.Generic;
using UnityEngine;
public class ObjectPooler : MonoBehaviour {
[Header("DRAG OBJECT PREFAB HERE")]
/// <summary>
/// Main object, that will be pooled.
/// </summary>
[Tooltip("Main object, that will be pooled.")]
/*
JavaScript function to check whether if user clicked a specific region
on given element
Example <div>
<style>
#example {
width:500px;
height:500px;