Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×

The new D&D 2024 sheet is now available!

Create a free account

Display a pop up when clicking a button in chat menu ?

EN : Hello everyone, I have a question. It is possible to display a pop up whit the content I want to display, for a player when he click on a button in a chat menu. I explain. I have used the tip of keithcurtis to create a bestiary in my game, but I want to display the description of the monsters when the player choose one in the menu. It is possible ? Thanks for your attention. I get you my code under this message. P.S : Sorry for my english it isn't perfect. FR :&nbsp; Bonjour tout le monde, J'ai une question. Est ce qu'il est possible d'afficher une pop-up avec le contenu que je souhaite afficher, pour un joueur quand il clique sur un bouton dans un menu de chat. Je m'explique. J'ai crée un bestiaire dans ma partie avec l'astuce de keithcurtis, mais j'aimerais que la description des monstres s'affiche dans une pop-up plûtot que dans le chat quand un joueur choisit un monstre dans le menu. Est-ce que c'est possible ? Merci de votre attention. Je vous mets mon code sous ce message. The menu : /me &amp;{template:invocation} {{name=Bestiaire}} {{description=Enahora [Araignée énorme](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312155026049317515807.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312155026049317515807.jpg&amp;#41</a>; &amp;#13;** Araignée énorme — **Aussi dangereuse que repoussante, sa blessure est mortelle&amp;#13;/w gm ) - *Enahora* [Araignée géante](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312155026049317515807.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312155026049317515807.jpg&amp;#41</a>; &amp;#13;** Araignée géante — **Aussi dangereuse que repoussante, sa blessure est mortelle&amp;#13;/w gm ) - *Enahora* [Chimère](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312154926049317515800.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312154926049317515800.jpg&amp;#41</a>; &amp;#13;** Chimère — **Créatures aussi vieilles que la magie elle-même et solitaires. Ce sont de redoutables adversaires, même pour les plus grands guerriers.&amp;#13;/w gm ) - *Enahora* [Crabe Géant](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312154926049317515802.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312154926049317515802.jpg&amp;#41</a>; &amp;#13;** Crabe Géant — **Fort d'une grande puissance dans leur pince, si un crabe géant vous attrape, il sera très difficile de vous libérer seul.&amp;#13;/w gm ) - *Enahora* [Gargouille](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312155026049317515806.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312155026049317515806.jpg&amp;#41</a>; &amp;#13;** Gargouille — **Créatures nées de la magie, ces monstres ailés sont de redoutables prédateurs sont aussi solides que la pierre dont ils sont issus.&amp;#13;/w gm ) - *Enahora* [Gobelin](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312155326049317515815.png&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312155326049317515815.png&amp;#41</a>; &amp;#13;** Gobelin — **Petites créatures repoussantes et insupportables, ils aiment monter des embuscades pour voler les voyageurs. &amp;#13;/w gm ) - *Enahora* [Golem](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312155126049317515808.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312155126049317515808.jpg&amp;#41</a>; &amp;#13;** Golem — **Créatures née de l'alchimie des éléments, ils sont brutaux et n'obéissent qu'à leur créateur.&amp;#13;/w gm ) - *Enahora* [Goule](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312155126049317515809.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312155126049317515809.jpg&amp;#41</a>; &amp;#13;** Goule — **Créatures immondes et effrayantes, produits de sombres expériences. Ils hantent désormais les cimetières.&amp;#13;/w gm ) - *Enahora* [Griffon](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312155126049317515811.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312155126049317515811.jpg&amp;#41</a>; &amp;#13;** Griffon — **Créatures craintes autant que respectées, ils peuplent les reliefs montagneux du continent.&amp;#13;/w gm ) - *Enahora* [Harpie](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312155226049317515813.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312155226049317515813.jpg&amp;#41</a>; &amp;#13;** Harpie — **Véritables monstruosités, ces hybrides raffolent de la chair fraîche comme les enfants.&amp;#13;/w gm ) - *Enahora* [Loup Garou Sauvage](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312161726049317515821.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312161726049317515821.jpg&amp;#41</a>; &amp;#13;** Loup Garou Sauvage — **Contrairement aux lycans, ce sont des êtres maudit incapable de reprendre leur forme initiale. Ils sont aussi rapides qu'assoiffés de sang.&amp;#13;/w gm ) - *Enahora* [Lutin](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312161726049317515823.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312161726049317515823.jpg&amp;#41</a>; &amp;#13;** Lutin — **Petite créature envahissante qui aime s'infiltrer dans les maisons pour voler tout et n'inmporte quoi.&amp;#13;/w gm ) - *Enahora* [Manticore](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312161826049317515824.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312161826049317515824.jpg&amp;#41</a>; &amp;#13;** Manticore — **Originaires des contrées désertiques, le venin de ces créatures est considéré comme l'un des plus redoutables.&amp;#13;/w gm ) - *Enahora* [Minotaure](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312161826049317515825.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312161826049317515825.jpg&amp;#41</a>; &amp;#13;** Minotaure — **Créatures méconnues et incomprises, ils restent à l'écart de la civilisation mais n'hésitent pas à défendre leur territoire.&amp;#13;/w gm ) - *Enahora* [Ogre](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312161926049317515828.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312161926049317515828.jpg&amp;#41</a>; &amp;#13;** Ogre — **Aussi stupides qu'immenses, ils passent le plus clair de leur temps à se goinfrer et à dormir. Mais prenez gare, un seul de leur coup de massue suffit à assomer plusieurs chevaux.&amp;#13;/w gm ) - *Enahora* [Ork](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312161926049317515829.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312161926049317515829.jpg&amp;#41</a>; &amp;#13;** Ork — **Originaires de sombres contrées aujourd'hui disparues, ils se délectent de massacres et de pillages et ils aiment s'attaquer plus particulièrement aux caravanes marchandes.&amp;#13;/w gm ) - *Enahora* [Rat Géant](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312162026049317515832.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312162026049317515832.jpg&amp;#41</a>; &amp;#13;** Rat Géant — **Véritable nuisible qui infeste les souterrains et les égouts des grandes villles.&amp;#13;/w gm ) - *Enahora* [Scolopendre](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312162026049317515833.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312162026049317515833.jpg&amp;#41</a>; &amp;#13;** Scolopendre — **Grand insecte aux innombrables pattes vivant surtout dans les marais ou le désert.&amp;#13;/w gm ) - *Enahora* [Scorpion Géant](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312162026049317515834.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312162026049317515834.jpg&amp;#41</a>; &amp;#13;** Scorpion Géant — **Créature emblématique du désert qui représente un danger certain pour les voyageurs autour de Lockyr.&amp;#13;/w gm ) - *Enahora* [Skaven](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312162126049317515835.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312162126049317515835.jpg&amp;#41</a>; &amp;#13;** Skaven — **Hybridation entre l'homme et le rat, plus intelligent que ce dernier. Ils séjournent aussi bien à Maïn Sonha qu'à l'état sauvage dans les égouts.&amp;#13;/w gm ) - *Enahora* [Tentaculaire](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312161926049317515830.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312161926049317515830.jpg&amp;#41</a>; &amp;#13;** Tentaculaire — **Créatures sournoises et troglodytes, elles se cachent dans l'ombre des cavernes, à l'affut d'un avanturier imprudent.&amp;#13;/w gm ) - *Enahora* [Troll](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312165526049317515839.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312165526049317515839.jpg&amp;#41</a>; &amp;#13;** Troll — **Créatures laides et grossières, ils prennent un malin plaisir à massacrer le bétail pour le plaisir.&amp;#13;/w gm ) - *Enahora* [Vampire Sauvage](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312155326049317515816.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312155326049317515816.jpg&amp;#41</a>; &amp;#13;** Vampire Sauvage — **Originaires de'Hombrolis, ce sont des créatures sauvages et sanguinaires, qui terrorisent fermes et villlages à la tombée de la nuit.&amp;#13;/w gm ) - *Enahora* [Vouivre](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312165626049317515841.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312165626049317515841.jpg&amp;#41</a>; &amp;#13;** Vouivre — **Lointaines cousines des dragons, elles sont plus petites et véloces. Les vouivres sont dépourvus de glandes leur permettant d'utiliser un souffle élémentaire.&amp;#13;/w gm ) - *Enahora* [Warg](!/&amp;#13;[Image](<a href="https://nsm09.casimages.com/img/2021/08/03//21080312165626049317515842.jpg&amp;#41" rel="nofollow">https://nsm09.casimages.com/img/2021/08/03//21080312165626049317515842.jpg&amp;#41</a>; &amp;#13;** Warg — **Bien plus grands et féroces que les loups, ils chassent en meute et peuvent traquer leurs proies pendant des jours jusqu'à l'épuisement. Méfiez-vous des routes isolées la nuit.&amp;#13;/w gm ) - *Enahora* }}
1628176861

Edited 1628177014
The Aaron
Roll20 Production Team
API Scripter
You can provide a link in chat that opens a handout or character.&nbsp; The easiest way to do that is by creating a link in a handout and copying it: [Faceless]( <a href="http://journal.roll20.net/handout/-MHT13I0mhd3d08fF1N6" rel="nofollow">http://journal.roll20.net/handout/-MHT13I0mhd3d08fF1N6</a> )
The Aaron said: You can provide a link in chat that opens a handout or character.&nbsp; The easiest way to do that is by creating a link in a handout and copying it: [Faceless]( <a href="http://journal.roll20.net/handout/-MHT13I0mhd3d08fF1N6" rel="nofollow">http://journal.roll20.net/handout/-MHT13I0mhd3d08fF1N6</a> ) I can't do that because I use this script of keithcurtis&nbsp; <a href="https://app.roll20.net/forum/post/6676805/npc-directory-macro-and-spreadsheet-version-2" rel="nofollow">https://app.roll20.net/forum/post/6676805/npc-directory-macro-and-spreadsheet-version-2</a> &nbsp;and all the description are generated by an excel sheet and there are directly generated in the macro
1628183315
The Aaron
Roll20 Production Team
API Scripter
Ah.&nbsp; That's going to take some redesign by Keith to get that functionality to work.
The Aaron said: Ah.&nbsp; That's going to take some redesign by Keith to get that functionality to work. It was what I think too. But if anyone want to help me to modify the formula in the excel sheet or the macro it's could be cool because I don't have found anything about how to open a pop-up with a macro's content.
1628190122
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Question: can you define what you mean by a "pop-up"? You can display information in one of two places in Roll20 without resorting to a script: In chat or in a handout. Do you mean opening a pre-defined handout?
keithcurtis said: Question: can you define what you mean by a "pop-up"? You can display information in one of two places in Roll20 without resorting to a script: In chat or in a handout. Do you mean opening a pre-defined handout? A pop-up window like what is used by the character sheet when we open it in an external window.
1628196011
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
OK, a handout would function similarly to that. Whether it pops out into an external window is set by the user's in-game preferences. Without using a specialized API script, you would need to pre-set what to open. You would also have to deal with permissions. By default, a monster is not usually in a player's journal list. You would need to make them available. Alternatively, you could link to the monster's compendium page instead of its journal entry, but that would expose the statblock, which might be more info than you want to share. You might want to look into the Supernotes API, which allows you to display monster images, notes, gmnotes or token notes, based on a selected monster. It can also be set to use token ID instead of a selection, so that could be used to set up a menu for players ahead of time without giving them control of the monster token. The catch to that is that it displays the info only in the chat, and does not open a handout.
1628197778

Edited 1628197928
keithcurtis said: OK, a handout would function similarly to that. Whether it pops out into an external window is set by the user's in-game preferences. Without using a specialized API script, you would need to pre-set what to open. You would also have to deal with permissions. By default, a monster is not usually in a player's journal list. You would need to make them available. Alternatively, you could link to the monster's compendium page instead of its journal entry, but that would expose the statblock, which might be more info than you want to share. You might want to look into the Supernotes API, which allows you to display monster images, notes, gmnotes or token notes, based on a selected monster. It can also be set to use token ID instead of a selection, so that could be used to set up a menu for players ahead of time without giving them control of the monster token. The catch to that is that it displays the info only in the chat, and does not open a handout. I see what you said. But I have 2 problems with this. First, I don't have any access to a compendium because it's a personal game system. Second, I don't have any sheet for the monsters. I have used your NPC Macro creator sheet to create the macros for my bestiary. And I have create a menu to access at the different parts of the bestiary, it's only seen by the player who used the macro menu, but the infos about the monsters are displayed in the public chat. But I can see an other solution. It is possible to use a command as the /me to open a pop-up window with the content or to display the content only for the player who consult it ? Sorry, if my explanations are a little obscure, my english isn't perfect.
1628200408
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
You can only do this if you set the permissions ahead of time. Without the API, it is only possible to set permissions at the time the macro is used to All Players. To do what you are trying to do will require you to: Set up handouts for each "pop-up" you want. Set the Permissions to All Players. Set up a macro which can call those handouts, using the method the Aaron described above.
keithcurtis said: You can only do this if you set the permissions ahead of time. Without the API, it is only possible to set permissions at the time the macro is used to All Players. To do what you are trying to do will require you to: Set up handouts for each "pop-up" you want. Set the Permissions to All Players. Set up a macro which can call those handouts, using the method the Aaron described above. Ok thanks but I prefer to let it as this. It will be too long for realise all the handouts for the bestiary. Thanks a lot for infos.