Changeset 290 for binary-improvements/AllocsCommands/Commands
- Timestamp:
- Sep 25, 2016, 1:51:01 PM (8 years ago)
- Location:
- binary-improvements/AllocsCommands/Commands
- Files:
-
- 5 deleted
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
binary-improvements/AllocsCommands/Commands/Give.cs
r250 r290 52 52 53 53 if (_params.Count == 4) { 54 if (!iv.HasQuality ) {54 if (!iv.HasQuality && iv.Attachments == null && iv.Parts == null) { 55 55 SdtdConsole.Instance.Output ("Item " + _params [1] + " does not support quality."); 56 56 return; … … 63 63 } 64 64 iv.Quality = quality; 65 66 // Specific code for weapons with parts and attachmetns 67 if (iv.Attachments != null && iv.Attachments.Length != 0) { 68 for (int i = 0; i < iv.Attachments.Length; i++) { 69 ItemValue att = iv.Attachments[i]; 70 if (att.HasQuality) { 71 att.Quality = quality; 72 } 73 } 74 } 75 76 if (iv.Parts != null && iv.Parts.Length != 0) { 77 for (int i = 0; i < iv.Parts.Length; i++) { 78 ItemValue part = iv.Parts[i]; 79 if (part.HasQuality) { 80 part.Quality = quality; 81 } 82 } 83 } 65 84 } 66 85
Note:
See TracChangeset
for help on using the changeset viewer.