generating unintelligent random maps on mouse press

this code generates random maps on mouse press. it is really just a simple 2d array value filling. a modification of this article. demo explanations  

  here we generated a random map by looping and assigning a random value. randint returns a value betwen 1 and 0. the advantage of a function is… Continue Reading generating unintelligent random maps on mouse press

game map rendering

game map rendering

game map rendering or simply map rendering is a nice technique that is used to generate worlds. explanations follow suit : demo explanations  

  first we initialise our world as a 2d array, we distinguished patterns by using 0 and 1  

  next we initialised the width of a tile. the… Continue Reading game map rendering

polygon drawer implementation (processing.py)

polygon drawer implementation (processing.py)

if ever you wanted to implement a polygon drawer, here it is : explanations  

  first we added some coordinates as 2d arrays  

  then for each coordinate we drew a line from it to the next, the try pass is a bad and lazy practise to prevent out of index… Continue Reading polygon drawer implementation (processing.py)

processing.py : trails using oop

in this post, we’ll explain how to add trails using an oop approach. a trail is basically objects that appear where the primary objects passed in nature, trails are made by particles of the primary object but in programming, one simple approach is to draw other shapes albeit more small the full code there is the full processing.py code :

explanations in… Continue Reading processing.py : trails using oop