I'm having trouble using a macro.return function in a frame. Basically, I have a frame that takes player input. I send that information to another macro to be calculated. What I'd like that to do, is use a macro.return function to then display that information at the bottom of the same frame. It seems, though, that macro.return isn't working <form action***>.
A, is this even possible?
B, if not, is there some workaround? Perhaps reloading the same frame from the same calling macro with new jsons?
[macro.return] and frames
Moderators: dorpond, trevor, Azhrei, giliath, jay, Mr.Ice
- Xaelvaen
- Dragon
- Posts: 498
- Joined: Wed Aug 31, 2011 9:49 pm
- Location: Somewhere between Heaven and Hell
[macro.return] and frames
"An arrogant person considers himself perfect. This is the chief harm of arrogance. It interferes with a person's main task in life - becoming a better person." - Leo Tolstoy
Re: [macro.return] and frames
its possible, but not with macro.return. a different method is required: Forms tutorial
GETTING STARTED WITH MAPTOOLS - TUTORIALS, DOCS, VIDEOS, TOOLS, ETC
DISCORD (the new MT forum!)
My stuff
Excel Tools: Table and Light editors
MT Tools: Bag of Tricks: Tools for Maptool, Dungeon Builder I, Dungeon Builder II,onMouseOverEvent.
Frameworks: Dark Heresy, Rogue Trader, Deathwatch, Black Crusade, Only War, SET Card Game, RoboRally
Wiki: Debugging Tutorial, Speed Up Your Macros, Working With Two CODE Levels, Shortcut Keys, Avoiding Stack Overflow, READ THIS
DISCORD (the new MT forum!)
My stuff
Excel Tools: Table and Light editors
MT Tools: Bag of Tricks: Tools for Maptool, Dungeon Builder I, Dungeon Builder II,onMouseOverEvent.
Frameworks: Dark Heresy, Rogue Trader, Deathwatch, Black Crusade, Only War, SET Card Game, RoboRally
Wiki: Debugging Tutorial, Speed Up Your Macros, Working With Two CODE Levels, Shortcut Keys, Avoiding Stack Overflow, READ THIS
- Xaelvaen
- Dragon
- Posts: 498
- Joined: Wed Aug 31, 2011 9:49 pm
- Location: Somewhere between Heaven and Hell
Re: [macro.return] and frames
Not exactly what I was looking for - I used that tutorial to build my onChange~ character sheet. However, I just used a workaround like I mentioned above where the sheet is simply re-opened with the rolled information in place. Didn't want to do that, because it's a lot trickier, but since a simple macro.return wouldn't work, I guess I had no choice.
Thanks for the response, Wolph!
Thanks for the response, Wolph!
"An arrogant person considers himself perfect. This is the chief harm of arrogance. It interferes with a person's main task in life - becoming a better person." - Leo Tolstoy
Re: [macro.return] and frames
Yeah, there's no javascript so any changes made require the form to be redrawn. It's usually called a call back from another function. So, the macro you call needs call the callback to redraw the frame.
Downloads:
- Notepad++ MapTool addon
- RPEdit details (v1.3)
- Coding Tips: Modularity and Design
- Videos: Macro Writing Tools
- JamzTheMan
- Great Wyrm
- Posts: 1872
- Joined: Mon May 10, 2010 12:59 pm
- Location: Chicagoland
- Contact:
Re: [macro.return] and frames
FYI there is some javascript support in the dev version and my fork, although I have not played with it at all... Do a search and you should find some info?
Again, not sure if it will help you in this situation though, it's mostly an alternative way of doing macro logic AFAIK.
Again, not sure if it will help you in this situation though, it's mostly an alternative way of doing macro logic AFAIK.
-Jamz
____________________
Custom MapTool 1.4.x.x Fork: maptool.nerps.net
Custom TokenTool 2.0 Fork: tokentool.nerps.net
More information here: MapTool Nerps! Fork
____________________
Custom MapTool 1.4.x.x Fork: maptool.nerps.net
Custom TokenTool 2.0 Fork: tokentool.nerps.net
More information here: MapTool Nerps! Fork
- Xaelvaen
- Dragon
- Posts: 498
- Joined: Wed Aug 31, 2011 9:49 pm
- Location: Somewhere between Heaven and Hell
Re: [macro.return] and frames
I know absolutely nothing about javascript, and pretty much any html I use, I just use w3schools to tell me what I'm doing XD.
I just used the normal method of [openFrame] macro, [theSheet], and refreshing it all through macro.args. I was honestly just looking for a shortcut to that process, but it is what it is, and I'll get the job done one way or the other!
Thanks though, Jamz.
I just used the normal method of [openFrame] macro, [theSheet], and refreshing it all through macro.args. I was honestly just looking for a shortcut to that process, but it is what it is, and I'll get the job done one way or the other!
Thanks though, Jamz.
"An arrogant person considers himself perfect. This is the chief harm of arrogance. It interferes with a person's main task in life - becoming a better person." - Leo Tolstoy
- JamzTheMan
- Great Wyrm
- Posts: 1872
- Joined: Mon May 10, 2010 12:59 pm
- Location: Chicagoland
- Contact:
Re: [macro.return] and frames
No problem, definitely stick with what you are doing then!
-Jamz
____________________
Custom MapTool 1.4.x.x Fork: maptool.nerps.net
Custom TokenTool 2.0 Fork: tokentool.nerps.net
More information here: MapTool Nerps! Fork
____________________
Custom MapTool 1.4.x.x Fork: maptool.nerps.net
Custom TokenTool 2.0 Fork: tokentool.nerps.net
More information here: MapTool Nerps! Fork