I am trying to edit the GM notes on a token, but I need to add a blank line. <br> just literally adds <br> to it, and even <html><br></html> adds that literally to what i am doing. Here is the code I have thus far:
[h:setGMNotes(GetGMNotes()+"<html><br></html>Smite Evil (Su): Once per day a celestial creature can make a normal melee attack to deal extra damage equal to its HD (maximum of +20) against an evil foe.")]
Lil help would be wonderful.
Addling a line break to a variable (or to anything really)
Moderators: dorpond, trevor, Azhrei, giliath, jay, Mr.Ice
-
- Giant
- Posts: 192
- Joined: Mon Apr 11, 2011 8:11 pm
Re: Addling a line break to a variable (or to anything really)
You don't need <html> tags for gmNotes to be displayed when clicking on the token in object layer. But if viewed from the token config, it shows all the literal html. If you want to toss in a CR, you can put a literal CR in the string.
I also do thing like this.
Code: Select all
[H: newNotes = oldNotes + "
New stuff goes here"]
Code: Select all
[H: EOL = decode("%0A")]
[H: newNotes = strformat("%{oldNotes}%{EOL}%{newText}")]
Downloads:
- Notepad++ MapTool addon
- RPEdit details (v1.3)
- Coding Tips: Modularity and Design
- Videos: Macro Writing Tools