Jump to content



Photo

Unity 3D and VPinMAME!


  • This topic is locked This topic is locked
1388 replies to this topic

#81 bladexdsl

bladexdsl

    Joined the elite ranks

  • Banned
  • PipPipPipPip
  • 1,234 posts
  • Location:Queensland

  • Flag: Australia

  • Favorite Pinball: Scared stiff and Congo

Posted 28 January 2012 - 12:57 AM

wait a min so hopefully this will be able to take a fp table and run it like vp complete with vp physics etc?!!

no more having to use fp?

Edited by bladexdsl, 28 January 2012 - 12:58 AM.


#82 louizou

louizou

    Enthusiast

  • Members
  • PipPipPip
  • 265 posts

  • Flag: France

  • Favorite Pinball: BlackKnight2k T2 Twilight Zone

Posted 28 January 2012 - 01:28 AM

QUOTE (epthegeek @ Jan 27 2012, 08:17 PM) <{POST_SNAPBACK}>
QUOTE (louizou @ Jan 27 2012, 11:40 AM) <{POST_SNAPBACK}>
I use a c# interpreter component in unity for launching the table script.
So you'll just have to replace the FP script by the new ,save the table , and BINGO !!

Actually i do not master the interpreter at all so the syntax is a little boring .But it works

here is the T2 script :

... bunch of code ...

All those sendmessage are boring to type and object affectation must be done by the GameObject.Find method.
That's because i create the table in unity and then launch the interpreter.
I've planed to doit in another way, launching the interpreter and create the table from it, so the table objects will be directely accesible by the script.


So that's all the code for the lamps, what about switches and other solenoid driven mechanisms? Don't have any of that running yet?



yes for the lamps , you don't need more ...

table.SendMessage("Set_FirstL",11); // the number of the first used light
table.SendMessage("Set_LastL",88); // the number of the last one

table.SendMessage("addlamp","LightBonus2x$11"); // light declaration ( the $ is actually used as a token to separate the name of the light in FP and the number of this one ROMside)


Switches are not handled at the moment, but it will be the same thing.

QUOTE (maceman @ Jan 27 2012, 09:58 PM) <{POST_SNAPBACK}>
Wow. that is amazing. I am trying to get a handle on what is happening here. So is this UW's VP table with some sort of 3d rendering? I don't get what i am seeing just yet.

Flippers are slow for me, but i understand this is just the sample. Very interesting, i just don't get it yet smile.gif

Maceman



Yes flippers were very bad in the bad cats prototype.
But don't worry about this . when the flippers will be added , i'll try to make them supa tweakable(and all this by scripting)

why hiding physics parameters essential to the gameplay ?
for the same reason as not implementing VPM directly in FP (you see what i mean)

uplogomini.png

Continue helping us at [email protected]

 


#83 louizou

louizou

    Enthusiast

  • Members
  • PipPipPip
  • 265 posts

  • Flag: France

  • Favorite Pinball: BlackKnight2k T2 Twilight Zone

Posted 28 January 2012 - 01:42 AM

QUOTE (bladexdsl @ Jan 28 2012, 01:57 AM) <{POST_SNAPBACK}>
wait a min so hopefully this will be able to take a fp table and run it like vp complete with vp physics etc?!!

no more having to use fp?


it already takes lots ol FP tables (only one known crashing the extractor => jurassik park=>needs investigation)


All the tables you can see in the vidéo are screenshots or little clips made from VPM3d , not from FP

I do my tests on those tables :

Badcats, T2 , The dark knight , IJ ,Addams family , Cyclone , Taxi , Whirlwind , doctor who , medieval madness and more .......

Forget VP or FP physics , there will be VPM3d's physics (good or bad).

FP is just used as the editor . point !

uplogomini.png

Continue helping us at [email protected]

 


#84 Dazz

Dazz

    Pinball Fan

  • Banned
  • PipPipPipPip
  • 858 posts
  • Location:Keller, Texas

  • Flag: United States of America

  • Favorite Pinball: Twilight Zone and Cyclone

Posted 28 January 2012 - 01:51 AM

