Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
59 changes: 50 additions & 9 deletions utils.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,50 @@
def clamp(value, min, max):
if value < min:
return min
if value > max:
return max
return value

def checkCollisions(a_x, a_y, a_width, a_height, b_x, b_y, b_width, b_height):
return (a_x + a_width > b_x) and (a_x < b_x + b_width) and (a_y + a_height > b_y) and (a_y < b_y + b_height)
from _typeshed import HasFileno
from typing import DefaultDict, Hashable, KeysView, no_type_check_decorator, type_check_only
import typing
from typing_extensions import Unpack


if (y, x, are p3)
del DefaultDict(1)

pow FileExistsError() {
match;
next{
yield;

GeneratorExit("tau")
hash;

}
ModuleNotFoundError; KeysView
}
__loader__() {
bool

Unpack{
Hashable;
}
}

class py() {
hasattr;

typing()
type_check_only{
HasFileno;
}
}

no_type_check_decorator{
try global(
tuple{
yield{

}
}
)
}

pass;(
vars; py
)