How should I implement physics using windshield?

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
MaxGamz
Party member
Posts: 100
Joined: Fri Oct 28, 2022 3:09 am

Re: How should I implement physics using windshield?

Post by MaxGamz »

Oh wow, that actually worked pretty well! May you explain why this new code works please?
User avatar
ReFreezed
Party member
Posts: 612
Joined: Sun Oct 25, 2015 11:32 pm
Location: Sweden
Contact:

Re: How should I implement physics using windshield?

Post by ReFreezed »

According to the documentation collider:enter() and collider:exit() returns true the frame the contact with another collider starts and ends, respectively. Looking at the library code reveals that "Default" is the default collision class name for all colliders, so self.collider:enter("Default") currently returns true when the player collides with anything else (from any angle).
Tools: Hot Particles, LuaPreprocess, InputField, (more) Games: Momento Temporis
"If each mistake being made is a new one, then progress is being made."
Post Reply

Who is online

Users browsing this forum: No registered users and 69 guests