[D&D3.5 + Pathfinder] MT1.3b86.02 Campaign Framework

Discussion concerning lmarkus' campaign framework for D&D3.x and Pathfinder.

Moderators: Azhrei, dorpond, trevor, giliath, Gamerdude, jay, Mr.Ice, lmarkus001

Forum rules
Discussion regarding lmarkus001's framework only. Other posts deleted without notice! :)
User avatar
lmarkus001
Great Wyrm
Posts: 1862
Joined: Sat Mar 29, 2008 12:30 am
Location: Layfayette Hill, PA

[D&D3.5 + Pathfinder] MT1.3b86.02 Campaign Framework

Post by lmarkus001 »

THIS IS AN OLD VERSION OF THE FRAMEWORK!
MT1.3.86.02_DnD35_Pathfinder.cmpgn

Note that with all the add-ins this is now a 22MB download.


1.3b86_02
=========
  • Merged in Neofax's PF campaign file so his update effort should be less going forward.
  • Merged in Aliasmask's campaign file.
    NOTE: I made personal choices with regards to these merges, so there are some differences.

  • Included Wolf42's Beta tools (teleport pads and forest generator, etc.)
  • Included Plotho's Beta 3.0 Spell Manager, 2.04 Spell Manager, and his Inventory Manager

  • Initial Campaign Button Reformatting. A fair bit of discussion and thought is going into these. There are at least two differing camps, "Keep em small" & "Make em easier to find". These are somewhat mutually exclusive, and with the current window the organized approach denies a horizontal layout. So more thought and fiddling to come.

  • Active Mods: Unholy Aura, Heroes Feast
  • Vital Strike Feat
  • Enhanced the ManyShot Feat: Now prompts for ManyShot in attack dialog only if you have the feat, if chosen, RapidFire is removed, attack option is set to Standard (not Full round), and a -4 tempATK penalty is applied. Damage corrected: Only shows if you chose ManyShot from attack dialog. Shows multiple arrows should your BAB be high enough. Adds special weapon damage (like flaming) and removes precision damage (Ranger favored enemy).

  • Adjust Action Points: Allow easy setting of daily number and current availability.
  • Concentration: Made it work for both systems. I assume D&D3.5 DMs will remove the macro since it is covered by Skill Check and Concentration on the character sheet, but for those that leave it, it will work correctly.

  • Crit Range Modifier: You can now specify a value in the attack dialog that will reduce each attack's threat range by that value. So if you want to guarantee a threatened critical, enter 20 (20-20=0 which is < 1 which is the lowest number a die can roll).
  • Critical Confirmation: Added Critical Confirmation persistent value to the attack dialog. You can enter a formula (like 4+IntB) into that field and that value will be added to critical confirmation to hit rolls. If you selected the feat Critical Focus, it will now show in this new field as a +4 bonus.

  • Secret Tooltips: Reworked GM detection and output code so should eliminate duplicate entries for GMs and work better.
  • Updated D&D3.5 special attacks so they have nicer tooltips and can be rolled secretly (this was previously done for PF).

  • Tweaked Lights & Auras: Now should be correct size from center of square. Silence deviates from this as it is most often cast on an intersection.

  • Move Tokens: Now gives map locations dialog if no tokens were selected
  • Map Locations Dialog: Has a link to move you to a desired map. Has a new button to add an entry point based on the selected token's location. (See this post for info: viewtopic.php?f=46&t=10642&start=40 )
Last edited by lmarkus001 on Sat Sep 17, 2011 5:52 pm, edited 15 times in total.

neofax
Great Wyrm
Posts: 1694
Joined: Tue May 26, 2009 8:51 pm
Location: Philadelphia, PA
Contact:

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by neofax »

Thanks! I am thinking about Smite and how to have it work.

User avatar
aliasmask
Deity
Posts: 8578
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by aliasmask »

Ack! Can you also include this update to the output. This fixes the double output to GMs and also fixes the GM list with multiple GMs.

[spoiler=||| onCampaignLoad |||]

Code: Select all

@@ @onCampaignLoad
[H: gLib = "Lib:GlobalsSRDPF" ]

[
H: gStartMap = getLibProperty( "StartMap", gLib )]
[
H, IF( json.isEmpty( gStartMap ) ), CODE: {
  [ sMap = getCurrentMapName() ]
  [ sX = 0 ]
  [ sY = 0 ]
};
 {
  [ sMap = json.get( gStartMap, "name" ) ]
  [ mAvail =  listFind( getAllMapNames(), sMap ) ]
  [ sMap = if( mAvail < 0, getCurrentMapName(), sMap ) ]
  [ sX = json.get( gStartMap, "x" ) ]
  [ sY = json.get( gStartMap, "y" ) ]
}]

