Code Monkey home page Code Monkey logo

moppu's Introduction

Moppu

Lisp Game Jam Autumn 2019 Entry Play it here: https://sarge.itch.io/moppu

+D90t7

Requirements

  • x86_64 Windows, GNU/Linux or macOS
  • OpenGL 2.1 or 3.3+
  • x86_64 SBCL or CCL
  • Quicklisp

How to install SBCL or CCL

  • Go to http://www.sbcl.org or https://ccl.clozure.com and download the tool.
  • After sbcl is installed you can call it with the command sbcl from command line.
  • After ccl is installed run the exe in the folder and you are ready to go.

How to install Quicklisp

  • Go to https://www.quicklisp.org ad download ´quicklisp.lisp´
  • While sbcl or ccl is running enter the command (load "c:/somewhere/path_to_where_you_downloaded_quicklisp.lisp")
  • Quicklisp will be installed into your user folder.
  • Run the command (load "~/quicklisp/setup.lisp") to start setup.
  • Run the command (ql:add-to-init-file) to load quick lisp automatically when you run sbcl or ccl.

How to Run

To run from REPL, clone project into ~/quicklisp/local-projects/ and run the following commands.

(ql-dist:install-dist "http://bodge.borodust.org/dist/org.borodust.bodge.testing.txt")

(ql:register-local-projects)

(ql:quickload :moppu) (moppu::run)

Play the Builds

You can download the game for Windows, Mac and Linux from here. https://github.com/borodust/moppu/releases

Controls

Control Keyboard
Walk Arrow Keys
Jump Space

moppu's People

Contributors

srcnalt avatar borodust avatar

Stargazers

 avatar Krazov avatar Alper Kılcı avatar Hady Mahmoud avatar ma haidong avatar Brad Svercl avatar Oleg Pykhalov avatar Peter S. Housel avatar Roman avatar  avatar

Watchers

 avatar  avatar

Forkers

borodust

moppu's Issues

local variables

small improvement to your code: in Common Lisp setting a variable is a different operation from defining it.

(defun check-collision-all (item)
  (setf collides nil)
  (loop
    :for elem :in (nth (- *game-state* 2) *levels*)
    :when (check-collision item elem)
    :do (setf collides t))
  collides)

You have that pattern in your code elsewhere, too. load-level and check-collision for example.

SETF does not define a variable, but sets it only. To define a function local variable one has two options: let and (not that often seen) &aux:

(let ((collides nil))
  (loop ... (setf collides t) ...)
  collides)

or

(defun check-collision-all (item &aux (collides nil))
   (loop ... (setf collides t) ...)
   collides)

Otherwise collides possibly would be a global and undefined variable. A Common Lisp compiler will typically warn about that.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.