QUOTE (bent98 @ Jan 27 2012, 11:43 AM) <{POST_SNAPBACK}>
QUOTE (epthegeek @ Jan 27 2012, 06:18 PM) <{POST_SNAPBACK}>
QUOTE (louizou @ Jan 27 2012, 10:49 AM) <{POST_SNAPBACK}>
At the moment my focus is putted on the table ...
As you can see in the video , there is no backglass at all.
You can be sure that there will be a cabinet view .
The backglass on the second screen is a good idea , but i'll need to create a second exe and make it comunicate with the main one .....
I don't know if unity can handle this ... with ethernet perhaps


Even without the backglass, it's be awesome just to get the main table & vpmame running together and playable. Does your method have it's own script (like vpm tables do) for working back and forth with pinmame? Should talk to one of the FP table guys about making a version of one of their tables (like glxb) that is set up however would work best for your system.

Anxious to see whatever happens, no matter what, that's for sure. dblthumb.gif


What about spanning the table, would that work?
I wouldn't even worry about spanning as it only works in XP.

Posted Image

#85 maceman

maceman

    Home Pinball Machine Collector/ Restorer

  • VIP
  • 2,271 posts
  • Location:Canada, Eh!

  • Flag: Canada

  • Favorite Pinball: ....**Haunted House**....



Posted 28 January 2012 - 01:53 AM

QUOTE (destruk @ Jan 27 2012, 07:11 PM) <{POST_SNAPBACK}>
I think this is really cool, regardless of which table file is used to import into a different physics environment.



I think it is cool as well, but i just don't yet understand the reason to do it. I mean, i guess for FP, it would be to have the ability to perhaps tweak the physics more in Unity 3D?

I thought it was something that could take a VP file and render it in 3D, then i was getting excited, as that would be superb.

I don't know enough about this, but will watch the progress. It looks promising! Does this mean that FP will be able to use VPM roms possibly?

Maceman
________________________________________________________________________________
Canada Eh!
hm_avatar.pngss_avatar.jpg MODS ys_avatar5.jpggenie_avatar.pngj2o_avatar.png

#86 bent98

bent98

    Pinball Fan

  • Members
  • PipPipPipPip
  • 1,077 posts
  • Location:NY

  • Flag: United States of America

  • Favorite Pinball: Roadshow, Haunted House, Safe Cracker

Posted 28 January 2012 - 02:01 AM

QUOTE (louizou @ Jan 28 2012, 02:42 AM) <{POST_SNAPBACK}>
QUOTE (bladexdsl @ Jan 28 2012, 01:57 AM) <{POST_SNAPBACK}>
wait a min so hopefully this will be able to take a fp table and run it like vp complete with vp physics etc?!!

no more having to use fp?


it already takes lots ol FP tables (only one known crashing the extractor => jurassik park=>needs investigation)


All the tables you can see in the vidéo are screenshots or little clips made from VPM3d , not from FP

I do my tests on those tables :

Badcats, T2 , The dark knight , IJ ,Addams family , Cyclone , Taxi , Whirlwind , doctor who , medieval madness and more .......

Forget VP or FP physics , there will be VPM3d's physics (good or bad).

FP is just used as the editor . point !



I know this is a major undertaking to program this. Just wondering is this something that will take a year or more to complete?




#87 rehab

rehab

    Enthusiast

  • Members
  • PipPipPip
  • 381 posts
  • Location:Amsterdam

  • Flag: Netherlands

  • Favorite Pinball: funhouse,AFM,MM

Posted 28 January 2012 - 05:31 AM

This looks very promising! Thanks for your hard work and I hope this succeeds!

#88 Dazz

Dazz

    Pinball Fan

  • Banned
  • PipPipPipPip
  • 858 posts
  • Location:Keller, Texas

  • Flag: United States of America

  • Favorite Pinball: Twilight Zone and Cyclone

Posted 28 January 2012 - 06:28 AM

QUOTE (maceman @ Jan 27 2012, 07:53 PM) <{POST_SNAPBACK}>
QUOTE (destruk @ Jan 27 2012, 07:11 PM) <{POST_SNAPBACK}>
I think this is really cool, regardless of which table file is used to import into a different physics environment.



I think it is cool as well, but i just don't yet understand the reason to do it. I mean, i guess for FP, it would be to have the ability to perhaps tweak the physics more in Unity 3D?

I thought it was something that could take a VP file and render it in 3D, then i was getting excited, as that would be superb.

I don't know enough about this, but will watch the progress. It looks promising! Does this mean that FP will be able to use VPM roms possibly?

