Skip to content

Instantly share code, notes, and snippets.

View TheVoxcraft's full-sized avatar

Jonas TheVoxcraft

  • University i Oslo (USIT)
View GitHub Profile
@TheVoxcraft
TheVoxcraft / Money_Maker.py
Last active August 29, 2015 14:10
Fake Money Maker! Idea by MIkkel
#Makes Money!
def rndTime(minT, maxT):
rnd = random.randint(minT, maxT)
time.sleep(rnd)
def rndMoney(minM, maxM):
rnd = random.randint(minM, maxM)
return rnd
@TheVoxcraft
TheVoxcraft / terrain.py
Created December 3, 2014 11:28
Basic Terrain Generation
print("Loading...\n\n")
import random
line1=""
line2=""
line3=""
line4=""
line5=""
line6=""
line7=""
@TheVoxcraft
TheVoxcraft / decode.py
Last active August 29, 2015 14:10
Encode and Decode based on dkey
# -*- coding: utf-8 -*-
word = raw_input("Decode Word: ")
dkey = "qwerty,uiop:å!asdf;g.hjklø?æz xcv'bnm"
decoded = ""
word = word.lower()
for letterw in word:
for lettera in dkey:
@TheVoxcraft
TheVoxcraft / main.py
Created December 3, 2014 11:33
The Smart Test! Using DBs. Original by Mikkel
print('Welcome to Smart Test!')
print("Made by VOX.")
print("Adapted from Downy Test created Mikkel helped by VOX.")
print("\n"*3)
print("Loading...")
import time
import os
import random
@TheVoxcraft
TheVoxcraft / ascii_art_generator.py
Last active August 29, 2015 14:10
Final version of ASCII ART GENERATOR
# by TheVoxcraft, on github now.
print(r"Welcome to TheVoxcraft's ASCII ART GENERATOR!")
word = raw_input("Type in a word: ")
current_letter = ""
current_count = 0
line1 = ""
line2 = ""
line3 = ""
line4 = ""
@TheVoxcraft
TheVoxcraft / index.html
Last active August 29, 2015 14:10
One Way messager! My first chat room type of application.
One Way messager! My first chat room i made in python.
@TheVoxcraft
TheVoxcraft / RPG.py
Created December 3, 2014 12:08
Simple RPG in python
from random import randint
class Character:
def __init__(self):
self.name = ""
self.health = 1
self.health_max = 1
def do_damage(self, enemy):
damage = min(
max(randint(0, self.health) - randint(0, enemy.health), 0),
@TheVoxcraft
TheVoxcraft / ntsng v2.py
Created December 3, 2014 12:09
Never the same number generator. VERSION 2
import random as rnd
nu=0
try:
with open("DATA.txt", 'r') as f:
c = [line.rstrip('\n') for line in f]
print "LOADED!"
except IOError:
print "Setting up!"
with open("DATA.txt", 'w') as f:
@TheVoxcraft
TheVoxcraft / guess_it.py
Last active August 29, 2015 14:10
2 Player Guessing Game. The player nearest to random number wins. Local
import random
#To do: Make it multiplayer LAN version!
print("\n"*50)
print("Welcome to guess the it!")
print("")
print("")
player1name=raw_input("Enter your name player 1: ")
@TheVoxcraft
TheVoxcraft / divide.py
Created December 3, 2014 12:12
Divides words.
#letter dividing
canRun=1
while canRun == 1:
word=raw_input("Type in a word: ")
for letter in word:
print("Current letter: " + letter)
print(" ")