[
H: setCurrentMap( sMap ) ]
[
H: goto( sX, sY ) ]

[
H: plGM = getLibProperty( "PlayersGM", gLib ) ]
[
H, if( json.isEmpty( plGM )): plGM = "[]"]

[
H, if(isGM()), code: {
   [H: plGM = json.intersection(plGM,getAllPlayerNames("json"))]
   [H: setLibProperty("PlayersGM", json.union( plGM, getPlayerName() ), gLib )]
};{}]

[
H: gEoL = getLibProperty( "EditOnLoad", gLib )]
[
H, IF(gEoL && isGM()), CODE: {
  [MACRO("[email protected]"): ""]
}]

!!
 
[/spoiler] [spoiler=||| subGetAllOtherPCPlayers |||]

Code: Select all

@@ @subGetAllOtherPCPlayers
@PROPS@ fontColor=black ; autoExecute=true ; fontSize=11pt ; sortBy=16 ; color=pink ; playerEditable=false ; applyToSelected=false ; group=Utility ; tooltip= ; minWidth=147 ; 
[H: gLib = "Lib:GlobalsSRDPF" ]

[
H: allPlay = getAllPlayerNames("json") ]
[
H: playersGM = getLibProperty( "PlayersGM", gLib ) ]
[
H: playersGM = if( json.type( playersGM ) == "ARRAY", playersGM, "[]" ) ]
[
H: allOtherPC = json.difference( allPlay, json.append(playersGM,getPlayerName()) ) ]
[
H: macro.return = allOtherPC ]

!!
 
[/spoiler]

This code replaces the current output where secret rolls are possible.

Code: Select all

[R,G,S: outputwTip]

[if(! flagSecret), code: {
   [R,W(allOtherPC): output]
};{}]

The change is mostly the same throughout with this one exception: charSavingThrow

Actually, there may be one more spot where "secret" was used as the variable. I just changed the input to flagSecret in that case. (ah, one is in charSkillCheck)

User avatar
aliasmask
Deity
Posts: 8578
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by aliasmask »

@neofax - I just added another damage variable for "firstAttack" and "firstDamage".

Also, Lindsay. Can you take a look at my framework. I have a request to make the buttons prettier and organized similar to how I have it... feel free to change whatever though.

Things I specifically would like you to take a look at is:
  • Spell Menu - It does use Plothos's 3.0.0 beta (I haven't had any problems), but with some minor changes to have it work with framework. You need to add a couple of token props. Also, this macro will reset the data on tokens with existing spell info because previous formats are incompatible with this one.
  • Call Tokens - click any token and summon tokens to that spot.
  • Move Tokens - w/ selected tokens - move tokens to map point, w/o selected tokens - bring up map point creation tool
  • Edit Macros - My latest incarnation of RPEdit.
  • Use Disguise - First version of Disguise
  • Impersonate - w/ selected token - impersonate owned token. Will "reacquire" id if token changes maps (and id changes). w/o selected token - GM can make up a name to impersonate and it doesn't have to have a token. Players can use this tool too in case they have multiple owned tokens.
  • Spell Library - an updated version that has tooltips and is compatible with Plothos's Spell Manager
  • Open Inventory - Uses lib:inventory. I haven't tested this much, but I think there may be a bug for players. GM seems to work just fine though.
  • NOTES - This has been modified to work for players as well. The GM can view PC token notes or write his own notes to the lib token by selecting an NPC token on any map. This is fully functional, but has one menu popup that is a WIP (selecting players to send to... only the bottom checkboxes work, so ignore the top radio button.) I have a game in 30 min, but I'll see if I can finish that update before you post your new release so it can be included.

I also included the updated version of Token Manager for looking at token props.
lib:chat is required for Impersonate
lib:disguise is required for Disguise
Lib:msg_mngr is required for NOTES

lib:tabs is something new I'm working on.

Campaign also includes Limbo, a players waiting room and a chess board (no macros, yet)

MT1.3.86_DnD35PathfinderCore01_AM2

User avatar
lmarkus001
Great Wyrm
Posts: 1862
Joined: Sat Mar 29, 2008 12:30 am
Location: Layfayette Hill, PA

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by lmarkus001 »

