The Daily Click ::. Forums ::. Klik Coding Help ::. How can I get MMF2 to refer to an external graphic file for an active object's animation frames?
 

Post Reply  Post Oekaki 
 

Posted By Message

Jack Crow



Registered
  04/04/2007
Points
  15
7th January, 2008 at 01:45:34 -

I've been at it with TGF and now MMF2 and I've always wanted to somehow allow users to create their own modifiable grahpics or 'skin sets', if you will, so as to allow for maximum customization. You know, to add a level of depth to the gameplay.

I've been programming for MMF2 for a while, now, so there aren't many ideas that are new to me. I've created a full-length game, an open development engine with a level creator, etc., but still the only way I've found to use external graphics in-game is using the "Picture" BG object.

If there's an extension or a very complex method to get this to work, I don't really care. I'm willing to sit down for a week or so just to get this to work for my newest project. There are only two things I'd like to make sure of with this process.

1. It can support transparency.
2. The hot and action spots remain in their proper places on the original active object.

Please, if anyone has any pointers, help me out here.

 
n/a

Hernan



Registered
  04/03/2003
Points
  707

VIP Member
7th January, 2008 at 04:58:11 -

I think it's the load frame action you're looking for. You can find it in the actions of an Active object, under Animation.

 
This space is for rent

viva/volt

Awesome Sauce

Registered
  26/08/2006
Points
  1694

Game of the Week WinnerSilverNova MemberKlikCast StarVIP Member
7th January, 2008 at 05:52:03 -

You'll notice some fairly long load times when you load them at runtime though, you could *try* using textblitter to display the images too.

 
Image
http://bfollington.tumblr.com

Eternal Man [EE]

Pitied the FOO

Registered
  18/01/2007
Points
  2955

Game of the Week WinnerHero of TimeLOL SignI am an April Fool
7th January, 2008 at 18:31:58 -

I know there is a way, just don't know how. The Underside uses it.

 
Eternal Entertainment's Code'n'Art Man

E_E = All Indie


...actually Ell Endie, but whatever.
Image
Image

viva/volt

Awesome Sauce

Registered
  26/08/2006
Points
  1694

Game of the Week WinnerSilverNova MemberKlikCast StarVIP Member
7th January, 2008 at 23:17:01 -

The underside uses text blitter for cutscenes I'm pretty sure, enemies and the player when actually playing aren't loaded externally.

 
Image
http://bfollington.tumblr.com

alastair john jack

BANNED

Registered
  01/10/2004
Points
  294

GOTW WINNER CUP 1!GOTW WINNER CUP 2!GOTW WINNER CUP 3!VIP MemberMushroomI am an April Fool
8th January, 2008 at 00:12:33 -

I usually just use text-blitter to make animations with external stuff.

 
lol

Jack Crow



Registered
  04/04/2007
Points
  15
8th January, 2008 at 10:56:46 -

Just to clear things up, I want to make animations import from external files when they're played, or refer to them. So that when you're done creating the game, the user can modify them to whatever they please or download a character mod set of animations.

And the last time I imported animations and changed them afterward in the .bmp they didn't take effect in the game.

 
n/a

Jack Crow



Registered
  04/04/2007
Points
  15
8th January, 2008 at 11:24:40 -

Ee gad! I think I found my solution: the AlphaChannel Object!

It allows you to load BMP, JPEG, and GIF files externally, as well as PNGs with variable transparency. And you can attach any movement type to the object.

Now I know what I have to do. The only thing left to answer is.... how do I get it to load externally? When I bring up the dialog to load alpha/image from external PNG, all I get is the ordinary "enter value for your expression here," type dealy. Should I use the file object in conjunction with this? Either way, I'm going to test it out and tell you guys what I come up with.

 
n/a

\/\/olf

Creative Genius

Registered
  06/08/2005
Points
  76

VIP Member
9th January, 2008 at 02:52:25 -

Get it to get the value from a text box (edit object). Appdrive$ + appdir$ + (whatever the user inputs or whatever you have planned).

Actually, it would be better if theres some folder in which there are all the pics for a sprite. You can make sure that everyone names the walking frames properly, etc. e.g, Walk_001, Walk_002 and so on. The same should be the case with other animations.

That way, all you ahve to do is when a certain button is pressed, a certain picture is loaded but from a user defined directory.

E.g,

Right is pressed --> load pic, appdrive$ + appdir$ + (USER DEFINED FOLDER) + Walk_right_001.gif

 
Image

www.OldMansTale.net
Sign the Petition! Go go Go!!
   

Post Reply



 



Advertisement

Worth A Click