Jump to content


Photo
- - - - -

Simple 3d Walk Animation - revisited


  • Please log in to reply
54 replies to this topic

#21 weckar

weckar

    Helping Hand

  • New Member
  • 1946 posts

Posted 02 June 2010 - 11:15 PM

In quality it reminds me of Yomamasmama's old 3d walking animation example...

EDIT: actually, I'm not sure who made that...

Edited by weckar, 02 June 2010 - 11:44 PM.

  • 0

#22 sub

sub

    EVIL GENIUS

  • GMC Member
  • 1852 posts
  • Version:GM6

Posted 03 June 2010 - 03:23 AM

hmm.. this seems to be what i'm trying to achieve with my giant robot walk animation. (killbot game link below)
i got mine to work, but.. it's crazy.. and uses too many shape transformations.. and i hate it.. but i went and added elbows and knees.. (yours doesn't seem to have that?)

all this time i've been pestering Tepi, Icuurd, Slayer, etc into fixing my problem when it seems i should have been pestering you! :blink:

i don't know how you're doing it (will d/l soon) ..but if this could utilise the 3d particle dll (by Icuurd) then i think the methods could be shortened, and models can be used instead of shapes (much faster, and much faster again by using the p3d dll.)

are you able to locate the x,y,z location of an objects tip? (like a bone system?) i wasn't able to do that???

...awesome job, even without running it yet, i know this is going to help me achieve what i'm after.
  • 0

#23 Drandula

Drandula

    Mister Pixel

  • GMC Member
  • 269 posts

Posted 03 June 2010 - 10:09 AM

Well, I didn't include elbows etc. because it would have been too complicated. And this is Simple 3D Walk animation.

And I haven't ever used DLL's, expect one. So DLL's you are talking about makes totally no sense to me ^^"

No, you cannot pinpoint x,y,z positions of shapes tip. But I think it can be done with lengthdir_'s.
Then you could do elbows and everything else.
  • 1

#24 Funkyfreddo

Funkyfreddo

    GMC Member

  • New Member
  • 36 posts

Posted 18 June 2010 - 11:31 PM

You wonderful wonderful person ^_^

This is without a doubt, one of THE best 3D engines I seen created. So easy to follow!
Do you mind if i use it in a game/engine i will give credit and change textures, and maybe add more features to the person.

Seriously though, I wish you could give rep on this forum, cause if you could *button mashes on rep button* xD
Btw, if anyone wants a fun little added extra.

I'm building my engine, and I decided to release this ^_^ its this engine incorporated with mine (mine = unfinished)
http://dl.dropbox.co...gine+Player.gmk
Space= move character on Z axis (upwards)
Ctrl= Move character on Z axis (downwards)
Arrow Keys= Move Character (along z plane)

Box collision,
collide with top of box!!!!

If anyone can make it that you fall off the edge, PLEASE POST! I Cannot figure it out!!

Edited by Funkyfreddo, 18 June 2010 - 11:33 PM.

  • 0

#25 Shadowrend

Shadowrend

    Master of Shadows

  • GMC Member
  • 1571 posts
  • Version:GM8

Posted 19 June 2010 - 10:03 AM

You forgot to add gravity. Download the official FPS tutorial, you have a good gravity example there. Also enable gravity only when space and ctrl aren't pressed.
  • 0

#26 Funkyfreddo

Funkyfreddo

    GMC Member

  • New Member
  • 36 posts

Posted 19 June 2010 - 11:24 AM

You forgot to add gravity. Download the official FPS tutorial, you have a good gravity example there. Also enable gravity only when space and ctrl aren't pressed.


I'm working on gravity but it's not going too well, i'm using this character animation engine added to my own (incomplete one) but when the chara goes up, he dont come down straight away :(
  • 0

#27 Drandula

Drandula

    Mister Pixel

  • GMC Member
  • 269 posts

Posted 19 June 2010 - 11:44 AM

Do you mind if i use it in a game/engine i will give credit and change textures, and maybe add more features to the person.

Well of course you can use it. Didn't I write in first post, just add me in credits.

About gravity, set in create event
z=0 zspeed=0 zg=0
In step event
if z <= 0 {z=0 zspeed=0 zg=0} else {z+=zspeed zspeed+=zg zg=-(force of gravity)}

For jump key, for example Space
if z=0 zspeed =(force of jump)

Thats how I remember the base of making gravity for 3D game.

~Drandula~
  • 1

#28 Funkyfreddo

Funkyfreddo

    GMC Member

  • New Member
  • 36 posts

Posted 19 June 2010 - 02:57 PM

Well i have the bulk of that, but because of the way my collisions work, that may not go so well (the jumping) I tried it and it failed.. lol, can you take a look at my engine, (jump just goes on forever) and see whats up? :P

Download From Dropbox

Everyone - Please don't rip the Collisions :) they took me over a day to code! This engine alone has taken up the bulk of my week and its nowhere near finished! (with changing blocks ect, i started off with buildings, then buildings and a flat car sprite... then buildings with walking dude (thanks to drandula) now blocks, with collisions, with walking! :D)