aliasmask wrote:Also, Lindsay. Can you take a look at my framework. I have a request to make the buttons prettier and organized similar to how I have it... feel free to change whatever though.


Sure thing, I will do this before release as I would like to incorporate as much of "what I like" as I can :-) (and this makes making tweaks easier if I incorporate all the tweaks I am comfortable with).

I saw the discussion of "prettier button layout". While this makes it easier for the new player to find buttons, it chews up a MASSIVE amount of screen real estate! So I am very torn over doing the buttons this way. Through the various iterations I have tried to reduce the number and size of buttons so they can fit in a small area. Hummm... maybe I will put up a poll (and for certain I will poll my group).

User avatar
aliasmask
Deity
Posts: 8578
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by aliasmask »

This is how I typically have my windows set up:

[spoiler=/// Screen Capture \\\]
Image1.jpg
Image1.jpg (496.77 KiB) Viewed 4993 times
[/spoiler]

But I do have a wide screen. I just use the scroll on my mouse when I need to use some gm functions.

User avatar
lmarkus001
Great Wyrm
Posts: 1862
Joined: Sat Mar 29, 2008 12:30 am
Location: Layfayette Hill, PA

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by lmarkus001 »

Yeah I use this layout (although I usually have the Dicebox, Spell menu, and Character Sheet unpinned on the right side to pop out when desired):

[spoiler=SCREEN CAPTURE]
MTLayout.png
MTLayout.png (163.84 KiB) Viewed 4991 times
[/spoiler]

User avatar
lmarkus001
Great Wyrm
Posts: 1862
Joined: Sat Mar 29, 2008 12:30 am
Location: Layfayette Hill, PA

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by lmarkus001 »

aliasmask wrote:Ack! Can you also include this update to the output. This fixes the double output to GMs and also fixes the GM list with multiple GMs.



Ok the issue with this onLoad is that it always updates the global property if the person loading is a GM.

So key parts to my approach are:

1) Only update if an update is required. This reduces collisions when 2 folks connect at the same time.
2) Demote at player that was a GM and is now just a Player.

The issue I had was the global property was not always updating (hence the campaign macro to refresh the list). There seems to be some timing/race issues around writing a global property in onLoad.

UPDATE: Ah, I see what you are doing with the output, yes that is more elegant. Now to figure the onLoad bit a tiny bit better....

UPDATE2: Ah, it used to be the case that [R,S,G: "text"] would send duplicates to the GM if the GM issued it. This must have gotten fixed.
Last edited by lmarkus001 on Thu Sep 08, 2011 12:07 pm, edited 1 time in total.

User avatar
aliasmask
Deity
Posts: 8578
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by aliasmask »

Code: Select all

[H, if(isGM()), code: {
   [
HplGM json.intersection(plGM,getAllPlayerNames("json"))]
   [
HsetLibProperty("PlayersGM"json.unionplGMgetPlayerName() ), gLib )]
};{}] 

Only updates when GM is loading, it removes anyone who's not currently in the players list, then adds the current GM name. I like your solution to updating another lib token. Seems to help on the race condition. I had another way of doing it. I would get current map and if it wasn't the lib map, I would change the map to lib map (at top of macro), then at bottom I would set property, then change map back. The couple of lines in between seemed to fix the race condition and token duplication. Only side effect would be a split second of black screen, but on load, didn't make any difference.

neofax
Great Wyrm
Posts: 1694
Joined: Tue May 26, 2009 8:51 pm
Location: Philadelphia, PA
Contact:

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by neofax »

aliasmask wrote:@neofax - I just added another damage variable for "firstAttack" and "firstDamage".

In Pathfinder Smite works differently than 3.5 it is not just a base increase of 1 per level. Yes, you could just double the damage if the creature was a Outsider/Undead or Dragon.

User avatar
lmarkus001
Great Wyrm
Posts: 1862
Joined: Sat Mar 29, 2008 12:30 am
Location: Layfayette Hill, PA

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by lmarkus001 »

neofax wrote:
aliasmask wrote:@neofax - I just added another damage variable for "firstAttack" and "firstDamage".

In Pathfinder Smite works differently than 3.5 it is not just a base increase of 1 per level. Yes, you could just double the damage if the creature was a Outsider/Undead or Dragon.


I prefer killing anything that can Smite before it can Smite... problem solved!

