Skip to content

Instantly share code, notes, and snippets.

View ameyxd's full-sized avatar
🎯
Focusing

Amey Ambade ameyxd

🎯
Focusing
View GitHub Profile
# Your init script
#
# Atom will evaluate this file each time a new window is opened. It is run
# after packages are loaded/activated and after the previous editor state
# has been restored.
#
# An example hack to log to the console when each text editor is saved.
#
# atom.workspace.observeTextEditors (editor) ->
# editor.onDidSave ->
@ameyxd
ameyxd / collision.c
Created April 14, 2016 14:48
Collision
bool noCollision(){
if (zPos< 2.8 && zPos > -2.8 && xPos < 2.8 && xPos > -2.8 && yPos < 1.44) // if z is in the room (1.44 is the room height)
{
if (zPos < -1.8 && zPos > -2.2) //If in the space between door and stairs
{
if (xPos < 0.1 && xPos > -0.1 && DOOROPEN) return true; //x position fits and door is open: no collision
else return false;
}
if (zPos <= -2.2) //if in the stairway or upstairs
{