Quantcast
Viewing latest article 16
Browse Latest Browse All 51

Why does my Physics.gravity revert value change when accessed by one script, but not another?

Wow, that's a verbose title. Physics.gravity = -other.transform.up * GRAVITYCONSTANT; This is the line I'm using in one script, which simply doesn't work. looking at the data of the debug log, it tells me that Physics.gravity sometimes lets itself be changed for a second, but almost immediately changes back to what it was before. However, in another script with this line: Physics.gravity = direction * GRAVITYCONSTANT; it doesn't matter how often I call that line, it causes no problems. I've tried referencing the working script's functions that uses that line, but that does exactly the same. It's driving me batty.

Viewing latest article 16
Browse Latest Browse All 51

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>