Just Getting Started???
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
Just Getting Started???
Hi. I'm new to Love, but not to Lua. I've used Lua in many other scenarios, but I have to develop a videogame about taking over the world. The Love format is confusing me with the love.draw, etc. So, how would I start..?
Re: Just Getting Started???
Hi there! I'm more of a noob than you are, but I've collected a few interesting links on how to get started.
This one is very noob oriented, but it shows you how to handle some graphics:
https://github.com/kikito/love-tile-tutorial/wiki
This one deals with movement, and a bit of physics/collision:
http://www.headchant.com/2010/11/27/lov ... -must-die/
http://www.headchant.com/2010/12/31/lov ... 2-pew-pew/
(might be a bit buggy tho)
And here are some links I haven't totally checked out myself yet:
http://gamedev.tutsplus.com/articles/ho ... ve-love2d/
http://www.explodingrabbit.com/forum/en ... al-01.669/
Hope it helps! Tell me later what worked out for you.
This one is very noob oriented, but it shows you how to handle some graphics:
https://github.com/kikito/love-tile-tutorial/wiki
This one deals with movement, and a bit of physics/collision:
http://www.headchant.com/2010/11/27/lov ... -must-die/
http://www.headchant.com/2010/12/31/lov ... 2-pew-pew/
(might be a bit buggy tho)
And here are some links I haven't totally checked out myself yet:
http://gamedev.tutsplus.com/articles/ho ... ve-love2d/
http://www.explodingrabbit.com/forum/en ... al-01.669/
Hope it helps! Tell me later what worked out for you.
Re: Just Getting Started???
What about [wiki]Getting Started[/wiki]?
There's a link to some Tutorials at the end of that page, and a specific one you should read to better understand how LÖVE works. If there's something specific you don't get about them, feel free to ask! If you've read them already but still you don't get it, what aren't you getting exactly?
love.draw is a user defined function that gets called about 60 times a second (in optimal conditions), once a frame. It's the function where you should put all of the code that's supposed to draw something in the window.
EDIT: If you can understand it, take a look at [wiki]love.run[/wiki] to see how LÖVE works
Ninja'd by BozoDel
There's a link to some Tutorials at the end of that page, and a specific one you should read to better understand how LÖVE works. If there's something specific you don't get about them, feel free to ask! If you've read them already but still you don't get it, what aren't you getting exactly?
love.draw is a user defined function that gets called about 60 times a second (in optimal conditions), once a frame. It's the function where you should put all of the code that's supposed to draw something in the window.
EDIT: If you can understand it, take a look at [wiki]love.run[/wiki] to see how LÖVE works
Ninja'd by BozoDel
lf = love.filesystem
ls = love.sound
la = love.audio
lp = love.physics
lt = love.thread
li = love.image
lg = love.graphics
ls = love.sound
la = love.audio
lp = love.physics
lt = love.thread
li = love.image
lg = love.graphics
Re: Just Getting Started???
I'm getting the hang of it now, but now I came across another problem: require() is being a complete biotch.Nixola wrote:
So, I have a file called main.lua and mainmenu.lua in the main directory, and I have a libs folder with Love Frames and a font.
I tried using
Code: Select all
require("libs.loveframes");
Is there a problem with it? The game is called uDominate (since you have to take over the world). So mhere are the filepaths:
- main.lua uDominate/main.lua
- mainmenu.lua: uDominate/mainmenu.lua
- Love Frames: uDominate/libs/loveframes
- Font: uDominate/libs/titleFont.ttf
- Robin
- The Omniscient
- Posts: 6506
- Joined: Fri Feb 20, 2009 4:29 pm
- Location: The Netherlands
- Contact:
Re: Just Getting Started???
If you could upload a .love of your game, we could take a look at it. See the wiki on how to make a .love.
Help us help you: attach a .love.
Re: Just Getting Started???
About the semicolons, I think they're just ignored in Lua; the require error seems to be weird, are you sure that's the line that throws it?
lf = love.filesystem
ls = love.sound
la = love.audio
lp = love.physics
lt = love.thread
li = love.image
lg = love.graphics
ls = love.sound
la = love.audio
lp = love.physics
lt = love.thread
li = love.image
lg = love.graphics
- Roland_Yonaba
- Inner party member
- Posts: 1563
- Joined: Tue Jun 21, 2011 6:08 pm
- Location: Ouagadougou (Burkina Faso)
- Contact:
Re: Just Getting Started???
Just in addition to that, checkout BlackBulletIV's tutorials, especially the Lua for programmers series.BozoDel wrote:Hi there! I'm more of a noob than you are, but I've collected a few interesting links on how to get started
Re: Just Getting Started???
I fixed the require error. Apparently, parentheses shouldn't be in it. :\
New problem though. I tried making a new font, but it says the font file doesn't exist. It's in the same directory.
I used:
titleFont.tff is in the same directory as my lua file. The error is: "graphics.lua.1252: Could not open file titleFont.tff. Does not exist."
I'm pretty sure it exists.
New problem though. I tried making a new font, but it says the font file doesn't exist. It's in the same directory.
I used:
Code: Select all
titleFont = love.graphics.newFont("titleFont.tff",50);
I'm pretty sure it exists.
- DaedalusYoung
- Party member
- Posts: 413
- Joined: Sun Jul 14, 2013 8:04 pm
Re: Just Getting Started???
The font file extension is probably ttf, not tff.
Re: Just Getting Started???
-facepalm- Thanks.DaedalusYoung wrote:The font file extension is probably ttf, not tff.
Wait a second, now I'm getting another error! D:<
So on my main.lua, I have a line that says:
Code: Select all
require"mainmenu.lua"
main.lua and mainmenu.lua are both in the main directory.
Btw, I don't see the need to upload my .love file yet. When I get major errors I definitely will.
Who is online
Users browsing this forum: Ahrefs [Bot], Bing [Bot], Google [Bot] and 3 guests