ËNVY (LÖVE Framework)

Showcase your libraries, tools and other projects that help your fellow love users.
Post Reply
User avatar
Kuromeku
Party member
Posts: 166
Joined: Sun Jul 20, 2008 5:45 pm

ËNVY (LÖVE Framework)

Post by Kuromeku »

Image

After LÖVE comes ËNVY.

So I'm making a framework that will help you on your way to making a great game. It's work in progress at the moment and can't really be used at it's current state.

Image

ËNVY is a LÖVE Framework which should help you all to make great games for love. It includes everything that kudoLib (http://love2d.org/forum/viewtopic.php?f=5&t=160) has and much more. It has an entity system to help with creating new types of entities as well as spawning them easily. It has hooks so that you can hook into different functions that are called both by the engine and by ËNVY.

Each entity has callbacks such as onSpawn() and onCollision(data, contact) which you can override (and soon derive from) when you create your custom entities.

When ËNVY is done there will also be a weapon creation system as well as the entity creation system. You'll be able to assign your created weapons to different entities, there'll also be a simple AI library so that you can easily create enemies too.

If you take a look at this really early version of ËNVY you can get used to the structure, as well as the "entities" directory you'll soon see directories like "weapons" and "characters".

Note: The example game that comes with ËNVY is now Wrath, you will be able to see how any new features work by looking at the Wrath source code.

Sorry for the big file size increase, it now includes sounds because I'm using Wrath as the example game.

Image

Version: Phase 14.
Download:http://kudomiku.com/dump/lua/envy/envy.love.
Changelog:

Code: Select all

[Phase 14]
	* Changed envy.entity.class:destroy() to envy.entity.class:destroy(force).
	* Fixed a bug in the example gamemode where dying would allow you to pass through walls (didn't destroy the border entity correctly).
	* Added getValid() checks in envy.entity.class:getAlive() and envy.entity.class:destroy(force);
	* Added envy.entity.class:getDestroyed().
	* Added unless an entity is forcefully destroyed, it'll be destroyed at the end of the frame to avoid crashes.
[Phase 13a]
	* Added envy.control.class:stretchToParent(spacing).
	* Added envy.util.drawRoundedBox(x, y, width, height, radius, drawType).
	* Added envy.util.round(number).
	* Added envy.vector:newFromRandom().
	* Added envy.entity:onInitialize() is now envy.entity:onInitialize(arguments).
	* Added envy.control:onInitialize() is now envy.control:onInitialize(arguments).
	* Added envy.map:onInitialize() is now envy.map:onInitialize(arguments).
	* Added the ability to parse arguments to an entity's onInitialize callback with envy.entity.add(s_Class, t_Arguments, b_World).
	* Added the ability to parse arguments to a control's onInitialize callback with envy.control.add(s_Class, t_Parent, t_Arguments).
	* Added the ability to parse arguments to a map's onInitialize callback with envy.map.load(s_Class, t_Arguments).
	* Changed the style of the GUI.
	* Changed the control's onDraw function to have position, width and height arguments.
	* Changed the type()'s of Controls, Entities, etc to proper ones.
	* Changed envy.defaultFont to ENVY_FONT.
	* Fixed a bug that osuf oboys pointed out to me, thanks osuf oboys.
[Phase 13]
	* Added envy.control.class:stretchToParent(spacing).
	* Added envy.util.drawRoundedBox(x, y, width, height, radius, drawType).
	* Added envy.util.round(number).
	* Added envy.vector:newFromRandom().
	* Changed the style of the GUI.
	* Changed the control's onDraw function to have position, width and height arguments.
	* Changed the type()'s of Controls, Entities, etc to proper ones.
	* Changed envy.defaultFont to ENVY_FONT.
[Phase 12]
	* Added envy.map library.
	* Added onError(message) hook.
	* Added onMapLoad(map) hook.
	* Added onDrawMap(map) hook.
	* Added onMapUnload(map) hook.
	* Added the world is now automatically created when a map is loaded. If you really must
	get the world, you can use envy.map.getWorld().
	* Added if you don't specify a world to put an entity in when using envy.entity.add, then it
	will automatically add it to the map's world - if a map is active.
	* Added envy.entity.class:getWorld().
	* Added envy.util.error(message).
[Phase 11]
   * Added envy.util.getSound and envy.util.newMusic and envy.util.getImage.
   * Added envy.util.isBetween(value, minimum, maximum).
   * Added envy.vector.class:angleBetween(vector).
   * Added envy.vector.class:moveTowards(angle, speed).
   * Added envy.vector.class:moveAtAngle(angle, speed).
   * Added envy.vector.class:rotate(angle).
   * Added envy.entity.class:addVelocity(velocity) (adds to the entity's velocity).
   * Added envy.entity.include(file).
   * Added envy.entity.includeAll(directory).
   * Added envy.control.include(file).
   * Added envy.control.includeAll(directory).
   * Added envy.util.enumerate(directory);
   * Added envy.util.include(file);
   * Added envy.trace.class:setName(name).
   * Added envy.trace.class:getName().
   * Added envy.util.reverseTable(base).
   * Added anything in game/entities/ is included automatically.
   * Added anything in game/controls/ is included automatically.
   * Added if you return true on a GAME hook, the normal hooks will not run.
   * Added if you return true on a hook, the rest of the hooks will not run.
   * Added canTraceHit hook for entities (return false to disallow the trace to hit it).
   * Added onInitialize hook for entities.
   * Added onHookError hook.
   * Added canPressKey and canPressMouse hooks (return false to disallow).
   * Added onDrawControls hook.
   * Added the envy.control library.
   * Added the envy.module library.
   * Changed onMousePressed and onMouseReleased arguments to (button, position).
   * Changed the way entities work you no longer need to define ENTITY and register it in the file. This is done automatically
when it is included.
[Phase 10]
   * Added envy.util.getSound and envy.util.newMusic and envy.util.getImage.
   * Added envy.util.isBetween(value, minimum, maximum).
   * Added if you return true on a GAME hook, the normal hooks will not run.
   * Added if you return true on a hook, the rest of the hooks will not run.
[Phase 9]
   * Added the envy.vector:newFromAngle(angle) function (thanks Borsty).
   * Added more functions to the entity library, so in most cases you can just do things like
   * Added entity hook onShapeCollision(data, contact).
   * Added game hook onCollision(first, second, contact).
   entity:setDamping() rather than entity:getBody():setDamping(). But it's your choice.
   * Changed the way the takeDamage and onZeroHealth thing works. Borsty you should
   switch over to takeDamage and just let us take care of the health. If you want to set
   an entity's health just do entity:setHealth(health) when they spawn!
   * Changed the way that the onEntityCollision callback handles the collisions.
   * Changed onCollision to onEntityCollision.
[Phase 8]
	* Improved the - currently shitty - parenting system.
	* Added the ability to make entities derive from others (see example game).
	* Added the envy.key library. Check it out, it's just a simple library to convert a key to a lower case or upper case translation of it. Don't get the wrong idea, it isn't string.lower and string.upper - haha.
	* Added more stuff to the example game (Wrath) so that you can understand how things work more.
	* Changed the trace system so that masks could be added. It has rendered the trace system unusable until I can figure out how to work/understand the setMask and setMaskBits functions properly. Until then you may want to use an old trace.lua file.
[Phase 7]
	* Added a ton more functions to the entity library.
	* Added health to entities. What is done when the entity reaches zero health is set onZeroHealth().
	* Added more stuff that I am too lazy to mention.
	* Fixed a ton of stuff that I am too lazy to mention.
[Phase 6]
	* Added a ton more functions to the entity library and changed the way that drawing works. See the prop_physics as an example.
	* Added the envy.trace library. It's for trace lines, take a look at it to see how it operates.
	* Added a licence. See the licence.txt for more information.
	* Added the onTakeDamage and takeDamage functions for entities.
	* Added more stuff and fixed more stuff that I can't be bothered to log.
[Phase 5]
	* Removed useless drawLaser and drawMode.
	* Removed prop_bullet example entity.
	* Removed all of the tutorial junk.
	* Added a game folder.
	* Added envy.timer library.

[Phase 4]
	* Added a decent jumping system to the prop_physics.

[Phase 3]
	* Posted the ËNVY thread on the LÖVE forums.
	* Began the changelog.
Licence

Feel free to use any or all parts for whatever you please. If you have any questions about the source, do ask. LPCL with myself as community - clauses to be invoked at any time.
Last edited by Kuromeku on Fri Feb 20, 2009 10:48 pm, edited 14 times in total.
User avatar
SamPerson12345
Prole
Posts: 41
Joined: Sat Aug 30, 2008 5:35 pm

Re: ËNVY (LÖVE Framework)

Post by SamPerson12345 »

Looks like a great idea! But the file you put up doesn't work. D:
SnakeFace
Prole
Posts: 28
Joined: Tue Aug 19, 2008 2:45 pm

Re: ËNVY (LÖVE Framework)

Post by SnakeFace »

When do you expect it to be usable? And will games made using previous frameworks be easy to integrate into new ones?
Lovely quotes
somewhere within the jungle of administrative doom - rude
User avatar
rude
Administrator
Posts: 1052
Joined: Mon Feb 04, 2008 3:58 pm
Location: Oslo, Norway

Re: ËNVY (LÖVE Framework)

Post by rude »

Maybe I'll give this a try. ^^

... looks like there's something wrong with the archive, though. Windows claims it's corrupt, and LOVE claims that the game doesn't exist.
User avatar
Kuromeku
Party member
Posts: 166
Joined: Sun Jul 20, 2008 5:45 pm

Re: ËNVY (LÖVE Framework)

Post by Kuromeku »

Fixed. I did it as a .rar and not a .zip.
User avatar
needcoffee
Prole
Posts: 11
Joined: Tue Aug 19, 2008 8:10 am

Re: ËNVY (LÖVE Framework)

Post by needcoffee »

I tried this and also "Zombie Crush", but it won't run. It isn't able to handle video...

Code: Select all

~ > love envy_phase_3.love 
INIT love.filesystem [PhysFS]
INIT love.graphics [OpenGL/DevIL/FreeType]
INIT love.audio [SDL_mixer]
INIT love.timer [SDL]
INIT love.mouse [SDL]
INIT love.keyboard [SDL]
INIT love.physics [Box2D]
INIT love.system [Generic]
Could not set video mode: Couldn't find matching GLX visual
Could not set video mode: Couldn't find matching GLX visual
Could not set display mode.
QUIT love.system [Generic]
QUIT love.physics [Box2D]
QUIT love.keyboard [SDL]
QUIT love.mouse [SDL]
QUIT love.timer [SDL]
QUIT love.audio [SDL_mixer]
QUIT love.graphics [OpenGL/DevIL/FreeType]
QUIT love.filesystem [PhysFS]
I'm running Linux (Ubuntu, Kernel: 2.6.24-19-rt) with a Radeon 9600 (fglrx, OpenGL 2.1.7659).
User avatar
Kuromeku
Party member
Posts: 166
Joined: Sun Jul 20, 2008 5:45 pm

Re: ËNVY (LÖVE Framework)

Post by Kuromeku »

Maybe because it is set to run at fullscreen at 1024x768?
User avatar
CandleJack
Prole
Posts: 2
Joined: Wed Jul 30, 2008 2:15 am

Re: ËNVY (LÖVE Framework)

Post by CandleJack »

Can you make the background a PNG? JPEG compression makes it look terrible.
User avatar
Kuromeku
Party member
Posts: 166
Joined: Sun Jul 20, 2008 5:45 pm

Re: ËNVY (LÖVE Framework)

Post by Kuromeku »

You could do that :)
User avatar
qubodup
Inner party member
Posts: 775
Joined: Sat Jun 21, 2008 9:21 pm
Location: Berlin, Germany
Contact:

Re: ËNVY (LÖVE Framework)

Post by qubodup »

Kudomiku wrote:You could do that :)
CandleJack can't because it doesn't have the source file and because you didn't give any permissions (there is no license/copyright info/terms of use)

In case you decide to use some license, remember to state the font license (appears to be "unknown")
lg.newImage("cat.png") -- made possible by lg = love.graphics
-- Don't force fullscreen (it frustrates those who want to try your game real quick) -- Develop for 1280x720 (so people can make HD videos)
Post Reply

Who is online

Users browsing this forum: No registered users and 44 guests