Fate of the Norns

The Complete Viking Experience!
It is currently Wed Apr 01, 2020 2:29 pm

All times are UTC - 5 hours


Forum rules


No cyber-bullying, no racism, no spam! Keep discussions civil and respectful or you will be banned!



Post new topic Reply to topic  [ 14 posts ]  Go to page 1, 2  Next
Author Message
 Post subject: Roll20
PostPosted: Mon Mar 16, 2020 10:29 am 
Offline

Joined: Thu Jan 09, 2020 2:43 pm
Posts: 18
Given the whole COVID-19 situation, my group is going online via Roll20 for a bit. Does anyone have or is interested in developing a character sheet and deck of runes for roll20?


Top
 Profile  
 
 Post subject: Re: Roll20
PostPosted: Wed Mar 18, 2020 1:16 pm 
Offline
User avatar

Joined: Thu Apr 25, 2013 10:39 am
Posts: 1174
I'm actually going on Roll20 Friday night.

I was reading over the fan built setups on these threads:
viewtopic.php?f=3&t=678&p=4314&hilit=roll20#p4314

and
viewtopic.php?f=10&t=344&hilit=roll20

This will be my first time, so thanks to the fans who have made these tutorials! :) :) :)

_________________
Image
https://twitter.com/avalkauskas
https://www.patreon.com/fateofthenorns


Top
 Profile  
 
PostPosted: Thu Mar 19, 2020 10:28 am 
Offline
User avatar

Joined: Thu Apr 25, 2013 10:39 am
Posts: 1174
I contacted Fantasy Grounds and to get our game on there, we need a developer willing to use their API to create a custom integration for FOTN. Do we have any keen developers interested in this? They said the programmer would get an ongoing commission for the work done, since users would need to subscribe.

_________________
Image
https://twitter.com/avalkauskas
https://www.patreon.com/fateofthenorns


Top
 Profile  
 
 Post subject: Re: Roll20
PostPosted: Sun Mar 22, 2020 11:00 am 
Offline

Joined: Thu Jan 09, 2020 2:43 pm
Posts: 18
I made a set of decks with runes and am looking to make some macros, but haven't but haven't really played around with their character sheet builder yet.


Top
 Profile  
 
 Post subject: Re: Roll20
PostPosted: Thu Mar 26, 2020 12:48 pm 
Offline
User avatar

Joined: Thu Apr 25, 2013 10:39 am
Posts: 1174
I would love it if someone made a set of macros that recalls played/drawn cards and shuffles all decks. This is a pain in the ass for the Norn right now.

I'm also curious, did anyone make Ragnarok dweller sheets yet?

_________________
Image
https://twitter.com/avalkauskas
https://www.patreon.com/fateofthenorns


Top
 Profile  
 
 Post subject: Re: Roll20
PostPosted: Thu Mar 26, 2020 1:05 pm 
Offline

Joined: Thu Jan 09, 2020 2:43 pm
Posts: 18
I haven't made dweller sheets yet, looking to get pro access this weekend. As far as I can tell, the macros don't give access to the decks by default, you need access to the API. I am at best a novice programmer and javascript is not my strong suit, but I've signed up at codeacademy to get the basics and will take a swing at the character sheet if no one else does.

FotN is a pretty crunchy system and I can tell that it was built by someone with a coding background. It should be possible to translate it.


Top
 Profile  
 
 Post subject: Re: Roll20
PostPosted: Sat Mar 28, 2020 1:03 pm 
Offline
User avatar

Joined: Thu Apr 25, 2013 10:39 am
Posts: 1174
We had our first battle on roll20 last night and discovered that recalling the runes to the deck will wipe out the damage you've taken. AGH! How did others get around this? Our solution was to just have everyone use the mobile rune app, and then synch their playmats on the actual table after wyrding or taking/healing damage. Oh lord I miss playing in person!

_________________
Image
https://twitter.com/avalkauskas
https://www.patreon.com/fateofthenorns


Top
 Profile  
 
 Post subject: Re: Roll20
PostPosted: Sat Mar 28, 2020 9:23 pm 
Offline

Joined: Thu Jan 09, 2020 2:43 pm
Posts: 18
I've been writing some scripts today. I have one that is usable by players and allows them to weird from their own decks and have the runes appear on their playmat (relies on some strict naming conventions for the playmat and decks).

