Actors are Actors
Admittedly, both Sharpee and Chord are still very young and cranky. I continually find seams in both through working with Chord. In my latest set of activities, I started to port my old Textfyre game, Jack Toresal and The Secret Letter, to Chord. I'd talked to Mike Gentry earlier in the year about making a new version with specific changes and he loved all of it. Sadly, he's moved on from IF and was not interested in helping. I'll eventually have a separate post about these changes, but I'll summarize by saying I'm opening the world up and removing the rails (those were intentional for the target audience) and changing the main character in a very important and present-day meaningful way. I am using Claude to port the code, but all content changes are mine, including puzzles/logic/text.
A problem surfaced from complaints I had about event capturing in actor/npc blocks in Chord. There was a lot of what I call inelegant phrasing to the syntax. That led to digging into the differences between the player character and NPCs in Sharpee and Chord and this seam was telling me that NPCs needed to be dissolved into the platform and Actor was a singular architecture concept.
This is the offending language that started everything...
after entering it, while the stall is blocked
phrase keeper-yells
move the player to an adjacent room, randomly
end afterI was bothered that a) the target actor is not identified here, and b) 'it' is ceremonial and not really necessary. Pushing on those two seams followed this progression:
create the sword
on taking it
refuse sword-not-for-you
end oncreate the sword
on the player taking
refuse sword-not-for-you
end onIn the below example, we explicitly say who the event capture is targeting...in this case the Actor currently designated as the player.
create the Grocery Stall
a room
states: open, blocked
after the player entering, while the Grocery Stall is blocked
phrase keeper-yells
move the player to a random adjacent room
end afterThe only exception is an actors own block:
create Jack
a person
playable
starts in the Northwest Junction
on going while the wandering mercenaries is aggressive
refuse merc-held
end onIn this case, there is only one target actor so explicitly naming the actor would be redundant.
And for 'it' and 'its', they survive in one place: Trait definitions...
define trait kick-escape
on the player kicking
refuse when it is oblivious: merc-dont-provoke
phrase merc-break-free-kick when it is aggressive
change it to approaching
reset its lunge
start its recovery
end on
end traitThis also led to the player being a role that can be changed.
Before...
create the player
starts in the Northwest Junction
kick-yourself
wears the old gray cloak
wears the woolen cap
wears the boots
carries the cloth satchel
Jack Toresal, who has been a boy in this market for as long as anyone here has
bothered to look.
on going while the wandering mercenaries is aggressive
refuse merc-held
end on
after going while hunted
restart waiting
end after
And now that will be...
create Jack
a person
playable
starts in the Northwest Junction
Jack Toresal, who has been a boy in this market for as long as anyone here has
bothered to look.
on going while the wandering mercenaries is aggressive
refuse merc-held
end onWith the new block...
before the game starts
change the player to Jack
end beforeWhich allows us to change the player character when we choose...
create Viola
a person
playable
starts in the Chapel
Viola.
create the Chapel
a room
A chapel.
after Jack examining the seal
phrase cut-to-viola
change the player to Viola
end afterAnd now all actors in chord are the same and one is the player character at any designed time. All of their actions thread through the platform exactly as the player character does today. (and no, this was not the case for the current npc-plugin architecture).
This is a very big change to Sharpee and Chord, so needs full regressions with both and the platform and chord sample stories.