How to start programming a game?

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
User avatar
TrkViktor
Prole
Posts: 2
Joined: Mon May 26, 2014 3:51 pm

How to start programming a game?

Post by TrkViktor »

Firstly we need a text editor don't the basic "notepad" on windows.

Text Editors:
Windows: Notepad++(free),Sublime Text 2(i'm use it,paid but i'm use a license from the internet)
Mac: TextMate(free)
Linux: Kate(free)

Why i'm recommend this text editors?
- Because they are have colorful text and easy to use;)

Okay the basic we learned.But we need to learn programming language.
Start here: http://love2d.org/wiki/Getting_Started

Basic we are setup the engine because the 95% of players lazy to download the LÖVE 2D runtime package*

First we need to install love engine into the created folder.
Create a folder and call it to "engine" ( " " <--- this is not need )

So download installer(or zip) install(or extract) the files.

If you failure this step you're stupid and don't continue the tutorial.
( I'm doesn't pick a picture because this is an easier step and if you can't do it you're not able to create a real game so sorry :c )

Next step we need to create a bat file and put these text to the bat file.
Image

Code: Select all

@ECHO OFF
start "" "engine\love" .
Okay we completed (three-quarters of) the tutorial! No so sorry:D

Next step we are write the main.lua and the conf.lua

main.lua

Start an empty text save it to main.lua and start editing:

We need to type these text to the main.lua

Image

Code: Select all

function love.draw()
    love.graphics.print("Hello World", 400, 300)
end
This is only the Hello World Text not a game basic(you look i'm think)


conf.lua

Again start an empty text save it to conf.lua and start editing:

Again we need to type these text to the conf.lua

Image

Code: Select all

function love.conf(t)
	t.modules.joystick = true
	t.modules.audio = true
	t.modules.keyboard = true
	t.modules.event = true
	t.modules.image = true
	t.modules.graphics = true
	t.modules.timer = true
	t.modules.mouse = true
	t.modules.sound = true
	t.modules.thread = true
	t.modules.physics = true
	t.console = false
	t.title = "Your Game"
	t.author = "You"
	t.screen.fullscreen = false
	t.screen.vsync = false
	t.screen.fsaa = 0
	t.screen.height = 600
	t.screen.width = 800
end

Now end start the bat file and look WORKING OH MY GOD :O

My folder looks:

Image


My basic program looks:

Image

Thanks for read it!

What i'm used to create this tutorial?

Keyboard
Mouse
Sublime Text 2
Windows
Google Translator(for 1-2 words)

:)
User avatar
Roland_Yonaba
Inner party member
Posts: 1563
Joined: Tue Jun 21, 2011 6:08 pm
Location: Ouagadougou (Burkina Faso)
Contact:

Re: How to start programming a game?

Post by Roland_Yonaba »

Well, thanks for your contribution. It is your first post, and already a tutorial. Nice.
I am afraid this does not seem to be useful, as-is. Maybe you should make it clear from the start that it is going to be a tutorial.
Second, define the objectives : what are you going to teach to your readers ?
And I am not very comfortable with the title, which, in my humble opinion, does not relate to the contents.
You basically explained how to create a .love project. Almost everyone here knows how to do that. I think.

Just my two cents, hope it wull help.
And, welcome around.
User avatar
TrkViktor
Prole
Posts: 2
Joined: Mon May 26, 2014 3:51 pm

Re: How to start programming a game?

Post by TrkViktor »

Thanks i'm a little programmer and i'm created a tutorial so i'm writed in the tutorial "lazy" people don't download the runtime package and this bat file uses the love2d from a folder.This is simple and easy.
I'm know this is already uploaded but this is my first tutorial and i'm starting a hardest lesson to the trainers.
User avatar
lalorobot
Prole
Posts: 16
Joined: Sat Apr 19, 2014 12:06 am
Contact:

Re: How to start programming a game?

Post by lalorobot »

First: Welcome to the forums! :ultrahappy: now back on-topic
TrkViktor wrote: Basic we are setup the engine because the 95% of players lazy to download the LÖVE 2D runtime package*
For windows and mac downloading the engine isn't needed (Note: Downloading Löve IS needed for developing a game but not for releasing it )
I am bad at explaining so you might want to take a look at this page from the wiki:
http://www.love2d.org/wiki/Game_Distribution
TrkViktor wrote: So download installer(or zip) install(or extract) the files.

If you failure this step you're stupid and don't continue the tutorial.
( I'm doesn't pick a picture because this is an easier step and if you can't do it you're not able to create a real game so sorry :c )
Personally I find this insulting I'm quite sure most of us didn't knew how to unzip a file when we first started using a computer.

Another thing please don't do this:
Image

Code: Select all

function love.conf(t)
   t.modules.joystick = true
   t.modules.audio = true
   t.modules.keyboard = true
   t.modules.event = true
   t.modules.image = true
   t.modules.graphics = true
   t.modules.timer = true
   t.modules.mouse = true
   t.modules.sound = true
   t.modules.thread = true
   t.modules.physics = true
   t.console = false
   t.title = "Your Game"
   t.author = "You"
   t.screen.fullscreen = false
   t.screen.vsync = false
   t.screen.fsaa = 0
   t.screen.height = 600
   t.screen.width = 800
end
it's confusing. Apart from that good tutorial ;)
Post Reply

Who is online

Users browsing this forum: Ahrefs [Bot], Amazon [Bot], Bing [Bot], Google [Bot] and 5 guests