(BTW its only for my games, so dont go saying it wont suit many others.. cause i'll release the source after i release my games. "/)


**FIXED***************************************************************************
Oo i fixed it using this method (incase anyone wants to know):
When the player collides with the top of a block at 52z, jumptrue=true, in the jump event, before the actions, it says if(jumptrue=true){jump code}

when he collides with the top of the object, it also sets jumpheighest to 102, when the player reaches this number, jumptrue=false

And I change the jumpheight when he goes on a larger block. :)

Its going to take me a while to comment it all so i'll know what it does if i forget XD

Test it out :):
http://dl.dropbox.com/u/7310599/Engine%2BPlayer%28WIP%29.exe

Controls- Space to jump
Arrow keys to move

Edited by Funkyfreddo, 19 June 2010 - 03:58 PM.

  • 0

#29 Drandula

Drandula

    Mister Pixel

  • GMC Member
  • 269 posts

Posted 19 June 2010 - 04:09 PM

^ Jumping is bit odd, doesn't feel real. I fixed it by myself:
http://www.mediafire.com/?yvdr0yimajm

~Drandula~

Edited by drandula, 19 June 2010 - 04:09 PM.

  • 1

#30 Funkyfreddo

Funkyfreddo

    GMC Member

  • New Member
  • 36 posts

Posted 19 June 2010 - 04:20 PM

Thanks much man, yeh, mine was very... sticky :) that really helps man, thanks!!!
  • 0

#31 Glen

Glen

    GMC Member

  • GMC Member
  • 840 posts
  • Version:GM:Studio

Posted 19 June 2010 - 05:34 PM

Very Nice. I like the movement.
  • 0

#32 sub

sub

    EVIL GENIUS

  • GMC Member
  • 1852 posts
  • Version:GM6

Posted 20 June 2010 - 10:35 AM

hi again.

lengthdir statements will only work in 2D mode (i've tried) ~ the vectors change in 3D mode, a more advanced calc is needed.

thanks for your time tho' :) - if you want the code pieces for adding elbows and knees just drop me a PM.
  • 0

#33 smash ball

smash ball

    Volcanic Light

  • GMC Member
  • 1126 posts
  • Version:GM7

Posted 20 June 2010 - 04:31 PM

This great, just what I need to do a remake of OOT! I just figured out how to make my character jump off ledges (I am using another 3D example for terrain). This did take a bit of editing to make it work for my crude ellipsoid and cylinder shapes!
  • 0

#34 ikkentim

ikkentim

    GMC Member

  • New Member
  • 1 posts

Posted 25 June 2010 - 08:27 PM

thanks verry much!!!
  • 0

#35 slyx114

slyx114

    GMC Member

  • New Member
  • 1 posts

Posted 19 August 2010 - 06:56 AM

Excelent example. 6/5
  • 0

#36 thatshelby

thatshelby

    GMC Member

  • GMC Member
  • 3823 posts
  • Version:GM8

Posted 09 November 2010 - 06:37 PM

It's a bit of a necropost but this is AMAZING. I found a link in your signature (And was curious, I'm into 3D all of a sudden) and I LOVE IT! I just wish it was a little better commented. Do you mind if I PM you if I don't understand it?
  • 0

#37 Drandula

Drandula

    Mister Pixel

  • GMC Member
  • 269 posts

Posted 09 November 2010 - 10:02 PM

Thanks :)

Yeah, its a bit of gravedigging, but I don't mind.
You can send PM's, I'll try answer as well as I can.
I can add more comments in file, I don't see it as big job.

Tero Hannula

Edit. 600+ downloads

Edited by drandula, 09 November 2010 - 10:18 PM.

  • 1

#38 Drandula

Drandula

    Mister Pixel

  • GMC Member
  • 269 posts

Posted 16 November 2010 - 01:11 AM

Simple 3D walking animation and 3D platform example imbued together:

Posted Image

This example is better commented.

Edited by drandula, 16 November 2010 - 01:13 AM.

  • 1

#39 ck2k

ck2k

    GMC Member

  • New Member
  • 68 posts

Posted 23 November 2010 - 02:14 PM

Awesome example!

But I've got a "small" problem.
Currently I'm making a 3rd person horror shooter and off course there will be zombies (somehow everyone makes a zombie game :D)
Anyway, I want them to hold their arms always in front of them and just shaking a bit up and down. (yeah my game is based on stereotypes)
i solved this editing the end step event:

// Hands rotation
hand_l_x = 55
hand_l_y = 340
hand_l_z = image_angle + 95


hand_r_x = -85
hand_r_y = 250
hand_r_z = image_angle-25

I found these values with trying around a little bit.. but it's not statisfying me..
I'm sure, you as the developer of that script can suggest me a much better version, don't you?

it would be enugh if the arms had an angle of 90° and move between 85° and 95° while walking or something.. ^^

Edited by ck2k, 23 November 2010 - 02:35 PM.

  • 0

#40 mironic

mironic

    GMC Member

  • New Member
  • 783 posts

Posted 23 November 2010 - 04:40 PM

nice but all of my reading of it and studying... i have no clue how it works...
  • 0




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users