I'm almost done with one that will allow you to select certain runes and then recall the ones not selected, though I may change it to recall the ones you have selected, now that you mention the damage track. If you PM me your roll20 email I will invite you to my Dev campaign so you can check them out, or I can post the code here if you like


Top
 Profile  
 
 Post subject: Re: Roll20
PostPosted: Sun Mar 29, 2020 4:13 pm 
Offline

Joined: Thu Jan 09, 2020 2:43 pm
Posts: 18
Here is a script to weird your destiny in runes. You have to have a deck with name of the character doing the weirding, a playmat named $character_name+" playmat" and attributes in the character journal called Destiny and Essence. It is called with an ability containing:
!weird [email protected]{character_name} [email protected]{Destiny}
Note: my runes are 20x30 pixels and my playmats are 490x560. If you change these dimensions then your runes probably won't end up in the "in hand" section and you will have to move them around yourself.

Code:
on('chat:message', (msg) => {
    if ('api' === msg.type && /!weird\b/i.test(msg.content)) {
            const args = msg.content.split(/\s+--/);
            //getid of deck
            //deck must have the same name as the character
        let theDeck = findObjs({
            _type: "deck",
            name: args[1]
        })[0];
        //test if deck exists
        if (!theDeck) {
            sendChat('Weird', '/w gm Create a deck named ' + args[1]);
            return;
        }
        //Playmat graphic must be named $character_name+" playmat"
        let playmat = findObjs({
            _type: "graphic",
            name: args[1]+" playmat"
        })[0];
        //Check to make sure the playmat exists
        if (!playmat) {
            sendChat('Weird', '/w gm You need to named ' + args[1] + ' playmat');
            return;
        }
        // Get the deck ID and list of cards in it
        let deckID = theDeck.id;
        let deckCards = theDeck.get('_currentDeck');
        var i;
        // Do a number of times equal to the character's destiny
        for (i = 0; i < args[2]; i++) {
            //Draw a card
            let card = findObjs({
                _id: drawCard(deckID)
            })[0];
            //Put the card on the playmat, will stagger cards so they don't all stack on top of eachother
            //These numbers are scaled to put the cards into the in hand area on my playmat. If you change
            //the playmat size you will need to change them
            playCardToTable(card.id, {left: playmat.get("left")+i*20-70, top: playmat.get("top")-110});
            //I don't know why this works, but it seems necessary to change the "controlledby" property
            let cardObj = findObjs({
                cardid: card.id
            })[0];
            //Make it so that anyone can control the cards. If you change "all" to args[1] it should limit
            //control to the initiating player
            cardObj.set("controlledby", "all");
        }
    }
});
       


Last edited by jstomel on Sun Mar 29, 2020 4:18 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Roll20
PostPosted: Sun Mar 29, 2020 4:18 pm 
Offline

Joined: Thu Jan 09, 2020 2:43 pm
Posts: 18
Here is a script to recall runes to the deck and shuffle during cleanup. As above, you need to have a deck with the same name as the character using it. It will leave in play any runes which you have selected when you call the ability. It is called as an ability with the text:
!cleanup [email protected]{character_name}

Code:
on('chat:message', (msg) => {
    if ('api' === msg.type && /!cleanup\b/i.test(msg.content)) {
        let selectedId = []
            const args = msg.content.split(/\s+--/);
            //getid of deck
        let theDeck = findObjs({
            _type: "deck",
            name: args[1]
        })[0];
        //test if deck exists
        if (!theDeck) {
            sendChat('cleanup', '/w gm Create a deck named ' + args[1]);
            return;
        }
        //If nothing is selected pick up all of the cards
        if (!msg.selected) {
            recallCards(theDeck.id);
            shuffleDeck(theDeck.id);
            log('blarg')
        }
        //If there are selected cards
        else {
            //get the info for cards in play
            let cards = cardInfo({type: "play", deckid: theDeck.id})
            //stick the selected card IDs in an array
            for (i = 0; i < msg.selected.length; i++) {
                selectedId[i] = msg.selected[i]._id;
            }
            //for each card in play
            for (i = 0; i < cards.length; i++) {
            //if it's not selected, pick it up to the hand
                if (!(selectedId.includes(cards[i].id))) {
                    pickUpCard(cards[i].cardid);
                }
            }
            //put the hand in the deck and shuffle
            recallCards(theDeck.id, 'hand');
            shuffleDeck(theDeck.id);
        }
    }
});
       


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 14 posts ]  Go to page 1, 2  Next

All times are UTC - 5 hours


Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Group