Pip Distortion Bug: Difference between revisions
m God damnit. |
The mechanics behind the bug. |
||
Line 1: | Line 1: | ||
The Pip Distortion Bug is triggered when you alter any infantry from an [[MP Modes|MP Mode file]] without (re-)stating the pip settings for the unit in question. | The Pip Distortion Bug is triggered when you alter any infantry from an INI like an [[MP Modes|MP Mode file]] or a map without (re-)stating the pip settings for the unit in question. Its effect is that, if the unit enters any other object that displays a pip, the pip will get distorted (hence the name). | ||
The bug only affects {{ra2}} and {{yr}}. It occurs because Westwood removed the <tt>empty</tt> item from the internal list that maps string values to frame indexes. Because the pip frame index defined in the previous loaded INI is used as the default for reading the next INI value (as an index into the mapping list), the default value is now off-by-one and the wrong default value is used. If the {{f|Pip|link}} or {{f|OccupyPip|link}} tag is not defined, the wrong default value is converted to its corresponding frame index. | |||
In Yuri's Revenge, the mapping list was amended by the <tt>person</tt> pips, which leave out frame index 6 (which would be "personempty"). Thus, the frame index actually becomes off-by-two for the person pips each time they are read. | |||
Because the pip frame index can be larger than the number of items in the mapping list, the game overflows into the following {{f|PipScales}} mapping list, using <tt>ammo</tt> (and in YR also <tt>tiberium</tt>) as default, which cannot be mapped back to a valid pip frame index. The game resets the value to <tt>green</tt> in this case. | |||
More information at [[MP Modes#Pip= & OccupyPip=]]. | More information at [[MP Modes#Pip= & OccupyPip=]]. | ||
[[Category:Bugs and Errors]][[Category:Weird Bugs]][[Category:MP Mode Override Bugs]] | [[Category:Bugs and Errors]][[Category:Weird Bugs]][[Category:MP Mode Override Bugs]] |
Revision as of 14:27, 14 April 2013
The Pip Distortion Bug is triggered when you alter any infantry from an INI like an MP Mode file or a map without (re-)stating the pip settings for the unit in question. Its effect is that, if the unit enters any other object that displays a pip, the pip will get distorted (hence the name).
The bug only affects Red Alert 2 and Yuri's Revenge. It occurs because Westwood removed the empty item from the internal list that maps string values to frame indexes. Because the pip frame index defined in the previous loaded INI is used as the default for reading the next INI value (as an index into the mapping list), the default value is now off-by-one and the wrong default value is used. If the Pip or OccupyPip tag is not defined, the wrong default value is converted to its corresponding frame index.
In Yuri's Revenge, the mapping list was amended by the person pips, which leave out frame index 6 (which would be "personempty"). Thus, the frame index actually becomes off-by-two for the person pips each time they are read.
Because the pip frame index can be larger than the number of items in the mapping list, the game overflows into the following PipScales mapping list, using ammo (and in YR also tiberium) as default, which cannot be mapped back to a valid pip frame index. The game resets the value to green in this case.
More information at MP Modes#Pip= & OccupyPip=.