Inactive Combat

Immortius

Lead Software Architect
Contributor
Architecture
GUI
I don't think a second md5 would help, because it would be better to use simple collision shapes rather than meshes/models - and md5 has no support for that. Would probably need a separate file format. Or using a different skeleton file, since modellers would presumably want to create the collision hulls in Blender or similar.
 

aherber

Member
Contributor
Architecture
Immortius What i actualy meant was to parse the mesh of a seperate skeletonfile that defines the collsion volumes per bone and create the simple collsion volumes from it. If thats not possible or at least not practical what file format should we use for the collision hulls ?
 

Immortius

Lead Software Architect
Contributor
Architecture
GUI
Probably a custom file format. Or an extension to MD5 or IQM. Which would require a custom blender exporter. The problem with MD5 as is, is how can you tell what type of collision volume to create for each bone? All MD5 gives you are vertices, which is useless. You could possibly generate a collision hull from the vertex cloud related to each bone, but that isn't particularly performant.

The only one I'm aware of with that support is psk, but that format is horribly propriety.
 

aherber

Member
Contributor
Architecture
I was trying to implement the JBullet debugger for the collsionshapes but i ended up extending the AABBRender Class to render the OOBB that are attached to bones. This works and helps testing the collsion for the Combat. Hopefully i can replace it with the Debugger from JBullet. Here is a screenshot.



The creation of the collisionshapes for the bones is currently not dynamic. Thats why each collsion box have the same size. That means it is not based on the vertices that are attached to the bones. I already implemented the Math needed for the calculation of the OOBB (which is much harder than it sounds.) based on the vertices. It will give us an estimated OOBB but not the smallest possible OOBB. I still have to find out out how to determine the exact positions . I kinda have the feeling that the vertexpositions are all relative to the joint position but i have to check it Everthing else would make no sense to me also i havent found any information on this. Hopefully in the next update the collision boxes will be dynamically created based on the vertices of the model. When this problem is solved the technical requirements for the combat system are more or less finished.
 

Cervator

Org Co-Founder & Project Lead
Contributor
Design
Logistics
SpecOps
When this problem is solved the technical requirements for the combat system are more or less finished.
Can't wait! Keep it up - screenie looks very cool :)
 

Cervator

Org Co-Founder & Project Lead
Contributor
Design
Logistics
SpecOps
Update! I've mentioned here and there that aherber sadly retired from the project some time ago, probably from the usual RL reasons that you cannot quite escape on an all-volunteer project, oh well :)

Before leaving he tried to merge in the latest code, but the differences were vast (combat branch split from develop a loooong time ago) and some stuff broke. And the merged version replaced the working pre-merge version so we didn't have a working version :eek:

nh_99 to the rescue! I had looked around some for a pre-merge version and couldn't find one, but through quirky caching on old entries on GitHub nh_99 did find one! It is disconnected from the rest of the source tree now, but I pushed his find to MovingBlocks so we have a safe version for reference to review for a new version. It is over here. Many thanks nh_99 !

The pre-merge version is very old but you can run it from source (don't forget to "gradlew idea" it as libs/setup differs, also delete any game data as it'll clash). The goodie chest you start with has three different bows where the arrows act differently - described previously in this thread. I like shooting the ones that drop with distance straight up in the air, then watch them come back down in a rain of arrows :)

SuperSnark - try it out, just run it from source. Enable portals too and get some gelcubes running around, the arrows will kill them and trigger a funny "death animation" although they keep bouncing even after death, just in-place ;)

nh_99 is going to look at it some more and see if we can get it working with the latest code
 

Cervator

Org Co-Founder & Project Lead
Contributor
Design
Logistics
SpecOps
Progress, woo! Highlight build available for the initial work nh_99 has done :)

Will let him provide some more details, but it is attached to the head of develop and looking good in just a couple commits

Testing is appreciated, I was able to run it fine and use all three bows successfully against what a normal portal spawns. Sword just threw an exception though:

Code:
Raytest
20:09:23.812 [main] ERROR o.t.e.pojo.PojoEventSystem:257 - Failed to invoke event
java.lang.reflect.InvocationTargetException: null
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.7.0_07]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) ~[na:1.7.0_07]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.7.0_07]
    at java.lang.reflect.Method.invoke(Method.java:601) ~[na:1.7.0_07]
    at org.terasology.entitySystem.pojo.PojoEventSystem$ReflectedEventHandlerInfo.invoke(PojoEventSystem.java:251) [Terasology/:na]
Don't enable the questing module in that build, it makes the game go boom :)

I'll include this in a big update tomorrow or Saturday
 

Immortius

Lead Software Architect
Contributor
Architecture
GUI
You should post the inner exception, Cervator. That exception just says that an exception occurred while processing an event - below it should be a Caused by: exception. :)
 

Cervator

Org Co-Founder & Project Lead
Contributor
Design
Logistics
SpecOps
Oh, whoops. Here's the rest!

Code:
    at org.terasology.game.Terasology.main(Terasology.java:56) [Terasology/:na]
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) ~[na:1.7.0_07]
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) ~[na:1.7.0_07]
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) ~[na:1.7.0_07]
    at java.lang.reflect.Method.invoke(Method.java:601) ~[na:1.7.0_07]
    at com.intellij.rt.execution.application.AppMain.main(AppMain.java:120) [idea_rt.jar:na]
Caused by: java.lang.NullPointerException: null
    at org.terasology.components.actions.RayTraceAction.onActivate(RayTraceAction.java:54) ~[Terasology/:na]
    ... 27 common frames omitted
 

nh_99

New Member
Contributor
Yay, first bug!! Also, questing is wonky in this build. I was working on something with it then finished up with the combat thing :). For those of you that don't know, the goodie chest provides everything you need to play around. The bows are in there. To use them, just right click and hold for further range. To get the best testing out of this, enable portals or something like that to kill some gelcubes. Have fun :)
 
Top