Animated Water & Scripting

posted in Yar
Published February 11, 2005
Advertisement


Well, I think I just about have the water animation tiles done, I'll get a screenshot up later tonight. The other big thing that I have been working on was how to move a character between tiles. So I started work on my Path class which will handle all movements of my Actors.

Its going something like this:
Path path = new Path();path.createNode(0, 0, 0, 50);path.createNode(1, 5, 0, 50);path.createNode(2, 10, 0, 50);path.createNode(3, 15, 0, 50);path.createNode(4, 20, 0, 50);path.createNode(5, 25, 0, 50);path.createNode(6, 30, 0, 50);path.createNode(7, 35, 0, 50);path.createNode(8, 40, 0, 50);Actor actor = new Actor();actor.attachPath("Move_Right", path);


All in all a lot of the code is similar to my Animation class that handles changing the animation frames. In the update(long milliseconds) I change the animation frames depending on how much time has passed. So in my path class, I use relative absolute pixel drawing (this is a wierd term... but it just means that it is not being drawed off of its internal X,Y values).
With the Actor.attachPath() medthod, it will be used in my scripting engine so when I write something like this:

Map.createNew(10,10);Map.fillTiles(0,0,10,10,"tile_grass","passable",1,"tile_vert_01");test_actor = Actor.createNew("Character",0,0);test_actor.attachAnimationFromFile("test_sprite_01.anm");test_actor.attachPathFromFile("Move_Right", "m_r.pth");test_actor.setActivateEvent("Move_Right");


I also have the option of loading events from file, making the scripting even better :)

Anyway, back to coding... Starting to work on the in game map modifcation methods. This will be the start of the map maker.

-=EDIT=-
Found an old screenshot from back when I was writing my engine in PHP!!! It was going to be an online game, and it was written in PHP and used the GD library for graphics...
Previous Entry Another ARG!!
Next Entry Poster
0 likes 0 comments

Comments

Nobody has left a comment. You can be the first!
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Profile
Author
Advertisement

Latest Entries

!!!!!!!

671 views

MIDI Keyboard v1.7

1540 views

Yar.

1209 views

Orchestra Recording

1324 views

MIDI Keyboard v1.5

1459 views

Registration

1324 views

Ahhh!!!

1090 views

Um... yeah...

1076 views
Advertisement