![]() |
|
E2 Function: gravity() - Printable Version +- Team Spartan Cookies & Milk Forums (https://teamscm.co.uk) +-- Forum: Garry's Mod (https://teamscm.co.uk/forum-4.html) +--- Forum: Expression 2 (https://teamscm.co.uk/forum-6.html) +--- Thread: E2 Function: gravity() (/thread-2788.html) |
E2 Function: gravity() - iNoPeRaTiVe - 09-09-2018 I believe that gravity() is a function that Person added in from Stargazer? As it returns a value of "600," but where does it measure gravity from? If I move the E2 chip to space it still returns as "600". Thanks for reading, please help. RE: E2 Function: gravity() - mariofludd - 09-09-2018 I believe its a normal e2 function, not sure though, but the e2 is reading what the server has sv_gravity set to (which gmod default is 600 i believe) RE: E2 Function: gravity() - iNoPeRaTiVe - 09-09-2018 Oh, okay, nevermind then, is there a way to read the gravity of an entity using E2? I'm making something that needs to detect whether or not it's in gravity. RE: E2 Function: gravity() - mariofludd - 09-09-2018 No clue, sorry :/ RE: E2 Function: gravity() - Kosmos - 09-09-2018 Starfall has a function Entity:getEnvironmentData(), the table it returns contains a number "gravity". If you're lucky, person added this for E2 too, otherwise you have to write a starfall gate. |