File tree Expand file tree Collapse file tree 1 file changed +5
-2
lines changed 
Common/src/main/java/mezz/jei/common/util Expand file tree Collapse file tree 1 file changed +5
-2
lines changed Original file line number Diff line number Diff line change 22
33import  net .minecraft .ChatFormatting ;
44import  net .minecraft .network .chat .Component ;
5+ import  net .minecraft .network .chat .MutableComponent ;
6+ import  net .minecraft .network .chat .Style ;
57import  net .minecraft .world .entity .player .Player ;
68
79/** 
@@ -12,8 +14,9 @@ private ChatUtil() {
1214	}
1315
1416	public  static  void  writeChatMessage (Player  player , String  translationKey , ChatFormatting  color ) {
15- 		Component  component  = Component .translatable (translationKey );
16- 		component .getStyle ().applyFormat (color );
17+ 		MutableComponent  component  = Component .translatable (translationKey );
18+ 		Style  redStyle  = component .getStyle ().applyFormat (color );
19+ 		component .setStyle (redStyle );
1720		player .displayClientMessage (component , false );
1821	}
1922}
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments