• Localized Physics- a (semi)functional version of The Gravity Hull Designator
    65 replies, posted
New Thread courtesy of David: [url]https://facepunch.com/showthread.php?t=1488775[/url] [DEL]Hello. I for one thought this was long overdue. The Gravity Hull Designator by superllama was an amazing addon which was completely broken with noone attempting a possible fix. Instead of bitching about it, me and my friend learned lua and decided to do something about it. [B][U]NOTE: This addon has enough bugs to overfeed an ant-eater, and as such isn't intended for general use on servers. Use with caution. [/U][/B] Q: Why would you upload this? Didn't the old one already exist on GitHub? A: Yes, but that one hasn't been touched in a long time. If you attempted to use that one, your toolgun breaks, guns won't fire, and script errors all over the place. [B][U] What does localized physics do? [/U][/B] -It uses a complicated illusion to make movement of props and players relative to objects -It can be used to create a spaceship -It can even be used to create a submarine as the water effects are removed whilst in a hull [B][U] Simple Demo [/U][/B] [video=youtube;jbOHCopCyiU]https://www.youtube.com/watch?v=jbOHCopCyiU[/video] [B][U] What's infinite maps? Is this some next level impossible shit? [/U][/B] -Yes! Indeed it is. -Brings linear procedural-generation to Garry's Mod mapping -Maps never end now -Your rockets to space will actually head somewhere instead of the map boundaries (After you've reached high enough, Asteroids will appear) [B][U]Infinite maps demo[/U][/B] (Courtesy of David) [video=youtube;xn4bDLPY69Q]https://www.youtube.com/watch?v=SawtvzRSwVg[/video] [B][U] We are enlisting the help of mappers to create infinite maps for us to release with the final version [/U][/B] Current bugs y'all can help with: -Thirdperson breaks with WAC -Can't inflict damage on entities using bullet-based sweps -Players cannot be shot from inside or outside a hull -Players cannot inflict damage upon each other in a hull -exiting a hull will teleport you to a random position (can't narrow down what triggers this) -Vehicles don't work properly in a hull -Ragdolls simply don't work -Gravity percentage slider seems to be broken for world entities such as players -You can pick up func_rotating_doors with a hull, it'll duplicate and displace itself in the skybox -Can't get inside of seats whilst in hulls -Getting a inside a seat inside a hull derenders all props and entities [DEL]-Viewmodels refuse to render[/DEL] - Fixed thanks to Z0Mb1n3 [DEL]-Is very buggy with Falco's prop protection, as it tries to prevent players who aren't prop buddies to enter the hull[/DEL] - The great Falco himself helped me fix this [DEL]-The enitre tool is co-dependent on the obsolete/experimental map repeat function/feature [/DEL] - Not obsolete nomore. Thanks David! -Inform me about any more issues I have missed. [B][U]Links: [/U][/B]Original Thread: [URL]http://facepunch.com/showthread.php?t=1254462[/URL] Help us by contributing on Github: [URL]https://github.com/BillyTheBull/localizedphysics[/URL] Current main developers: Me (Bull on steam) David Ralphsky (Same name on steam) Erik the Born (Nightshade/Derek on Steam) Contributors thus far: kila98 - Fixed an overlooked string error Z0mb1n3 - Fixed Viewmodels rendering Falco - Fixed compatibility with FPP Ott - Lots and lots of detailed bug reports. Would any mappers be interested in helping us create infinite maps to release with LP? If interested, contact me or David on Steam [/DEL]
Making this work again would be beautiful. This was one of the addons which I never got a chance to play with properly.
[QUOTE=Jamsponge;48286161]Making this work again would be beautiful. This was one of the addons which I never got a chance to play with properly.[/QUOTE] It's perfectly usable as long as you don't take a vehicle near it!
[QUOTE]-Is very buggy with Falco's prop protection, as it tries to prevent players who aren't prop buddies to enter the hull[/QUOTE] I actually would find this to be a feature more then bug
You can fix the bullet thing by hooking [img]http://wiki.garrysmod.com/favicon.ico[/img] [url=http://wiki.garrysmod.com/page/GM/EntityFireBullets]GM/EntityFireBullets[/url] and modifying the position/angle of the bullet, even works on HL2 guns! [editline]25th July 2015[/editline] Also, shouldn't this be forked from [url]https://github.com/superllama/gravityhull[/url] on GitHub?
[QUOTE=MattJeanes;48290394]You can fix the bullet thing by hooking [img]http://wiki.garrysmod.com/favicon.ico[/img] [url=http://wiki.garrysmod.com/page/GM/EntityFireBullets]GM/EntityFireBullets[/url] and modifying the position/angle of the bullet, even works on HL2 guns! [editline]25th July 2015[/editline] Also, shouldn't this be forked from [url]https://github.com/superllama/gravityhull[/url] on GitHub?[/QUOTE] Thanks! I'll start working on it right away! And also this was my first time on Github (as a contributor), so I didn't know it was a feature :wavey:
Personally, I tried to fix the viewmodel issue, and could only get so far as to see it was coming from some math that I don't understand in the CalcViewModelView hook. Oddly enough, no matter what I set most of the numbers to, the viewmodel would render in the same glitched position, as if it was 'spectating' (orbiting 10 feet behind player) where the real version of the player is. [b]EDIT:[/b] yay I fixed the viewmodels, but I'm not sure what the hell the physgun beam is doing. [t]http://puu.sh/jcAyl.jpg[/t]
[url]https://github.com/BillyTheBull/localizedphysics/pull/1[/url] Breaks the toolgun.
[QUOTE=kila58;48299546][url]https://github.com/BillyTheBull/localizedphysics/pull/1[/url] Breaks the toolgun.[/QUOTE] Merged! Thanks! [editline]26th July 2015[/editline] [QUOTE=Z0mb1n3;48292203]Personally, I tried to fix the viewmodel issue, and could only get so far as to see it was coming from some math that I don't understand in the CalcViewModelView hook. Oddly enough, no matter what I set most of the numbers to, the viewmodel would render in the same glitched position, as if it was 'spectating' (orbiting 10 feet behind player) where the real version of the player is. [b]EDIT:[/b] yay I fixed the viewmodels, but I'm not sure what the hell the physgun beam is doing. [t]http://puu.sh/jcAyl.jpg[/t][/QUOTE] Do you mind committing it to the Git? I had trouble making CalcViewModelView work and I'm really curious as to how you did it
Thanks for revitalizing this! I'm terribly sorry for how badly I commented my code and how poorly constructed the mod is in general... if you need any help understanding something don't hesitate to ask. I know how it's *supposed* to work but I never learned gm13 which is why I haven't done anything to it since then.
[QUOTE=Par;48299588] Do you mind committing it to the Git? I had trouble making CalcViewModelView work and I'm really curious as to how you did it[/QUOTE] le done
[QUOTE=Z0mb1n3;48303415]le done[/QUOTE] Holy shit! You're amazing, thanks. :happy: I was always wondering why the old hook i was trying to fix didn't work lol :hammered::huh:
[QUOTE=SuperLlama;48300809]Thanks for revitalizing this! I'm terribly sorry for how badly I commented my code and how poorly constructed the mod is in general... if you need any help understanding something don't hesitate to ask. I know how it's *supposed* to work but I never learned gm13 which is why I haven't done anything to it since then.[/QUOTE] Wow, so many questions. Great to see you come back! The main question I was wondering about, did vehicles always glitch with the GHE? Was there a time when vehicles worked with it? Right now taking a vehicle near a hull causes world physics to crash
[QUOTE=Par;48305740]Wow, so many questions. Great to see you come back! The main question I was wondering about, did vehicles always glitch with the GHE? Was there a time when vehicles worked with it? Right now taking a vehicle near a hull causes world physics to crash[/QUOTE] I know they did once-- I remember driving a jeep into an upside-down gravhull and coming out the other side before landing on the ceiling, it was really fun. I do know they've been broken for quite a long time, though, like only a few months after I stopped working on it. To debug I'd suggest the following procedure: 1) comment out the code inside of TryEat and TrySpit in sv_main. 2) start the game, make a hull, put a Jeep on top of it, and use lua_run to call GravHull.ShipEat(ship_prop, jeep_entity). 3) observe how the hull behaves-- if the physics breaks, the problem is not with the automatic linking functions but with the linking process itself. If it doesn't break, move the hull around and also try calling ShipEat on yourself and driving around inside the hull-- I'm pretty sure the CalcView hook will break if you enter a vehicle so that'll be another fix, but it'd be a good idea to try and figure out just *HOW* broken vehicles are. Way way way back when this was first released, vehicles worked just fine, but a lot has changed since then. Let me know how this goes and I can suggest further tests to figure out what's going on. I don't really play gmod anymore but someone (MattJeanes^ up there) showed me that you were fixing my old mod and I thought I'd help out if I could. By the way, the physgun beam has actually always been broken and will probably stay that way forever unless someone writes a lua version of the effect. I managed to fool the game into making the physgun PHYSICS work by creating "physghosts" ship-side whenever you aim at an entity outside of your hull, then applying forces and changes to the outside entities whenever the ghosts are moved, but that was the best I could do. The mod works by lying to the rendering pipeline, calling SetPos on entities clientside every frame, changing where they're drawn, but not where they physically (in the serverside code) are. This works for most props and ragdolls and even most scripted entities, but the physgun beam is a fancy effect entity that doesn't take kindly to this, so it messes up its targeting system. So really the only way to make it render properly is to make the physgun beam entity completely invisible when you're in a hull and replace it with a lua version of the effect that takes hulls into account.
[QUOTE=SuperLlama;48308532]I know they did once-- I remember driving a jeep into an upside-down gravhull and coming out the other side before landing on the ceiling, it was really fun. I do know they've been broken for quite a long time, though, like only a few months after I stopped working on it. To debug I'd suggest the following procedure: 1) comment out the code inside of TryEat and TrySpit in sv_main. 2) start the game, make a hull, put a Jeep on top of it, and use lua_run to call GravHull.ShipEat(ship_prop, jeep_entity). 3) observe how the hull behaves-- if the physics breaks, the problem is not with the automatic linking functions but with the linking process itself. If it doesn't break, move the hull around and also try calling ShipEat on yourself and driving around inside the hull-- I'm pretty sure the CalcView hook will break if you enter a vehicle so that'll be another fix, but it'd be a good idea to try and figure out just *HOW* broken vehicles are. Way way way back when this was first released, vehicles worked just fine, but a lot has changed since then. Let me know how this goes and I can suggest further tests to figure out what's going on. I don't really play gmod anymore but someone (MattJeanes^ up there) showed me that you were fixing my old mod and I thought I'd help out if I could. By the way, the physgun beam has actually always been broken and will probably stay that way forever unless someone writes a lua version of the effect. I managed to fool the game into making the physgun PHYSICS work by creating "physghosts" ship-side whenever you aim at an entity outside of your hull, then applying forces and changes to the outside entities whenever the ghosts are moved, but that was the best I could do. The mod works by lying to the rendering pipeline, calling SetPos on entities clientside every frame, changing where they're drawn, but not where they physically (in the serverside code) are. This works for most props and ragdolls and even most scripted entities, but the physgun beam is a fancy effect entity that doesn't take kindly to this, so it messes up its targeting system. So really the only way to make it render properly is to make the physgun beam entity completely invisible when you're in a hull and replace it with a lua version of the effect that takes hulls into account.[/QUOTE] I think this issue stems from changing the vehicle's mass. I'll test that when I get the chance, as I remember it happening when I tried a while back to make zero-gravity airboat seats.
[QUOTE=SuperLlama;48308532]I know they did once-- I remember driving a jeep into an upside-down gravhull and coming out the other side before landing on the ceiling, it was really fun. I do know they've been broken for quite a long time, though, like only a few months after I stopped working on it. To debug I'd suggest the following procedure: 1) comment out the code inside of TryEat and TrySpit in sv_main. 2) start the game, make a hull, put a Jeep on top of it, and use lua_run to call GravHull.ShipEat(ship_prop, jeep_entity). 3) observe how the hull behaves-- if the physics breaks, the problem is not with the automatic linking functions but with the linking process itself. If it doesn't break, move the hull around and also try calling ShipEat on yourself and driving around inside the hull-- I'm pretty sure the CalcView hook will break if you enter a vehicle so that'll be another fix, but it'd be a good idea to try and figure out just *HOW* broken vehicles are. Way way way back when this was first released, vehicles worked just fine, but a lot has changed since then. Let me know how this goes and I can suggest further tests to figure out what's going on. I don't really play gmod anymore but someone (MattJeanes^ up there) showed me that you were fixing my old mod and I thought I'd help out if I could. By the way, the physgun beam has actually always been broken and will probably stay that way forever unless someone writes a lua version of the effect. I managed to fool the game into making the physgun PHYSICS work by creating "physghosts" ship-side whenever you aim at an entity outside of your hull, then applying forces and changes to the outside entities whenever the ghosts are moved, but that was the best I could do. The mod works by lying to the rendering pipeline, calling SetPos on entities clientside every frame, changing where they're drawn, but not where they physically (in the serverside code) are. This works for most props and ragdolls and even most scripted entities, but the physgun beam is a fancy effect entity that doesn't take kindly to this, so it messes up its targeting system. So really the only way to make it render properly is to make the physgun beam entity completely invisible when you're in a hull and replace it with a lua version of the effect that takes hulls into account.[/QUOTE] Thanks! I'll get started on bugfixing it right away, with this method I was able to stop seats from bugging out whilst on a hull.
Wow. Its nice to see that the project is appreciated. So nice to see poeple trying to help. I started this revive project (Night Shade) on steam. There is a workshop version of this I uploaded not too long ago that I keep updated from the github version. Heres the link: [url]http://steamcommunity.com/sharedfiles/filedetails/?id=465315188[/url]' Also when using the flashlight inside a hull it doesnt lightup inside or outside the hull could any1 take a look at this and if you get it working you could commit it on the github maybe? PS: Please tell me when someone made changes or fixed bugs so I can update the workshop addon with the changes you made.
There's also this one [url]http://steamcommunity.com/sharedfiles/filedetails/?id=239705853[/url] He seems to have made some progress fixing it too. Ideally I'd want there to only be one workshop version, one that I can put my stamp of approval on by being listed as one of the mod creators, and that I could support as a consultant. And I hate to be picky, but would it be too much trouble to put my name somewhere in your mod description? I did work really hard on this back in 2011-2012.
Sure I put it.... DONE! Sry i forgot about that. I honestly thought I already put your name there xD PS: Would you like me to add you as contributor for the workshop addon? Just in case you plan fix something.
[QUOTE=Erik The Born;48338239]Sure I put it.... DONE! Sry i forgot about that. I honestly thought I already put your name there xD PS: Would you like me to add you as contributor for the workshop addon? Just in case you plan fix something.[/QUOTE] Thanks! And sure, that way I can keep up with everything that's going on (plus technically I did a majority of the work contained in this mod albeit 4 years ago). I think once we get it working at least as well as the other guy's fork, we could reach out to him too and see if he wants to merge with us so there's only one official version on the workshop.
Great! Il send u an invite through steam! But I need ur profile page turns out ur name is very popular xD
Yeah lol, I chose the name when I was 14 and didn't realize how many other superllamas there were... then I made a few mods that people liked (runecraft and this one mostly) and now I can't really change it since I'm semi known in certain circles lol. I did manage to snatch the /id/superllama url on steam though. Just click the steam icon under my name here on fp and that should get you to my profile. The one that says "gravity is nothing" and has the same terribly made avatar I used when I was 14, lol
I have sent a friend request now check your firendlist
If someone could look into the old mapreapeat and maybe get that working would be good. :)
The ultimate test is to try this on a pirate ship.
It always used to work on boats just fine. I see no reason why it won't in its current state.
This is my favourite addon aside from wire, if you guys get this up and running I will be forever greatful. I may offer my services in assisting too.
[QUOTE=Ricool06;48384486]This is my favourite addon aside from wire, if you guys get this up and running I will be forever greatful. I may offer my services in assisting too.[/QUOTE] Oh but it is working! Just check it out on the workshop, LINK: [url]http://steamcommunity.com/sharedfiles/filedetails/?id=465315188[/url] Its not actually that buggy as we say it is. And yeah any assist what be really appreciated. :D
[QUOTE=Erik The Born;48448403]Oh but it is working! Just check it out on the workshop, LINK: [url]http://steamcommunity.com/sharedfiles/filedetails/?id=465315188[/url] Its not actually that buggy as we say it is. And yeah any assist what be really appreciated. :D[/QUOTE] Well then thanks again Erik! I shall check this out.
I fixed Infinite Maps for ya! [video=youtube;SawtvzRSwVg]https://www.youtube.com/watch?v=SawtvzRSwVg[/video]
Sorry, you need to Log In to post a reply to this thread.