Super Mario Galaxy

This is the Super Mario Galaxy community. TAS and Non-TAS videos posted on this forum. Created and run by Giraffecheetah A.K.A. generalmarioY.


You are not connected. Please login or register

I am making my very own Video Game!

View previous topic View next topic Go down  Message [Page 1 of 1]

1 I am making my very own Video Game! on Sun Oct 23, 2011 2:49 am

My game is called Caracal. I am using Pygame, which is a programming language that allows you to make video games.

Download it here:
pygame.org

There is a bug with this code (frames per second), but I will fix it soon.



Code:
import os, sys
import pygame
import time
import math


pygame.init()
screen = pygame.display.set_mode((699, 500))
pygame.display.set_caption("Caracal")


pygame.font.init()
pygame.font.get_fonts()


#Loads everything.

caracal = []
caracal.append(pygame.image.load("Images/Caracal/caracal_stand_right.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_run_right.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_run_right_f2.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_jump_right_f1.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_jump_right_f2.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_down.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_sleep_right_f1.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_sleep_right_f2.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_sleep_right_f3.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_sleep_right_f4.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_stand_left.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_run_left.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_run_left_f2.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_jump_left_f1.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_jump_left_f2.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_down_left.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_sleep_left_f1.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_sleep_left_f2.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_sleep_left_f3.png"))
caracal.append(pygame.image.load("Images/Caracal/caracal_sleep_left_f4.png"))
caracal_loc = caracal[0].get_rect()

menubackground = pygame.image.load("Images/Backgrounds/menubackground.png")
menubackground_loc = menubackground.get_rect()


pressentertoskip = pygame.image.load("Images/Text/pressentertoskip.png")
pressentertoskip_loc = pressentertoskip.get_rect()

run = True
menu = True
f = 1



if not pygame.mixer:
  print "Warning: Sound disabled!"




while run == True:
  for event in pygame.event.get():
    if event.type == pygame.QUIT:
      run = False
    keypresses = pygame.key.get_pressed()
    mousebuttoninput = pygame.mouse.get_pressed()
    if keypresses[pygame.K_RIGHT]:
      pass
  if menu:
    pygame.time.delay(100)
    if f == 0 and pygame.time.delay > 100:
      f = 2
    elif f == 2 and pygame.time.delay > 100:
      f = 0
    screen.blit(menubackground, (0, 0))
    screen.blit(caracal[f], (320, 270))
    pygame.display.flip()
Have you ever felt attracted to an animated character? Did you ever think a character was just so cute or so sexy you just wanted to squeeze them? Ever wished you could tell people this, but you thought people would think you were crazy? Well, check out the forum just for you, Cartoon Crushes, at http://cartooncrushes.forumotion.com/ my friend!

Here you can register for free just by pressing the Register button.
If you´re going to make an account, PLEASE POST SOMETHING! Seriously, we´re tired of account wasters.
Anyway, have fun!



Last edited by Giraffecheetah on Thu Nov 07, 2013 6:08 pm; edited 1 time in total

View user profile index.html

2 Re: on Wed Apr 18, 2012 9:05 am

It looks like you are very clever . So , have you repaired it now ? Mario Mario

Have you ever felt attracted to an animated character? Did you ever think a character was just so cute or so sexy you just wanted to squeeze them? Ever wished you could tell people this, but you thought people would think you were crazy? Well, check out the forum just for you, Cartoon Crushes, at http://cartooncrushes.forumotion.com/ my friend!

Here you can register for free just by pressing the Register button.
If you´re going to make an account, PLEASE POST SOMETHING! Seriously, we´re tired of account wasters.
Anyway, have fun!

View user profile http:// http://www.beats-by-dre-headphones.us/

View previous topic View next topic Back to top  Message [Page 1 of 1]

Permissions in this forum:
You cannot reply to topics in this forum