neofax
Great Wyrm
Posts: 1694
Joined: Tue May 26, 2009 8:51 pm
Location: Philadelphia, PA
Contact:

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by neofax »

lmarkus001 wrote:
neofax wrote:
aliasmask wrote:@neofax - I just added another damage variable for "firstAttack" and "firstDamage".

In Pathfinder Smite works differently than 3.5 it is not just a base increase of 1 per level. Yes, you could just double the damage if the creature was a Outsider/Undead or Dragon.


I prefer killing anything that can Smite before it can Smite... problem solved!

So you hate Monks and Paladins, what do you like? Fighters and Wizards or just creatures?

BTW, love the rain here lately? The Schuylkill and the Boulevard is closed from all the dirt and mud.

User avatar
lmarkus001
Great Wyrm
Posts: 1862
Joined: Sat Mar 29, 2008 12:30 am
Location: Layfayette Hill, PA

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by lmarkus001 »

Yeah took my wife 2.5 hours to get to work this AM.

I LOVE dead things. They never talk back.

More seriously, I will try to get some sorta Smite into this release...

User avatar
aliasmask
Deity
Posts: 8578
Joined: Tue Nov 10, 2009 6:11 pm
Location: Bay Area

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by aliasmask »

aliasmask wrote:

Code: Select all

[H, if(isGM()), code: {
   [H: plGM = json.intersection(plGM,getAllPlayerNames("json"))]
   [H: setLibProperty("PlayersGM", json.union( plGM, getPlayerName() ), gLib )]
};{}]
 

Only updates when GM is loading, it removes anyone who's not currently in the players list, then adds the current GM name. I like your solution to updating another lib token. Seems to help on the race condition. I had another way of doing it. I would get current map and if it wasn't the lib map, I would change the map to lib map (at top of macro), then at bottom I would set property, then change map back. The couple of lines in between seemed to fix the race condition and token duplication. Only side effect would be a split second of black screen, but on load, didn't make any difference.

Ah, yes. There is one thing I forgot with that update. Demoting GMs to players. It works fine when the server is first started, but if a person logs in as a 2nd GM, but then relogs as a player with the same name, they'll still get the GM info for output. This can be resolved by the following change:

Code: Select all

[H, if(! json.isEmpty(plGM)): plGM = lower(plGM)]
[
H: playerName = lower(getPlayerName)]
[
H, if(isGM()), code: {
   [H: plGM = json.intersection(plGM,lower(getAllPlayerNames("json")))]
   [H: setLibProperty("PlayersGM", json.union( plGM, playerName), gLib )]
};{
   [H, if(json.contains(plGM,playerName)): setLibProperty("PlayersGM", json.remove(plGM,playerName), gLib)]
}]
 

edit: also, needed to account for case because Chris != chris when making json comparisons but maptool would convert and treat as the same.

User avatar
lmarkus001
Great Wyrm
Posts: 1862
Joined: Sat Mar 29, 2008 12:30 am
Location: Layfayette Hill, PA

Re: [D&D3.5 + Pathfinder] MT1.3b86 Campaign Macros r02 (Soon

Post by lmarkus001 »

I am taking that a couple of steps further. I am testing to see if an update needs to happen, and if it does, swap to the map that the library token is on, then do the update.

Code: Select all

[H: libMap = "~~ Libraries & Utils" ]

[
H: plGM = getLibProperty( "PlayersGM", gLib ) ]
[
H, IF( json.isEmpty( plGM )): plGM = "[]"]

[
H, IF( ! json.isEmpty(plGM)): plGM lowerplGM ) ]
[
HplayerName lowergetPlayerName() ) ]

[
H, IF(isGM()), CODE: {
   [H: plGM2 = json.intersection( plGM, lower( getAllPlayerNames("json") ) ) ]
   [H: doUpdate = if( json.isEmpty( json.difference( plGM, plGM2 ) ), 0, 1 ) ]
   [H, IF( doUpdate ): setCurrentMap( libMap ) ]
   [H, IF( doUpdate ): setLibProperty("PlayersGM", json.union( plGM2,  playerName ), gLib ); "" ]
};{
   [H: doUpdate = if( json.contains(plGM,playerName), 1, 0 ) ]
   [H, IF( doUpdate ): setCurrentMap( libMap ) ]
   [H, IF( doUpdate ): setLibProperty("PlayersGM", json.remove( plGM, playerName ), gLib ) ]
}]
 

Post Reply

Return to “[D&D3.5 + Pathfinder] Campaign Macros”