Maceman


This takes tables that are created in FP, imports them into Unity. Unity is a 3d gaming/physics engine. It then communicates with VPM for the use of roms. The tables will NOT be played in the FP environment. This is NOT making FP able to use VPM roms.

Posted Image

#89 yoeyyutch

yoeyyutch

    Hobbyist

  • Members
  • PipPip
  • 29 posts
  • Location:Minnesota, USA

  • Flag: United States of America

  • Favorite Pinball: Twilight Zone

Posted 28 January 2012 - 12:48 PM

"Have you ever had a dream that you were so sure was real? What if you were unable to wake from that dream? How would you know the difference between the dream world and the real world?"





#90 Nick Warcholak

Nick Warcholak

    Enthusiast

  • Members
  • PipPipPip
  • 106 posts

  • Flag: United States of America

  • Favorite Pinball: TotAN, Twilight Zone

Posted 28 January 2012 - 03:22 PM

This looks amazing. Great work man.

Yes, the idea is that you make the table in FP's editor, which from what I understand is on the whole more user friendly than VP's editor. Then it can be exported to Unity where it can interface with VPM and have it's physics adjusted to degrees not allowed in FP. That's a win all around IMO.

#91 louizou

louizou

    Enthusiast

  • Members
  • PipPipPip
  • 265 posts

  • Flag: France

  • Favorite Pinball: BlackKnight2k T2 Twilight Zone

Posted 28 January 2012 - 03:43 PM

QUOTE (Nick War @ Jan 28 2012, 04:22 PM) <{POST_SNAPBACK}>
This looks amazing. Great work man.


Thanks a lot man

QUOTE (Nick War @ Jan 28 2012, 04:22 PM) <{POST_SNAPBACK}>
Yes, the idea is that you make the table in FP's editor, which from what I understand is on the whole more user friendly than VP's editor. Then it can be exported to Unity where it can interface with VPM and have it's physics adjusted to degrees not allowed in FP.


exactly

Edited by louizou, 28 January 2012 - 03:44 PM.

uplogomini.png

Continue helping us at [email protected]

 


#92 settingsons

settingsons

    Pinball Fan

  • VIP
  • 959 posts
  • Location:Switzerland

  • Flag: Switzerland

  • Favorite Pinball: Terminator 2 and many EM machines



Posted 28 January 2012 - 08:41 PM

Wow - that is extremely impressive! Excellent work and very exciting news.


#93 tipoto

tipoto

    Enthusiast

  • VIP
  • 296 posts
  • Location:Los Angeles

  • Flag: France

  • Favorite Pinball: Elvira and the Party Monsters ; Terminator 2

Posted 28 January 2012 - 09:25 PM

Some questions for you louizou smile.gif
Can we import directly into Unity 3D a table done with a 3D software like 3dsmax, Maya or whatever? If so, do the animations, UVW map and textures are imported as well? And what about the lighting?

Thanks! otvclap.gif

#94 louizou

louizou

    Enthusiast

  • Members
  • PipPipPip
  • 265 posts

  • Flag: France

  • Favorite Pinball: BlackKnight2k T2 Twilight Zone

Posted 28 January 2012 - 09:56 PM

Salut tipoto , et tout dabord merci pour ton mail , ca fait zizir smile.gif
Je sais pas si tu as recu la réponse , je l'ai envoyé 3 fois mais la messagerie du forum me dit 0 elements envoyés think.gif , donc j'en profite pour te remercier sur ce post.


Unity handles directly max ,fbx ,3DS ,OBJ and many more files , but only in the editor part.
At runtime it doesn't by scripting.
It handles mesh ,materials , 2 or 3 uv channels . I think it can handle baked lights for lightmapping but i don'tknow how this works....

Unity has some limited features at runtime . You can't do everything by scripting but it's great dblthumb.gif

Edited by louizou, 28 January 2012 - 09:57 PM.

uplogomini.png

Continue helping us at [email protected]

 


#95 tipoto

tipoto

    Enthusiast

  • VIP
  • 296 posts
  • Location:Los Angeles

  • Flag: France

  • Favorite Pinball: Elvira and the Party Monsters ; Terminator 2

Posted 28 January 2012 - 10:08 PM

