Lockgo Posted July 24, 2014 Author Posted July 24, 2014 So I'm look through japhys, and I'm just wondering, where does your code begin.
Stoiss Posted July 24, 2014 Posted July 24, 2014 look for the comment lines call //[japhys] Lockgo likes this
Xycaleth Posted July 24, 2014 Posted July 24, 2014 look for the comment lines call //[japhys]I never comment my code like that So I'm look through japhys, and I'm just wondering, where does your code begin. I'm not sure exactly how much of it is working, but the main files to look at are trunk/code/game/bg_physics.cpp and trunk/code/game/g_physics.cpp. The handling of the physics itself is done by the Newton Game Dynamics physics engine which can be found in trunk/code/newton. I haven't changed any code in that directory, it's just the (probably now, very out of date) Newton physics engine out of the box.
Stoiss Posted July 24, 2014 Posted July 24, 2014 hmm im sure you did comment you codes in w_force.c and some other places with this line, but then again its been years sense i look at it last time and then again i was right //[JAPhys]int strap_FS_FOpenFile( const char *qpath, fileHandle_t *f, fsMode_t mode );void strap_FS_Read( void *buffer, int len, fileHandle_t f );void strap_FS_FCloseFile( fileHandle_t f );//[/JAPhys]and lines like //[Physics] is also there
Lockgo Posted July 24, 2014 Author Posted July 24, 2014 Do you suggest that I should try using newton dynamics 3.11, as appose to what you had with 2.00?
Xycaleth Posted July 24, 2014 Posted July 24, 2014 hmm im sure you did comment you codes in w_force.c and some other places with this line, but then again its been years sense i look at it last time and then again i was right //[JAPhys]int strap_FS_FOpenFile( const char *qpath, fileHandle_t *f, fsMode_t mode );void strap_FS_Read( void *buffer, int len, fileHandle_t f );void strap_FS_FCloseFile( fileHandle_t f );//[/JAPhys]and lines like //[Physics] is also there Oh right. I must have still been doing that back then I wouldn't do it now though lol Do you suggest that I should try using newton dynamics 3.11, as appose to what you had with 2.00?I imagine the Newton API between version 2 and 3 changed quite a lot so it probably wouldn't work, but you could give it a try. Anyhow, I stopped working on it partly because like I said, at the time I couldn't get the level of integration that I wanted. You can't just add a model and rotate it arbitrarily and have a correct bounding box because of limitations in the engine. It's doable now, but the networking issue is still there. The only objects that could be affected by physics were map objects. The cubes in all of my demo videos are part of the map itself, but turned into physics entities.
Tempust85 Posted July 24, 2014 Posted July 24, 2014 This would be pretty cool in SP. Archangel35757 likes this
Lockgo Posted August 11, 2014 Author Posted August 11, 2014 So I looked into the Newton code and how to implement it in my free time. I was just wondering, how long of a project do you think this is? How long did you work on this Xycaleth? Archangel35757 likes this
Xycaleth Posted August 11, 2014 Posted August 11, 2014 One or two months to get the basic thing working I think. You would probably need a another few months to get it really polished off and well-integrated. Archangel35757 likes this
Lockgo Posted November 13, 2014 Author Posted November 13, 2014 Newton had weird DLL problems. Not even the sample programs that came with the sdks would work. Decided to try my luck with Bullet. Also, found out why the rotation of items seem random. Turns out, they are just random for some items, as the comment "// give weapon items zero pitch, a random yaw, and rolled onto their sides...but would be bad to do this for a bowcaster" stated.
eezstreet Posted November 18, 2014 Posted November 18, 2014 If you're going for SP you're going to have a lot more luck, as the client and server are sort-of merged into one mess of code. I wouldn't even try this on MP to be honest. Define "DLL problems" though?
Lockgo Posted November 24, 2014 Author Posted November 24, 2014 Most of it was simple references. Having to add references in Visual Studios, having to delete pre-existing lib files so it could re-compile them, and even after a few, it would still say "does not exist" even if I typed out the exact folder paths for the #include statement. After having to do that with Bullet though, I probably wouldn't have changed from newton. Had I know Bullet was going to make me do the same thing.....C'est la vie.
Xycaleth Posted December 1, 2014 Posted December 1, 2014 Most of it was simple references. Having to add references in Visual Studios, having to delete pre-existing lib files so it could re-compile them, and even after a few, it would still say "does not exist" even if I typed out the exact folder paths for the #include statement. After having to do that with Bullet though, I probably wouldn't have changed from newton. Had I know Bullet was going to make me do the same thing.....C'est la vie.Sounds like basic linking problems You're going to get those problems with any library unless you have a better understanding of what the linker does and how it searches for the .lib files.
Lockgo Posted September 17, 2015 Author Posted September 17, 2015 Its been a while. I decided to focus on my original objective. I was able to make force grip interact with items missiles and thermal detonator. I want to get back to trying to implement a physic engine into Jedi Academy. I learned a lot about gentity_t in getting grip to work. However, the import/convert-BSP that bullet includes, only really works with Quake-3 arena levels. From what I understand, you have to know how the BSP levels work for each individual Quake 3 powered game, since they all do it different. I also found that force grip was a bit wonky. Even before I started editing it. Always has been from what I could tell. Here are the videoshttp://www.dailymotion.com/lockgo I should also note that the rockets where put at 1/9 the speed, I actually think its next to impossible to catch a rocket at normal speed with the range force grip gives you. I was actually tempted to make an entire new force power as appose to editing grip. Sorry for the late update, though. http://www.dailymotion.com/video/x373xly_2015-09-16-23-28-02-rep_videogames Archangel35757 likes this
Lockgo Posted September 21, 2015 Author Posted September 21, 2015 Anyone still here? Archangel35757 likes this
Lockgo Posted September 21, 2015 Author Posted September 21, 2015 Any suggestions or opinions? Although I have already accomplished my original goal.
Archangel35757 Posted October 6, 2015 Posted October 6, 2015 Any suggestions or opinions? Although I have already accomplished my original goal. Suggestion: keep working on integrating Bullet or "Fill-in-blank" physics engine into SP code. Tempust85 likes this
ensiform Posted October 8, 2015 Posted October 8, 2015 Bullet shouldn't be too difficult if it can import the bsp data from the engine somehow without having to re-load the entire bsp another time. Archangel35757 likes this
Archangel35757 Posted October 8, 2015 Posted October 8, 2015 Interesting... http://irrlicht.sourceforge.net/forum/viewtopic.php?f=19&t=49714 http://bulletphysics.org/Bullet/phpBB3/viewtopic.php?f=9&t=166
ensiform Posted October 8, 2015 Posted October 8, 2015 I've already seen bullet used with q3 bsp/maps.
Xycaleth Posted October 8, 2015 Posted October 8, 2015 Ohai... https://code.google.com/p/japhys/source/browse/trunk/code/game/bg_physics.cpp Lockgo likes this
ensiform Posted October 8, 2015 Posted October 8, 2015 (You can't use this but just showing you that its been done) https://github.com/TheDushan/OWEngine/blob/master/code/Engine/gphysics/bullet/btp_staticMapLoader.cpp
Lockgo Posted August 12, 2016 Author Posted August 12, 2016 Felt kind of bad that I never "published my work", but I actually don't know what type of "file" I would need to make for my edits to the force powers. Mainly force grip. What would be needed to have my modifications something you could add to a post complied game.
eezstreet Posted August 12, 2016 Posted August 12, 2016 You can't simply "edit" post compiled binaries. You need to modify the source code and recompile from scratch. Lockgo and Smoo like this
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now