Skip to content

Instantly share code, notes, and snippets.

@Kayne
Kayne / HitDiceHelper.js
Created March 23, 2020 11:34
Fixed version of HitDiceHelper.js for roll20.net, originally by Kevin (https://app.roll20.net/forum/post/5581501/scriptlet-5e-ogl-hit-dice-helper)
on('chat:message', function(msg) {
// ROLL LISTENER
if(msg.playerid.toLowerCase() != "api" && msg.rolltemplate) {
var cnamebase = msg.content.split("charname=")[1].split('{{')[0]; // Fixed line
var cname = cnamebase ? cnamebase.replace('}}','').trim() : (msg.content.split("{{name=")[1]||'').split("}}")[0].trim();
var character = cname ? findObjs({name: cname, type: 'character'})[0] : undefined;
if(["simple"].indexOf(msg.rolltemplate) > -1) {
if(_.has(msg,'inlinerolls') && msg.content.indexOf("^{hit-dice-u}") > -1 && character) {
handlehd(msg,character);
}
@Kayne
Kayne / rails_admin.pl.yml
Created February 1, 2012 15:16
Polish translation for RailsAdmin
pl:
admin:
home:
name: Strona główna
pagination:
previous: "« Poprzednie"
next: "Następne »"
misc:
search: "Szukaj"
filter: "Filtruj"