| Summary: | Error in markDestroyable() or destroyDestoyable() in Map.java | ||
|---|---|---|---|
| Product: | CandyCrush 2020 | Reporter: | ziruichen6-c |
| Component: | Source Code | Assignee: | jli262-c |
| Status: | CONFIRMED --- | ||
| Severity: | enhancement | ||
| Priority: | --- | ||
| Version: | 1.0 | ||
| Hardware: | PC | ||
| OS: | Windows | ||
|
Description
ziruichen6-c
2020-11-18 22:29:54 HKT
The error was caused by the format for writing code. The result returned by markDestroyable() is different from the expected. The solution would be to correct the code. Previous version: boolean result = markSquareDestroyable()| markHorizontalDestroyable()| markVerticalDestroyable(); return result; The problem would be that if one item is marked by markSquareDestroyable(), it would no longer participate in markHorizontalDestroyable()or markVerticalDestroyable(). After correcting: boolean result = markSquareDestroyable(); result = result | markHorizontalDestroyable(); result = result | markVerticalDestroyable(); return result; This is because the short circuit has occurred so that two behind functions didn't be called. |