people playing: 78, servers online: 28, games played: 135,905,831 Top Player: Shmevin

  Toribash Community » Toribash » Mods » Lua scripts
Register FAQ General Rules Community
Reply
 
Thread Tools Display Modes
Old Mar 22, 2016   #1
barbarbar
Junior Member
 
Brown Belt
Join Date: Jan 2016
Posts: 12



[LUA] BVH exporter
Here is the script I wrote that converts Toribash-4.95 replay .rpl file to the Biovision Hierarchy .bvh format.
It is based on NutHug's Replay Recorder script http://forum.toribash.com/showthread.php?t=439010

Usage is basically the same.
First remove space symbols from the replay you want to export.
Download script to data/script, load it ingame "/loadscript rpl2bvh.rpl", run "/tobvh playerid input output startframe endframe"

playerid: "0" or "tori", "1" or "uke".
input: "myreplay", "/myfolder/myreplay"
output: "bvhfile", "/folderforbvh/bvhfile"
startframe: frame you want start recording from. If empty or zero last frame is taken.
endframe: frame you want end recording. If empty its zero frame.

Examples:
/tobvh 0 large large
/tobvh uke /myreplays/awesome /bvhs/fyeah 1000 400
/tobvh 1 bar bar1 0 500

Additional setup:
By default it writes every second frame to bvh. To change this open the script file and in the very top change the "sampling" value.
To change the size of exported figure use the "scale" value. By default I've put it to 10 so that it displays better in bvh_player. In Blender you can easily adjust it.

Now you can view your replay in any bvh players like http://www.oshita-lab.org/software/bvh/index.html or http://bvhacker.com/. Note however it's 90 degrees rotated than expected, because of difference in TB and bvh. Might change it in future.

But more importantly you can open it in any major 3d software and use to animate a character! Also you can make a better render using this awesome tori models http://forum.toribash.com/showthread.php?t=188623.

There is a drawback however, bvh format have no support of stretching, therefore you'll have to edit a bit the animation to look better, and it takes time.

Here is the video I've made using the script:
https://www.youtube.com/watch?v=fLlUYQTGwwg
Attached Files
File Type: lua rpl2bvh.lua (8.1 KB, 49 views)

Last edited by barbarbar; Mar 22, 2016 at 09:30 PM..
barbarbar is offline   Reply With Quote
Old Mar 22, 2016   #2
AlphaN00b
Chatterbox
 
3rd Dan Black Belt
Join Date: Sep 2014
Posts: 4,606
Clan: Elite



seems interesting
look like you did a good job on it
i'll give it a try later
ORMO
AlphaN00b is offline   Reply With Quote
Old Mar 23, 2016   #3
barbarbar
Junior Member
 
Brown Belt
Join Date: Jan 2016
Posts: 12



AlphaN00b Thanks!
barbarbar is offline   Reply With Quote
Old Mar 27, 2016   #4
TorixDemon
Senior Member
 
4th Dan Black Belt
Join Date: Sep 2014
Posts: 1,357



Awesome. Now I can finally make 3D fights and add awesome music to it.
Little advanced but I will try
TorixDemon is offline   Reply With Quote
Old Nov 17, 2016   #5
matarika
Senior Member
 
7th Dan Black Belt
Join Date: Apr 2011
Posts: 1,041
Clan: Evolution



how do you apply the bvh motion file to a rigged model. Such as the Toribash model.
Hey Check out my Replay Thread! :D HERE
matarika is offline   Reply With Quote
Old Nov 26, 2016   #6
Velair
ub3r
 
2nd Dan Black Belt
Join Date: Mar 2012
Posts: 3,098
Clan: Aether



Originally Posted by matarika View Post
how do you apply the bvh motion file to a rigged model. Such as the Toribash model.

not to backseat or anything but google is helpful

but here
[12:47:42 PM] Nate W™: Naming a porn website "Brazzers" is really considerate because the name can be typed entirely with the left-hand.
Velair is offline   Reply With Quote
Old Feb 2, 2017   #7
kankeyta
Junior Member
 
Blue Belt
Join Date: Aug 2014



i recorded a video about this

https://www.youtube.com/watch?v=9XIgM25V3CE
kankeyta is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +1. The time now is 09:49 AM.




Powered by vBulletin® Version 3.8.2
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
ragdoll fighting game physics fighting game ragdoll fighting physics funmotion joints martial arts karate pc mac free game turn based game