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

Fix for multipart doors. #26546

Merged
merged 2 commits into from
Nov 5, 2018
Merged

Conversation

kevingranade
Copy link
Member

A previous change got parts[next_index] and parts[part_index] confused, this corrects that.

Summary

SUMMARY: None

Purpose of change

This corrects a logic error introduced by #26477
The expected symptom is that opening or closing multitile doors will fail to propagate to adjacent door pieces.

Describe the solution

Extract the part coordinate for comparison purposes instead of accidentally subtracting it from itself.

Describe alternatives you've considered

The whole function needs cleaning up, but I don't have time for that at the moment.

A previous change got parts[next_index] and parts[part_index] confused, this corrects that.
src/vehicle_use.cpp Outdated Show resolved Hide resolved
Co-Authored-By: kevingranade <kevin.granade@gmail.com>
@ZhilkinSerg ZhilkinSerg merged commit de0ed7b into master Nov 5, 2018
@ZhilkinSerg ZhilkinSerg added Vehicles Vehicles, parts, mechanics & interactions [C++] Changes (can be) made in C++. Previously named `Code` <Bugfix> This is a fix for a bug (or closes open issue) labels Nov 5, 2018
@kevingranade kevingranade deleted the kevingranade-fix-multitile-open-close branch November 9, 2018 20:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
<Bugfix> This is a fix for a bug (or closes open issue) [C++] Changes (can be) made in C++. Previously named `Code` Vehicles Vehicles, parts, mechanics & interactions
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants