forked from public/foundryvtt-reve-de-dragon
		
	
		
			
				
	
	
		
			18 lines
		
	
	
		
			638 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			18 lines
		
	
	
		
			638 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
| import { ChatUtility } from "./chat-utility.js";
 | |
| 
 | |
| export class RdDRollResult {
 | |
| 
 | |
|   static async displayRollData(rollData, actor = undefined, template = 'chat-resultat-general.hbs') {
 | |
|     const chatMessage = await ChatUtility.createChatWithRollMode(
 | |
|       { content: await RdDRollResult.buildRollDataHtml(rollData, template) },
 | |
|       actor
 | |
|     )
 | |
|     return chatMessage
 | |
|   }
 | |
| 
 | |
|   static async buildRollDataHtml(rollData, template = 'chat-resultat-general.hbs') {
 | |
|     rollData.show = rollData.show || {};
 | |
|     return await foundry.applications.handlebars.renderTemplate(`systems/foundryvtt-reve-de-dragon/templates/${template}`, rollData);
 | |
|   }
 | |
| }
 |