QUOTE (louizou @ Jan 28 2012, 01:56 PM) <{POST_SNAPBACK}>
Salut tipoto , et tout dabord merci pour ton mail , ca fait zizir smile.gif
Je sais pas si tu as recu la réponse , je l'ai envoyé 3 fois mais la messagerie du forum me dit 0 elements envoyés think.gif , donc j'en profite pour te remercier sur ce post.


Unity handles directly max ,fbx ,3DS ,OBJ and many more files , but only in the editor part.
At runtime it doesn't by scripting.
It handles mesh ,materials , 2 or 3 uv channels . I think it can handle baked lights for lightmapping but i don'tknow how this works....

Unity has some limited features at runtime . You can't do everything by scripting but it's great dblthumb.gif

Oui j'ai bien reçu tes réponses, merci ! Il y a une case à cocher en bas des messages avant de les envoyer, si tu veux les voir dans la sentbox il me semble... Pas sûr...

Thanks for the quick reply, sounds very interesting! I'm gonna take a look at it and see the way it works with the import part wink.gif

#96 louizou

louizou

    Enthusiast

  • Members
  • PipPipPip
  • 265 posts

  • Flag: France

  • Favorite Pinball: BlackKnight2k T2 Twilight Zone

Posted 28 January 2012 - 10:20 PM

good luck , it's a really tricky part.(at runtime of course)

To import MS3D , i needed to port the milshape C++ importer code to c# and it's not finished .(lacks animations .... working on this at that time)

uplogomini.png

Continue helping us at [email protected]

 


#97 wtiger

wtiger

    Pinball Fan

  • VIP
  • 1,148 posts
  • Location:Los Angeles, CA

  • Flag: United States of America

  • Favorite Pinball: Junkyard



Contributor

Posted 29 January 2012 - 07:03 PM

louizou,
This is very fasinating. Thank you for sharing your works with us on this forum. I look forward to watching this progress.

#98 louizou

louizou

    Enthusiast

  • Members
  • PipPipPip
  • 265 posts

  • Flag: France

  • Favorite Pinball: BlackKnight2k T2 Twilight Zone

Posted 29 January 2012 - 08:14 PM

you do not have to thank me tiger ,even if i appreciate this dblthumb.gif
it's just normal to do this , as a pinball fan.

i must admit i had this idea since FP was released ! i don't remember the year think.gif
I've tryed to do my own editor/simulation , first using delphi and GLscene (that was ugly, i let it down quicly)
Then i tried something with virtools , a french game development tool => the same result even if it had better GFX and good physics

Borred with all this ,i decided to try something to rip FP data as the most difficult and long part, IMO , is the editor, and you must admit that it's editor is awesome.

I made some tools remoting FP in order to capture images , models ,etc .... That was not very "PRO" but it did the job (some data of the badcats prototype were taken from this)

And after releasing the video on youtube , LVR contacted me , and with the help of his tools , i started this project Worship.gif to him

As MLK said : "I have a dream .... It is a dream deeply rooted in the American dream" (in our case , it is some french men's dream too biggrin.gif )

All that to say that if we work all together (VP and FP fans) , we'll make that dream come true !

OMG , i do have lots of poetic and revolutionnary feelings tonight !!

uplogomini.png

Continue helping us at [email protected]

 


#99 bent98

bent98

    Pinball Fan

  • Members
  • PipPipPipPip
  • 1,077 posts
  • Location:NY

  • Flag: United States of America

  • Favorite Pinball: Roadshow, Haunted House, Safe Cracker

Posted 29 January 2012 - 10:03 PM

I am so happy you are working on this. It will be an exiciting day when the community can start playing tables in unity.


#100 louizou

louizou

    Enthusiast

  • Members
  • PipPipPip
  • 265 posts

  • Flag: France

  • Favorite Pinball: BlackKnight2k T2 Twilight Zone

Posted 29 January 2012 - 11:38 PM

true cool.gif

There are two things that worries me , the ramps and the toys .It will be IMO the hardest part.

As we can see on some FPT tables , the creators add surfaces or other invisible ramps over the real one(simple ramps) to avoid physics problem...

I thought about doing this natively , so the sides and bottom will be drawn with their FP textures,transp , spheremap ,etc ... and the top will be in the physic world but not visible.

What do you think about this ?

Edited by louizou, 29 January 2012 - 11:40 PM.

uplogomini.png

Continue helping us at [email protected]