Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Ready] Fixed script objects falling through the ground #450

Merged
merged 1 commit into from May 22, 2018
Merged

[Ready] Fixed script objects falling through the ground #450

merged 1 commit into from May 22, 2018

Conversation

ghost
Copy link

@ghost ghost commented May 12, 2018

This fixes issue when during the game intro few objects fall through the ground.

  • 0107 opcode
  • 0392 opcode​

Issues to fix:

  • Lamposts act weirdly now, seems like they only fall down after 2nd hit
  • Hydrants don't longer break

@ghost ghost changed the title Fixes script objects falling through the ground Fixed script objects falling through the ground May 12, 2018
@ghost
Copy link
Author

ghost commented May 13, 2018

its cause u have created a switch action, when the car hits the lamposts he trigger to true, and when he hits again, if true the lampost fall, make a test with this, the lampost will fall down with the first hit damage
image

but i dont know if this is the right method to make this works, maybe u need set the physcs to true when he detect if the impact can break the lampost

@ghost
Copy link
Author

ghost commented May 13, 2018

After the fix, some hydrants dont break when u hit with the car(high speed) but when u give small hits near the hydrant he breaks, its normal ?

@ghost
Copy link
Author

ghost commented May 13, 2018

I'll test

@ghost
Copy link
Author

ghost commented May 13, 2018

What you described happens in master branch, in my branch hydrants don't even break

@@ -308,7 +308,8 @@ void ObjectRenderer::renderVehicle(VehicleObject* vehicle,
void ObjectRenderer::renderPickup(PickupObject* pickup, RenderList& outList) {
if (!pickup->isEnabled()) return;

glm::mat4 modelMatrix = glm::translate(glm::mat4(1.0f), pickup->getPosition());
glm::mat4 modelMatrix =
glm::translate(glm::mat4(1.0f), pickup->getPosition());
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like there's just formatting changes in this file

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

getVisible was placed with isVisible

RW_UNUSED(args);
object->setStatic(!arg2);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The description of this opcode seems to be that it turns collision detection on and off, not change static status.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You right. Will fix.

@ghost ghost changed the title Fixed script objects falling through the ground [WIP] Fixed script objects falling through the ground May 14, 2018
@ghost ghost changed the title [WIP] Fixed script objects falling through the ground [Ready] Fixed script objects falling through the ground May 15, 2018
@ghost ghost mentioned this pull request May 22, 2018
27 tasks
@danhedron danhedron merged commit de81319 into rwengine:master May 22, 2018
@ghost ghost deleted the objphy branch May 22, 2018 22:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant