Your browser lacks required capabilities. Please upgrade it or switch to another to continue.
<div style="font-style: italic; height: 50vh; display: flex; justify-content: center; flex-direction: column;">
<p style="text-align: left;">
The summer had inhaled and held its breath too long<br>
The winter looked the same, as if it never had gone<br>
And through an open window where no curtain hung<br>
I saw you, comin’ back to me.<br>
</p>
<p style="text-align: right;">
Jefferson Airplane
</p>
</div><<script>>
config.ui.stowBarInitially = true;
config.cleanupWikifierOutput = true;
<</script>>
<<remove "#menu">>
<<display "Initialise">>
<<set $_time = "present">>
<<set $_face = 1>>
<<Pronoun>>
<<set $prevloc = "NULL">>
<<set $loc = $ByTheRidge>>
<<set $Stage = "Stage1">>
<<set $Theme = "LightTheme">>
:: PassageDone [] /% Выполняется каждый ход %/<<goto "ScreenBuild">><<set $player.Name = "Myself">>
<<set $player.Sex = "M">>
<<set $player.Parent = "ByTheRidge">>Nothing unusual. Just getting a little cold.<<if $she.thoughtAbout < 3>>
<<Act $player "Think about her" "sheThinking">>
<</if>>
<<NoAct $player "Listen" "playerListen">>
<<NoAct $player "Smell" "playerSmell">>The eternal hum of the waves and the wind whispering with the sand. The silence of overcast sky and seagulls’ sharp squawks. Her laughing.I breathe in the cold air deeply. Smells of iodine and wet wood. Smells of the autumn ocean.<<set $ByTheRidge.Name = "By the ridge">>
<<set $ByTheRidge.counter = 0>><<set $ByTheRidge.counter++>>
<<switch $ByTheRidge.counter>>
<<case 1>> <<object "She" $she>> throws off her shoes and runs on gray sand, laughing. Her hair and her long scarf flutter in the wind.
<<case 2>> <<object "She" $she>> reaches the edge of the surf and continues to run on wet sand, splashing the coming waves.<br>“Hey, come on! What are you waiting for?” <<object "I" $player>> barely hear her lively voice over the ocean’s roar.
<<case 3>> <<object "She" $she>> spreads her arms and circles around great driftwood. Her laugh scares away the seagulls sitting there. Her coat flaps in the wind.
<<default>> <<object "She" $she>> keeps running on the cold beach, laughing and scattering the wet sand with her bare feet. Sometimes she stops and waves to <<object "me" $player>>.
<</switch>>Piercing wind rustles bushes on the edge of the <<prop "ridge" $ridge>> where the narrow path starts and runs down to the sand. The cold grayish-yellow <<prop "beach" $beach>> full of bleached driftwood slopes to the restless <<prop "water" $ocean>>, where the white dust flies off high dark waves. Squawking seagulls hang in the overcast October <<prop "sky" $sky>>.<<set $MODE = "CUTSCENE">>
<<set $ACTLOG = false>><<set $she.Name = "she">>
<<set $she.Sex = "F">>
<<set $she.Parent = "ByTheRidge">>
<<set $she.isCalled = false>>
<<set $she.thoughtAbout = 0>>Black coat, long checkered scarf. She looks happy.<<Act $she "Call her" "sheCalling">>
<<if $she.thoughtAbout < 3>>
<<Act $she "Think about her" "sheThinking">>
<<else>>
<<Go "Follow her" $NearTheWater>>
<</if>><<if !$she.isCalled>>
“You will get cold running like that!” I shout to her but she doesn’t hear me for the howling wind and roaring ocean.
<<else>>
She won’t hear.
<</if>><<set $she.isCalled = true>><<set $she.thoughtAbout++>>//<<switch $she.thoughtAbout>>
<<case 1>> How long have I known her? Two days? Three?<br>A random glance of gray eyes in the shopfront’s reflection. A shy smile. A hesitant “Hi”.<br>The same cautious and curious eyes behind the steam rising from the cup of tea in the cozy shadows of the cafe. Raindrops running down the glass, the hum of the city behind them. Mutual ideas, mutual tastes, mutual laugh, and mutual silence.
<<case 2>> A couple of days after I proposed the drive to the ocean, she immediately agreed “It would be great. I haven’t seen the ocean for so long.”<br>The morning was cloudy but not rainy, and now we’ve hit the road. For several hours we’ve listened to and sung with Roger Daltrey, laughing at the moments when neither of us remembered the lyrics.
<<case 3>> After another turn, the horizon has widened with the misty infinity of the ocean. She gasps, moves closer to the windshield and begins to watch the waves, steely and restless.<br>We’ve parked at the deserted observation deck and descended by the path familiar to me.<br>Just three days and I have brought her to my October beach…
<</switch>>//<<set $ridge.Name = "ridge">><<if $loc == $ByTheRidge>>
The sand of the ridge’s wall is held together only by bushes’ roots and the tide slowly erodes it. Every autumn I come here the border is farther away.<br>An old narrow path washed out by rainwater winds down from the top.
<<else>>
Wind’s blows at the bushes on the ridge is harder. They rustle and thrash against a gray sky.
<</if>><<set $beach.Name = "beach">><<if $loc == $ByTheRidge>>
In the distance, I see dark spots of seaweed washed ashore. Seagulls’ footprints crisscross all over the beach.
<<else>>
Sand sweeps over the ribbed surface of the beach, it rounds half-buried driftwoods, gathers in tiny dunes.
<</if>><<set $ocean.Name = "ocean">><<if $loc == $ByTheRidge>>
The ocean is gray and cold. As it is every autumn I come here. Waves of heavy steel water crush on the sand and crawl back as a white foam.
<<else>>
Waving is stronger now. Foamy ridges rise higher and higher and wind blows salty mists off their edges.
<</if>><<set $sky.Name = "sky">>Low shaggy rain-clouds cover the sky. They are just starting to stream over, but I see curtains of heavy rain far in the ocean. Several seagulls hang on the strong wind over the uneasy water.<<set $NearTheWater.Name = "Near the water">>
<<set $NearTheWater.CutsceneTimer = 0>><<if $NearTheWater.CutsceneTimer == 0>>
“Hi!” she joyfully calls me when there is just a dozen meters left.<br>
“Don’t you feel cold? Because I almost froze to death immediately,” I come near her and put her shoes down on the sand.<br>
“Just a bit,” she smiles looking upwards at me, her white fingers stroking away several stray hairs, “Would you help me, please?”
<</if>>I pick up her shoes, brush off the sand and follow her footprints.
<<replace ".location_name">><p style="height: 2.5em;margin: 0;"></p><</replace>>The breath of the <<prop "ocean" $ocean>> feels colder near the water. The <<prop "wind" $ridge>> throws the salty drops off the waves.
<<if $NearTheWater.CutsceneTimer == 0>>
Retreating foam reveals white spots of seashells in a smoothed surface of the <<prop "sand" $beach>>.
<<else>>
Retreating foam reveals white spots of seashells in a smoothed surface of the <<prop "sand" $beach>>.
<br><<object "We" $we>> walk along the surf holding our hands.
<</if>><<if $NearTheWater.CutsceneTimer < 3 || $NearTheWater.CutsceneTimer == 5>>
<<ActLoc "" "NearTheWaterCutscene">>
<<elseif $NearTheWater.CutsceneTimer == 3>>
<p style="display:flex;justify-content:center;font-style:italic">
<span style="flex-grow:2;"></span>
<span style="flex-grow:1;"><<Act $NearTheWater "Yes?" "NearTheWaterYes1">></span>
<span style="flex-grow:1;"><<Act $NearTheWater "I… don‘t know" "NearTheWaterDontKnow">></span>
<span style="flex-grow:2 ;"></span>
</p>
<<elseif $NearTheWater.CutsceneTimer == 4>>
<span style="font-style:italic">
<<Act $NearTheWater "Yes!" "NearTheWaterYes2">>
</span>
<</if>><<set $NearTheWater.CutsceneTimer++>>
/%<<set $MODE = "NULL">>%/<<if $NearTheWater.CutsceneTimer == 1>>
I hold her hand while she brushes off her feet and wears the shoes, then I close her black coat and button it all up. At last, I tie her scarf. “That’s better. Wouldn’t be great if you caught a cold because of me.”<br>
Suddenly she stands on tiptoe and kisses me briefly. Then blushes turns away and we just stand there watching the ocean.
<<elseif $NearTheWater.CutsceneTimer == 2>>
After several minutes she breaks the silence “Thank you for showing me this beach. It is a special place for you, isn’t it? We have known each other for a mere couple of days and still, you brought me here. I…” she crumples her scarf, struggling with words, “If you would allow me, I would want to come here with you all the time…” I am humbled with her confession and can’t find right words. Would I allow her? Her stiff lips, clutched scarf. Would I allow her, she asks?
<<elseif $NearTheWater.CutsceneTimer == 6>>
<<append ".feeling">>
<span class="theend">It is two of us now.</span>
<</append>>
<</if>>/%<<set $ACTLOG = true>>%/
<<if $NearTheWater.CutsceneTimer == 6>>
<<addclass ".passage" "blured">>
<<append ".location_actions">>
<p><br></p>
<</append>>
<</if>><<set $NearTheWater.CutsceneTimer++>>And suddenly I realize how lonely I am. Every detail, every bit of my self-contained world. All of these long days and nights just for myself. Walks on the streets, every time for some purpose and never for just the sake of it. Parties full of barely familiar faces. Impressions of movies with no one to share. Music playing just for one. Prose never read aloud. My own deserted beach…<br>
Isn’t this moment I’ve waited for so long?<<set $NearTheWater.CutsceneTimer++>>And suddenly I realize and I’m scared. Scared for my cozy self-contained world. For days and nights just for my own self. For bars with familiar barmen. For parties with new faces every time. For movies, music, books just for my own understanding. For freedom from relationships, duties, responsibilities. For almost my own beach…<br>
And from this very moment, another person’s intrusion could disrupt this. Am I ready to continue her inclusion in this world?<<set $NearTheWater.CutsceneTimer++>>I take a deep breath and say, looking at the ocean, “I… I would spend all my time here if only you were with me.”<br>
And everything changes. There is no ocean anymore, no beach, no impendent storm, and no scarf. It’s me, her and our mutual feeling just born:
<<append "#passages">>
<p class="feeling" style="height: 10vh;text-align: center;"></p>
<</append>><<set $NULL.Name = "NULL">>ПУСТОТА.<<set $_time = "past">> /% время действия (past, present, future) %/
<<set $_sex = "M">> /% пол (M,F,N) либо множественное число (P) %/
<<set $_face = 1>> /% от 1-го, 2-го или 3-го лица идёт повествование %/
<<set $ACTLOG = true>> /% писать ли название действия в лог? %/
<<set $EXAMISACT = false>> /% считать ли осмотр (виджеты object, prp) за ход? %/
/% шаблон локации %/
<<set $MODE = "NULL">>
<<set $locProto = {
ID: "",
Name: "",
Children: [],
Desc: "",
Enter: "",
Events: "",
Acts: "",
NoGo: "",
Visited: 0,
isJustEntered: false
};>>
/% шаблон объекта %/
<<set $objProto = {
ID: "",
Sex: "M",
Name: "",
NameG: "",
NameD: "",
NameA: "",
NameI: "",
NameP: "",
Children: [],
Parent: "",
Disabled: false,
Examined: 0,
Shooted: false,
isOpen: true,
Desc: "",
Acts: "",
Take: "",
Drop: "",
Open: "",
Close: ""
};>>
/% шаблон декорации %/
<<set $propProto = {
ID: "",
Name: "",
Parent: "",
Disabled: false,
Examined: 0,
Desc: ""
};>>
<<set $locsArray = Story.lookup("tags", "loc")>> /% список параграфов с локациями %/
<<set $objsArray = Story.lookup("tags", "obj")>> /% список параграфов с объектами %/
<<set $propsArray = Story.lookup("tags", "prop")>> /% список параграфов с декорациями %/
/% создание всех локаций по шаблону $locProto %/
<<for _k to 0; _k < $locsArray.length; _k++>>
<<= "<<set $"+$locsArray[_k].title+" = clone($locProto)>>">>
<</for>>
/% создание всех объектов по шаблону $objProto %/
<<for _k to 0; _k < $objsArray.length; _k++>>
<<= "<<set $"+$objsArray[_k].title+" = clone($objProto)>>">>
<</for>>
/% создание всех декораций по шаблону $propProto %/
<<for _k to 0; _k < $propsArray.length; _k++>>
<<= "<<set $"+$propsArray[_k].title+" = clone($propProto)>>">>
<</for>>
/% инициализация всех локаций %/
<<for _k to 0; _k < $locsArray.length; _k++>>
<<set _t = $locsArray[_k].title>>
<<display _t>>
<<= "<<set $"+_t+".ID = '"+_t+"'>>">>
<<= "<<set $"+_t+".Enter = '"+_t+"Enter'>>">>
<<= "<<set $"+_t+".Events = '"+_t+"Events'>>">>
<<= "<<set $"+_t+".Desc = '"+_t+"Desc'>>">>
<<= "<<set $"+_t+".Acts = '"+_t+"Acts'>>">>
<<= "<<set $"+_t+".NoGo = '"+_t+"NoGo'>>">>
<</for>>
/% инициализация всех объектов %/
<<for _k to 0; _k < $objsArray.length; _k++>>
<<set _t = $objsArray[_k].title>>
<<display _t>>
<<= "<<set $"+_t+".ID = '"+_t+"'>>">>
<<= "<<set $"+_t+".Desc = '"+_t+"Desc'>>">>
<<= "<<set $"+_t+".Place = '"+_t+"Place'>>">>
<<= "<<set $"+_t+".Acts = '"+_t+"Acts'>>">>
<<= "<<set $"+_t+".Take = '"+_t+"Take'>>">>
<<= "<<set $"+_t+".Drop = '"+_t+"Drop'>>">>
<<= "<<set $"+_t+".Open = '"+_t+"Open'>>">>
<<= "<<set $"+_t+".Close = '"+_t+"Close'>>">>
<</for>>
/% инициализация всех декораций %/
<<for _k to 0; _k < $propsArray.length; _k++>>
<<set _t = $propsArray[_k].title>>
<<display _t>>
<<= "<<set $"+_t+".ID = '"+_t+"'>>">>
<<= "<<set $"+_t+".Desc = '"+_t+"Desc'>>">>
<</for>>
/% инициализация персонажей %/
<<for _k to 0; _k < $objsArray.length; _k++>>
<<if Story.get($objsArray[_k].title).tags.includes("char")>>
<<set _t = $objsArray[_k].title>>
<<= "<<set $"+_t+"['Talk'] = '"+_t+"Talk'>>">>
/%<<= "<<set $"+_t+"['Topics'] = '"+_t+"Topics'>>">>
<<= "<<display $"+_t+".Topics>>">>%/
<</if>>
<</for>>
/% распределение «детей» по «родителям» %/
<<for _k to 0; _k < $objsArray.length; _k++>>
<<set _t = $objsArray[_k].title>>
<<= "<<set _p = $"+_t+".Parent>>">>
<<= "<<set $"+_p+".Children.push($"+_t+".ID)>>">>
<</for>>
/% если «родитель» не открыт, все «дети» не доступны %/
<<for _k1 to 0; _k1 < $objsArray.length; _k1++>>
<<= "<<set _t = $"+$objsArray[_k1].title+">>">>
<<if !_t.isOpen>>
<<closeobj _t>>
<</if>>
<</for>>
/%
,, ,, ,, ,,
.g8""8q. *MM db mm `7MM mm mm db
.dP' `YM. MM MM MM MM MM
dM' `MM MM,dMMb.`7MM .gP"Ya ,p6"bo mmMMmm ,6"Yb. MM mmMMmm .gP"Ya `7Mb,od8 ,6"Yb.mmMMmm `7MM ,pW"Wq.`7MMpMMMb. ,pP"Ybd
MM MM MM `Mb MM ,M' Yb 6M' OO MM 8) MM MM MM ,M' Yb MM' "'8) MM MM MM 6W' `Wb MM MM 8I `"
MM. ,MP MM M8 MM 8M"""""" 8M MM ,pm9MM MM MM 8M"""""" MM ,pm9MM MM MM 8M M8 MM MM `YMMMa.
`Mb. ,dP' MM. ,M9 MM YM. , YM. , MM 8M MM MM MM YM. , MM 8M MM MM MM YA. ,A9 MM MM L. I8
`"bmmd"' P^YbmdP' MM `Mbmmd' YMbmd' `Mbmo `Moo9^Yo..JMML. `Mbmo`Mbmmd'.JMML. `Moo9^Yo.`Mbmo.JMML.`Ybmd9'.JMML JMML.M9mmmP'
QO MP
`bmP
%//%
# #
#
### ## # # ## # # ## ## ### #
# # # ## #### # # # # # ## # # # # #
# ## # # # # # # ## # # # # #
# ## # # ## # ## ## ### # #
#
%/
/% виджет удаления объекта %/
/%
$args[0] = объект для удаления
%/
<<widget "removeobj">>
<<disablelink $args[0] $args[0].Parent>>
<<set $args[0].Disabled = true>>
<<if $args[0].Parent and $args[0].Parent != "NULL">> /% если «родитель» есть, то удаляем объект из его «детей» %/
<<= "<<set $"+$args[0].Parent+".Children.splice($"+$args[0].Parent+".Children.indexOf($args[0].ID), 1)>>">>
<<= "<<set $"+$args[0].ID+".FormerParent = $"+$args[0].ID+".Parent>>">> /% записываем «текущего» родителя в «предыдущие» %/
<<set $args[0].Parent = "NULL">> /% обнуляем родителя в свойствах объекта %/
<</if>>
<<replace ".inventory">>
<<display "Inventory">>
<</replace>>
<</widget>>
/%
# #
#
# # ## # # ## ## ### #
#### # # # # # ## # # # # #
# # # # # # ## # # # # #
# # ## # ## ## ### # #
#
%/
/% виджет перемещения объекта %/
/%
$args[0] = объект для перемещения
$args[1] = объект, в который происходит перемещение
%/
<<widget "moveobj">>
<<disablelink $args[0] $args[0].Parent>>
<<enablelink $args[0] $args[1]>>
<<if $args[0].Parent and $args[0].Parent != "NULL">> /% если «родитель» есть, то удаляем объект из его «детей» %/
<<= "<<set $"+$args[0].Parent+".Children.splice($"+$args[0].Parent+".Children.indexOf($args[0].ID), 1)>>">>
<<= "<<set $"+$args[0].ID+".FormerParent = $"+$args[0].ID+".Parent>>">> /% записываем «текущего» родителя в «предыдущие» %/
<</if>>
<<= "<<set $"+$args[0].ID+".Parent = $args[1].ID>>">> /% меняем родителя в свойствах объекта %/
<<= "<<set $"+$args[0].Parent+".Children.push($args[0].ID)>>">> /% добавляем объект в список «детей» %/
<<replace ".inventory">>
<<display "Inventory">>
<</replace>>
<</widget>>
/%
# #
#
## ### ## ### ## ### #
# # # # # ## # # # # # # #
# # # # ## # # # # # # #
## ### ## # # ## ### # #
# #
%/
/% виджет открытия объекта %/
/%
$args[0] = объект для открытия
%/
<<widget "openobj">>
<<set $args[0].isOpen = true>>
<<for _i to 0; _i < $args[0].Children.length; _i++>>
<<= "<<set $"+$args[0].Children[_i]+".Disabled = false>>">>
<<= "<<enablelink $"+$args[0].Children[_i]+" $"+$args[0].ID+">>">>
<</for>>
<</widget>>
/%
## # #
# #
## # ## ### ## ## ### #
# # # # ## # ## # # # # #
# # # # ## ## # # # # #
## ### ## ### ## ## ### # #
#
%/
/% виджет закрытия объекта %/
/%
$args[0] = объект для закрытия
%/
<<widget "closeobj">>
<<set $args[0].isOpen = false>>
<<for _i to 0; _i < $args[0].Children.length; _i++>>
<<= "<<set $"+$args[0].Children[_i]+".Disabled = true>>">>
<<= "<<disablelink $"+$args[0].Children[_i]+" '"+$args[0].ID+"'>>">>
<</for>>
<</widget>>
/%
# # # ## ## # #
# # # # #
### ## ### ### ### # ## # ## ### # #
# # # ## # # # # # # ## # # # # ##
# # # ## # ## # # # ## # # # # # #
### ### ### # # ### ### ## ### ### # # # #
%/
/% виджет отключения ссылок объекта %/
/%
$args[0] = объект для отключения ссылок
$args[1] = имя родителя объекта
%/
<<widget "disablelink">>
/% отключаем ссылки с классами "link" и "[родитель-объект]" %/
<<script>>
var link = ".link."+variables().args[1]+"-"+variables().args[0].ID;
if ($(link)){
$(link).addClass("disabled");
}
<</script>>
<</widget>>
/%
# ## ## # #
# # # #
## ### ### ### # ## # ## ### # #
# ## # # # # # # # # ## # # # # ##
## # # # ## # # # ## # # # # # #
## # # # # ### ### ## ### ### # # # #
%/
/% виджет включения ссылок объекта %/
/%
$args[0] = объект для включения ссылок
$args[1] = родитель объекта
%/
<<widget "enablelink">>
/% включаем ссылки с классами "link" и "[родитель-объект]" %/
<<script>>
var link = ".link."+variables().args[1].ID+"-"+variables().args[0].ID;
if ($(link)){
$(link).removeClass("disabled");
}
<</script>>
<</widget>>
/%
db
;MM:
,V^MM. `7MMpdMAo.`7MMpdMAo. .gP"Ya ,6"Yb. `7Mb,od8 .gP"Ya `7MMpMMMb. ,p6"bo .gP"Ya
,M `MM MM `Wb MM `Wb ,M' Yb 8) MM MM' "',M' Yb MM MM 6M' OO ,M' Yb
AbmmmqMA MM M8 MM M8 8M"""""" ,pm9MM MM 8M"""""" MM MM 8M 8M""""""
A' VML MM ,AP MM ,AP YM. , 8M MM MM YM. , MM MM YM. , YM. ,
.AMA. .AMMA. MMbmmd' MMbmmd' `Mbmmd' `Moo9^Yo..JMML. `Mbmmd'.JMML JMML.YMbmd' `Mbmmd'
MM MM
.JMML. .JMML.
%/<<widget "DarkTheme">>
<<set $Theme = "DarkTheme">>
<<removeclass "body">>
<<addclass "body" "darktheme">>
<</widget>>
<<widget "LightTheme">>
<<set $Theme = "LightTheme">>
<<removeclass "body">>
<<addclass "body" "lighttheme">>
<</widget>>
/%
,, ,... ,...
`7MM"""Yb. db .d' "".d' "" mm
MM `Yb. dM` dM` MM
MM `Mb `7MM mMMmm mMMmm.gP"Ya `7Mb,od8 .gP"Ya `7MMpMMMb.mmMMmm
MM MM MM MM MM ,M' Yb MM' "',M' Yb MM MM MM
MM ,MP MM MM MM 8M"""""" MM 8M"""""" MM MM MM
MM ,dP' MM MM MM YM. , MM YM. , MM MM MM
.JMMmmmdP' .JMML..JMML..JMML.`Mbmmd'.JMML. `Mbmmd'.JMML JMML.`Mbmo
%//%
###
# #
# # ### ## ### ## # # ###
### # # # # # # # # # # # #
# # # # # # # # # # # #
# # ## # # ## ### # #
%/
<<widget "Pronoun">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set $PnNom = "я">>
<<set $PnGen = "меня">>
<<set $PnDat = "мне">>
<<set $PnAcc = "меня">>
<<set $PnIns = "мной">>
<<set $PnPre = "мне">>
<<set $PPnNom = "Я">>
<<set $PPnGen = "Меня">>
<<set $PPnDat = "Мне">>
<<set $PPnAcc = "Меня">>
<<set $PPnIns = "Мной">>
<<set $PPnPre = "Мне">>
<<case "P">>
<<set $PnNom = "мы">>
<<set $PnGen = "нас">>
<<set $PnDat = "нам">>
<<set $PnAcc = "нас">>
<<set $PnIns = "нами">>
<<set $PnPre = "нас">>
<<set $PPnNom = "Мы">>
<<set $PPnGen = "Нас">>
<<set $PPnDat = "Нам">>
<<set $PPnAcc = "Нас">>
<<set $PPnIns = "Нами">>
<<set $PPnPre = "Нас">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set $PnNom = "ты">>
<<set $PnGen = "тебя">>
<<set $PnDat = "тебе">>
<<set $PnAcc = "тебя">>
<<set $PnIns = "тобой">>
<<set $PnPre = "тебе">>
<<set $PPnNom = "Ты">>
<<set $PPnGen = "Тебя">>
<<set $PPnDat = "Тебе">>
<<set $PPnAcc = "Тебя">>
<<set $PPnIns = "Тобой">>
<<set $PPnPre = "Тебе">>
<<case "P">>
<<set $PnNom = "вы">>
<<set $PnGen = "вас">>
<<set $PnDat = "вам">>
<<set $PnAcc = "вас">>
<<set $PnIns = "вами">>
<<set $PnPre = "вас">>
<<set $PPnNom = "Вы">>
<<set $PPnGen = "Вас">>
<<set $PPnDat = "Вам">>
<<set $PPnAcc = "Вас">>
<<set $PPnIns = "Вами">>
<<set $PPnPre = "Вас">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M">>
<<set $PnNom = "он">>
<<set $PnGen = "его">>
<<set $PnDat = "ему">>
<<set $PnAcc = "его">>
<<set $PnIns = "им">>
<<set $PnPre = "нём">>
<<set $PPnNom = "Он">>
<<set $PPnGen = "Его">>
<<set $PPnDat = "Ему">>
<<set $PPnAcc = "Его">>
<<set $PPnIns = "Им">>
<<set $PPnPre = "Нём">>
<<case "F">>
<<set $PnNom = "она">>
<<set $PnGen = "её">>
<<set $PnDat = "ей">>
<<set $PnAcc = "её">>
<<set $PnIns = "ею">>
<<set $PnPre = "ней">>
<<set $PPnNom = "Она">>
<<set $PPnGen = "Её">>
<<set $PPnDat = "Ей">>
<<set $PPnAcc = "Её">>
<<set $PPnIns = "Ею">>
<<set $PPnPre = "Ней">>
<<case "N">>
<<set $PnNom = "оно">>
<<set $PnGen = "его">>
<<set $PnDat = "ему">>
<<set $PnAcc = "его">>
<<set $PnIns = "им">>
<<set $PnPre = "нём">>
<<set $PPnNom = "Оно">>
<<set $PPnGen = "Его">>
<<set $PPnDat = "Ему">>
<<set $PPnAcc = "Его">>
<<set $PPnIns = "Им">>
<<set $PPnPre = "Нём">>
<<case "P">>
<<set $PnNom = "они">>
<<set $PnGen = "их">>
<<set $PnDat = "им">>
<<set $PnAcc = "их">>
<<set $PnIns = "им">>
<<set $PnPre = "них">>
<<set $PPnNom = "Они">>
<<set $PPnGen = "Их">>
<<set $PPnDat = "Им">>
<<set $PPnAcc = "Их">>
<<set $PPnIns = "Им">>
<<set $PPnPre = "Них">>
<</switch>>
<</switch>>
<</widget>>
/%
# # ##
# # # #
# # # ### ### ##
# # # # # ## # ##
# # # # # ## ## ##
## ## # # ### ##
%/
<<widget "UCase">>
<<set _s = "">>
<<for _i to 0; _i lt $args[0].length; _i++>>
<<if /[a-zа-я]/i.test($args[0].charAt(_i))>>
<<set _u = $args[0].charAt(_i).toUpperCase() + $args[0].slice(_i+1)>>
<<break>>
<<else>>
<<set _s = _s+$args[0].charAt(_i)>>
<</if>>
<</for>>
<<= "<<set $"+$args[1]+" = _s+_u>>">>
<</widget>>
/%
,,
`7MMF' `7MF' *MM
`MA ,V MM
VM: ,V .gP"Ya `7Mb,od8 MM,dMMb. ,pP"Ybd
MM. M',M' Yb MM' "' MM `Mb 8I `"
`MM A' 8M"""""" MM MM M8 `YMMMa.
:MM; YM. , MM MM. ,M9 L. I8
VF `Mbmmd'.JMML. P^YbmdP' M9mmmP'
%//%
,, ,, ,, ,, ,,
.g8""8q. *MM db mm `7MMM. ,MMF' db `7MM mm db
.dP' `YM. MM MM MMMb dPMM MM MM
dM' `MM MM,dMMb.`7MM .gP"Ya ,p6"bo mmMMmm ,pP"Ybd M YM ,M MM ,6"Yb. `7MMpMMMb. `7MM `7MMpdMAo.`7MM `7MM MM ,6"Yb.mmMMmm `7MM ,pW"Wq.`7MMpMMMb.
MM MM MM `Mb MM ,M' Yb 6M' OO MM 8I `" M Mb M' MM 8) MM MM MM MM MM `Wb MM MM MM 8) MM MM MM 6W' `Wb MM MM
MM. ,MP MM M8 MM 8M"""""" 8M MM `YMMMa. M YM.P' MM ,pm9MM MM MM MM MM M8 MM MM MM ,pm9MM MM MM 8M M8 MM MM
`Mb. ,dP' MM. ,M9 MM YM. , YM. , MM L. I8 M `YM' MM 8M MM MM MM MM MM ,AP MM MM MM 8M MM MM MM YA. ,A9 MM MM
`"bmmd"' P^YbmdP' MM `Mbmmd' YMbmd' `MbmoM9mmmP' .JML. `' .JMML.`Moo9^Yo..JMML JMML..JMML. MMbmmd' `Mbod"YML..JMML.`Moo9^Yo.`Mbmo.JMML.`Ybmd9'.JMML JMML.
QO MP MM
`bmP .JMML.%/
/%
### #
# #
# ### # # ##
# # # ## # ##
# # ## # # ##
# # # # # ##
%/
/% «Взять» %/
/%
$args[0] = объект для взятия
($args[1] = глагол вместо «взять»)
%/
<<widget "Take">>
<<if $args[0].Parent != "player">>
<<if $args[1]>>
<<set $linktext = $args[1]+" "+$args[0].NameA>>
<<else>>
<<set $linktext = "Взять "+$args[0].NameA>>
<</if>>
<<if Story.has($args[0].Take)>>
<<set $objectActResult = tale.get($args[0].Take).processText()>>
<<else>>
<<switch $_time>>
<<case "past">>
<<switch $_sex>>
<<case "M">>
<<set _v = "взял">>
<<case "F">>
<<set _v = "взяла">>
<<case "N">>
<<set _v = "взяло">>
<<case "P">>
<<set _v = "взяли">>
<</switch>>
<<case "present">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "беру">>
<<case "P">>
<<set _v = "берём">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "берёшь">>
<<case "P">>
<<set _v = "берёте">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "берёт">>
<<case "P">>
<<set _v = "берут">>
<</switch>>
<</switch>>
<<case "future">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "возьму">>
<<case "P">>
<<set _v = "возьмём">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "возьмёшь">>
<<case "P">>
<<set _v = "возьмёте">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "возьмёт">>
<<case "P">>
<<set _v = "возьмут">>
<</switch>>
<</switch>>
<</switch>>
<<set $objectActResult = $PPnNom+" "+_v+" "+$args[0].NameA+".">>
<</if>>
<<= "<span class='link act "+$args[0].Take+"'><<link '"+$linktext+"'>><<moveobj $"+$args[0].ID+" $player>><<actrefresh $"+$args[0].ID+" '"+$linktext+"' '"+$objectActResult+"'>><</link>></span><br>">>
<</if>>
<</widget>>
/%
###
# #
# # ### ## ###
# # # # # # # #
# # # # # # #
### # ## ###
#
%/
/% «Бросить» %/
/%
$args[0] = объект для сброса
($args[1] = глагол вместо «бросить»)
%/
<<widget "Drop">>
<<if $args[0].Parent == "player">>
<<if $args[1]>>
<<set $linktext = $args[1]+" "+$args[0].NameA+" здесь">>
<<else>>
<<set $linktext = "Оставить "+$args[0].NameA+" здесь">>
<</if>>
<<if Story.has($args[0].Drop)>>
<<set $objectActResult = tale.get($args[0].Drop).processText()>>
<<else>>
<<switch $_time>>
<<case "past">>
<<switch $_sex>>
<<case "M">>
<<set _v = "бросил">>
<<case "F">>
<<set _v = "бросила">>
<<case "N">>
<<set _v = "бросило">>
<<case "P">>
<<set _v = "бросили">>
<</switch>>
<<case "present">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "бросаю">>
<<case "P">>
<<set _v = "бросаем">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "бросаешь">>
<<case "P">>
<<set _v = "бросаете">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "бросает">>
<<case "P">>
<<set _v = "бросают">>
<</switch>>
<</switch>>
<<case "future">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "брошу">>
<<case "P">>
<<set _v = "бросим">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "бросишь">>
<<case "P">>
<<set _v = "бросите">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "бросит">>
<<case "P">>
<<set _v = "бросят">>
<</switch>>
<</switch>>
<</switch>>
<<set $objectActResult = $PPnNom+" "+_v+" "+$args[0].NameA+".">>
<</if>>
<<= "<span class='link act "+$args[0].Drop+"'><<link '"+$linktext+"'>><<moveobj $"+$args[0].ID+" $loc>><<actrefresh $"+$args[0].ID+" '"+$linktext+"' '"+$objectActResult+"'>><</link>></span><br>">>
<</if>>
<</widget>>
/%
###
# #
# # ## # # ## # # ##
### # ## #### # # # # # ##
# # ## # # # # # # ##
# # ## # # ## # ##
%/
/% Глагол с удалением объекта %/
/%
$args[0] = объект для удаления
$args[1] = имя действия
$args[2] = имя параграфа с описанием действия
%/
<<widget "Remove">>
<<set $objectActResult = tale.get($args[2]).processText()>>
<<set $objectAct = '<<Remove $'+$args[0].ID+' "'+$args[1]+'" "'+$args[2]+'">>'>> /% действие для создания ссылки на повтор !внимание на обратную вложенность кавычек! %/
<<= "<span class='link act "+$args[2]+"'><<link '"+$args[1]+"'>><<removeobj $"+$args[0].ID+">><<actrefresh $"+$args[0].ID+" '"+$args[1]+"' '"+$objectActResult+"' '"+$objectAct+"'>><</link>></span><br>">>
<</widget>>
/%
##
# #
# # ### ## ###
# # # # # ## # #
# # # # ## # #
## ### ## # #
#
%/
/% «Открыть» %/
/%
$args[0] = объект для открытия
($args[1] = текст вместо «Открыть объект»)
%/
<<widget "Open">>
<<if !$args[0].isOpen>>
<<if $args[1]>>
<<set $linktext = $args[1]>>
<<else>>
<<set $linktext = "Открыть "+$args[0].NameA>>
<</if>>
<<if Story.has($args[0].Open)>>
<<set $objectActResult = tale.get($args[0].Open).processText()>>
<<else>>
<<switch $_time>>
<<case "past">>
<<switch $_sex>>
<<case "M">>
<<set _v = "открыл">>
<<case "F">>
<<set _v = "открыла">>
<<case "N">>
<<set _v = "открыло">>
<<case "P">>
<<set _v = "открыли">>
<</switch>>
<<case "present">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "открываю">>
<<case "P">>
<<set _v = "открываем">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "открываешь">>
<<case "P">>
<<set _v = "открываете">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "открывает">>
<<case "P">>
<<set _v = "открывают">>
<</switch>>
<</switch>>
<<case "future">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "открою">>
<<case "P">>
<<set _v = "откроем">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "откроешь">>
<<case "P">>
<<set _v = "откроете">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "откроет">>
<<case "P">>
<<set _v = "откроют">>
<</switch>>
<</switch>>
<</switch>>
<<set $objectActResult = $PPnNom+" "+_v+" "+$args[0].NameA+".">>
<</if>>
<<= "<span class='link act "+$args[0].Open+"'><<link '"+$linktext+"'>><<openobj $"+$args[0].ID+">><<actrefresh $"+$args[0].ID+" '"+$linktext+"' '"+$objectActResult+"'>><</link>></span><br>">>
<</if>>
<</widget>>
/%
## ##
# # #
# # ## ### ##
# # # # ## # ##
# # # # # ## ##
## ### ## ### ##
%/
/% «Закрыть» %/
/%
$args[0] = объект для закрытия
($args[1] = текст вместо «Закрыть объект»)
%/
<<widget "Close">>
<<if $args[0].isOpen>>
<<if $args[1]>>
<<set $linktext = $args[1]>>
<<else>>
<<set $linktext = "Закрыть "+$args[0].NameA>>
<</if>>
<<if Story.has($args[0].Close)>>
<<set $objectActResult = tale.get($args[0].Close).processText()>>
<<else>>
<<switch $_time>>
<<case "past">>
<<switch $_sex>>
<<case "M">>
<<set _v = "закрыл">>
<<case "F">>
<<set _v = "закрыла">>
<<case "N">>
<<set _v = "закрыло">>
<<case "P">>
<<set _v = "закрыли">>
<</switch>>
<<case "present">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "закрываю">>
<<case "P">>
<<set _v = "закрываем">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "закрываешь">>
<<case "P">>
<<set _v = "закрываете">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "закрывает">>
<<case "P">>
<<set _v = "закрывают">>
<</switch>>
<</switch>>
<<case "future">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "закрою">>
<<case "P">>
<<set _v = "закроем">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "закроешь">>
<<case "P">>
<<set _v = "закроете">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "закроет">>
<<case "P">>
<<set _v = "закроют">>
<</switch>>
<</switch>>
<</switch>>
<<set $objectActResult = $PPnNom+" "+_v+" "+$args[0].NameA+".">>
<</if>>
<<= "<span class='link act "+$args[0].Close+"'><<link '"+$linktext+"'>><<closeobj $"+$args[0].ID+">><<actrefresh $"+$args[0].ID+" '"+$linktext+"' '"+$objectActResult+"'>><</link>></span><br>">>
<</if>>
<</widget>>
/%
# # ## #
## # # # #
## # ## # # ## ###
# ## # # #### # #
# ## # # # # # #
# # ## # # ## ##
%/
/% Глагол без последствий — выводит только описание %/
/%
$args[0] = объект с этим действием
$args[1] = имя действия
$args[2] = имя параграфа с описанием действия
%/
<<widget "NoAct">>
<<set $objectActResult = tale.get($args[2]).processText()>>
<<= "<span class='link act "+$args[2]+"'><<link '"+$args[1]+"'>><<actrefresh $"+$args[0].ID+" '"+$args[1]+"' '"+$objectActResult+"'>><</link>></span><br>">>
<</widget>>
/%
# # ## # ##
## # # # # # #
## # ## # # ## ### # # ### ## ##
# ## # # #### # # # # # # # # ##
# ## # # # # # # # # # # # ##
# # ## # # ## ## ## # # ## ##
%/
/% Глагол без последствий — выводит только описание и только один раз %/
/%
$args[0] = объект с этим действием
$args[1] = имя действия
$args[2] = имя параграфа с описанием действия
%/
<<widget "NoActOnce">>
<<= "<<if $"+$args[2]+"_seen>><<set $NAO = $"+$args[2]+"_seen>><</if>>">>
<<if !$NAO>>
<<set $objectActResult = tale.get($args[2]).processText()>>
<<= "<span class='link act "+$args[2]+"'><<link '"+$args[1]+"'>><<set $"+$args[2]+"_seen = true>><<actrefresh $"+$args[0].ID+" '"+$args[1]+"' '"+$objectActResult+"'>><</link>></span><br>">>
<</if>>
<<set $NAO = false>>
<</widget>>
/%
## #
# # #
# # ## ###
#### # #
# # # #
# # ## ##
%/
/% Глагол с некоторым кодом %/
/%
$args[0] = объект с этим действием
$args[1] = имя действия
$args[2] = имя параграфа с описанием действия
%/
<<widget "Act">>
<<set $objectActResult = tale.get($args[2]).processText()>>
<<if Story.has($args[2]+"Act")>>
<<set $objectAct = $args[2]+"Act">>
<<else>>
<<set $objectAct = "NULL">>
<</if>>
<<if Story.has($args[2]+"AfterAct")>> /% !! highly experimental stuff !! %/
<<set $objectAfterAct = $args[2]+"AfterAct">>
<<else>>
<<set $objectAfterAct = "NULL">>
<</if>>
<<= "<span class='link act "+$args[2]+"'><<link '"+$args[1]+"'>><<display '"+$objectAct+"'>><<actrefresh $"+$args[0].ID+" '"+$args[1]+"' '"+$objectActResult+"'>><<display '"+$objectAfterAct+"'>><</link>></span><br>">>
<</widget>>
/%
## # ##
# # # # #
# # ## ### # # ### ## ##
#### # # # # # # # # ##
# # # # # # # # # ##
# # ## ## ## # # ## ##
%/
/% Одноразовый глагол с некоторым кодом %/
/%
$args[0] = объект с этим действием
$args[1] = имя действия
$args[2] = имя параграфа с описанием действия
%/
<<widget "ActOnce">>
<<= "<<if $"+$args[2]+"_seen>><<set $AO = $"+$args[2]+"_seen>><</if>>">>
<<if !$AO>>
<<set $objectActResult = tale.get($args[2]).processText()>>
<<if Story.has($args[2]+"Act")>>
<<set $objectAct = $args[2]+"Act">>
<<else>>
<<set $objectAct = "NULL">>
<</if>>
<<if Story.has($args[2]+"AfterAct")>> /% !! highly experimental stuff !! %/
<<set $objectAfterAct = $args[2]+"AfterAct">>
<<else>>
<<set $objectAfterAct = "NULL">>
<</if>>
<<= "<span class='link act "+$args[2]+"'><<link '"+$args[1]+"'>><<display '"+$objectAct+"'>><<set $"+$args[2]+"_seen = true>><<actrefresh $"+$args[0].ID+" '"+$args[1]+"' '"+$objectActResult+"'>><<display '"+$objectAfterAct+"'>><</link>></span><br>">>
<</if>>
<<set $AO = false>>
<</widget>>
/%
,, ,,
MMP""MM""YMM `7MM `7MM db
P' MM `7 MM MM
MM ,6"Yb. MM MM ,MP'`7MM `7MMpMMMb. .P"Ybmmm
MM 8) MM MM MM ;Y MM MM MM :MI I8
MM ,pm9MM MM MM;Mm MM MM MM WmmmP"
MM 8M MM MM MM `Mb. MM MM MM 8M
.JMML.`Moo9^Yo..JMML..JMML. YA..JMML..JMML JMML.YMMMMMb
6' dP
Ybmmmd'%/
/%
## # # ### ## #
# # # # # # #
# ### ### ### ### # ### # # #
# # # # # # # # # # # ##
# # # # ## # # # # ## # # #
## ## # # # ## # # # ### # #
%/
/% Запуск режима разговора с персонажем %/
/%
$args[0] = субъект действия
$args[1] = имя действия
%/
<<widget "StartTalk">>
<<set $talkResult = Story.get($args[0].ID+"StartTalk").processText()>>
<<= "<span class='link act "+$args[0].ID+"StartTalk'><<link '"+$args[1]+"'>><<set $MODE='talking'>><<actrefresh $"+$args[0].ID+" '"+$args[1]+"' '"+$talkResult+"'>><<set $ACTLOG=false>><</link>></span><br>">>
<</widget>>
/%
### # # # #
# # #
# ## ### ## ## # ## ### ###
# # # # # # # # # ## #
# # # # # # # # # ## #
# ## ### ### ## #### ### ### ##
#
%/
/% Список тем для разговора %/
<<widget "TopicsList">>
<<set $Topic = "NULL">>
<<set $CurrentTopic = false>>
<<for _t to 0; _t < $player.Topics.length; _t++>>
<<= "<<set _a = $player."+$player.Topics[_t]+">>">>
<<if _a.includes(1)>>
<<capture _t, _a>>
<p style="margin:0;">
<<link `$player.Topics[_t]+"…"`>>
<<replace ".object_actions">>
<<set $CurrentTopic = $player.Topics[_t]>>
<<set $PhrasesList = _a>>
<<Topic $CurrentTopic $PhrasesList>>
<</replace>>
<</link>>
</p>
<</capture>>
<</if>>
<</for>>
<br>
<<EndTalk>>
<</widget>>
/%
### #
#
# ## ### ## ##
# # # # # # #
# # # # # # #
# ## ### ### ##
#
%/
/% Выбор темы %/
/%
$args[0] = выбранная тема для разговора
$args[1] = массив фраз в этой теме
%/
<<widget "Topic">>
<<for _d to $args[1].length; _d >= 0; _d-->>
<<if $args[1][_d] == 2>>
<<break>>
<<elseif $args[1][_d] == 1>>
<<set _tp = $args[0]+_d>>
<<Phrase _tp>>
<<break>>
<</if>>
<</for>>
<br>
<<= "<span class='link act "+$args[0].ID+"RefreshTalk'><<link 'Сменить тему разговора'>><<set $CurrentTopic = false>><<actrefresh $"+$focus.ID+" '' ''>><</link>></span>">>
<br>
<<EndTalk>>
<</widget>>
/%
### #
# # #
# # ### ### ### ### ##
### # # # # # # ## # ##
# # # # # ## ## ##
# # # # # # ### ##
%/
/% Выбор фразы %/
/%
$args[0] = код фразы
%/
<<widget "Phrase">>
<<set $Topic = $args[0]>>
<<display "DohoKungTalk">>
<<set $talkResult = $question+"<br>"+$answer>>
<<= "<span class='link act "+$focus.ID+"Phrase"+$args[0]+"'><<link '"+$question+"'>><<set $MODE='talking'>><<= $clockwork>><<actrefresh $"+$focus.ID+" '"+$args[0]+"' '"+$talkResult+"'>><<set $ACTLOG=false>><</link>></span><br>">>
<</widget>>
/%
#### # ### ## #
# # # # #
### ### ### # ### # # #
# # # # # # # # # ##
# # # # # # # ## # # #
#### # # ### # # # ### # #
%/
/% Завершение режима разговора с персонажем %/
<<widget "EndTalk">>
<<= "<span class='link act "+$focus+"EndTalk'><<link 'Закончить разговор'>><<set $CurrentTopic = false>><<set $Topic = false>><<set $MODE='NULL'>><<actrefresh $focus '' ''>><<set $ACTLOG=true>><</link>></span><br>">>
<</widget>>
/%
,,
`7MMF' mm mm db
MM MM MM
MM `7MMpMMMb.mmMMmm .gP"Ya `7Mb,od8 ,6"Yb. ,p6"bo mmMMmm `7MM ,pW"Wq.`7MMpMMMb.
MM MM MM MM ,M' Yb MM' "'8) MM 6M' OO MM MM 6W' `Wb MM MM
MM MM MM MM 8M"""""" MM ,pm9MM 8M MM MM 8M M8 MM MM
MM MM MM MM YM. , MM 8M MM YM. , MM MM YA. ,A9 MM MM
.JMML..JMML JMML.`Mbmo`Mbmmd'.JMML. `Moo9^Yo.YMbmd' `Mbmo.JMML.`Ybmd9'.JMML JMML.
%/
/%
### # ## #
# # # # #
# ### ### ## ### # # ## ###
# # # # # ## # # #### # #
# # # # ## # # # # #
### # # ## ## # # # ## ##
%/
/% Запуск режима взаимодействия с другим объектом %/
/%
$args[0] = субъект действия
$args[1] = имя действия
$args[2] = имя отмены действия
$args[3] = имя режима
%/
<<widget "InterAct">>
<<= "<span class='link act "+$args[0].ID+"InterAct'><<link '"+$args[1]+"'>><<set $MODE='"+$args[3]+"'>><<actrefresh $"+$args[0].ID+" '"+$args[2]+"' ' ' '"+$args[3]+"'>><</link>></span><br>">>
<</widget>>
/%
### # ## # ### ## #
# # # # # # # # #
# ### ### ## ### # # ## ### # # ## ### # # # ###
# # # # # ## # # #### # # ### # ## ## # # # #
# # # # ## # # # # # # # ## ## # # # #
### # # ## ## # # # ## ## # # ## ### ### ### ##
%/
/% Вывод результата взаимодействия %/
/%
$args[0] = субъект действия
$args[1] = имя действия
$args[2] = имя параграфа с описанием действия | стандартное описание действия
$args[3] = объект действия
%/
<<widget "InterActResult">>
<<if Story.has($args[2]+"Act")>>
<<set $objectAct = $args[2]+"Act">>
<<else>>
<<set $objectAct = "NULL">>
<</if>>
<<if Story.has($args[2]+"AfterAct")>> /% !! highly experimental stuff !! %/
<<set $objectAfterAct = $args[2]+"AfterAct">>
<<else>>
<<set $objectAfterAct = "NULL">>
<</if>>
<<if Story.has($args[2])>>
<<set $objectActResult = Story.get($args[2]).processText()>>
<<else>>
<<set $objectActResult = $args[2]>>
<</if>>
<<= "<<set $MODE='NULL'>><<display '"+$objectAct+"'>><<actrefresh $"+$args[0].ID+" '"+$args[1]+"' '"+$objectActResult+"'>><<display '"+$objectAfterAct+"'>>">>
<</widget>>
/%
### # ## # ## ##
# # # # # # # #
# ### ### ## ### # # ## ### # ### ### ## ## #
# # # # # ## # # #### # # # # # # # # # ## #
# # # # ## # # # # # # # # ## # # # ## #
### # # ## ## # # # ## ## ## # # # # ## ## ###
%/
/% Прерывание режима взаимодействия %/
/%
$args[0] = субъект действия
$args[1] = имя действия
%/
<<widget "InterActCancel">>
<<= "<span class='link act "+$args[0].ID+"InterActCancel'><<link '"+$args[1]+"'>><<set $MODE='NULL'>><<set $ACTLOG=true>><<actrefresh $"+$args[0].ID+" '"+$args[1]+"'>><</link>></span><br>">>
<</widget>>
/%
## # # ### ## #
# # # # # # # #
# ### ## ## ### # # ## ### # # # ###
# # # # # # # # ### # ## ## # # # #
# # # # # # # # # # # ## ## # # # #
## # # ## ## ## # # ## ### ### ### ##
%/
/%
$args[0] = оружие
$args[1] = цель
%/
<<widget "ShootResult">>
<<if $args[1].NameA.charAt(0) == "в" || $args[1].NameA.charAt(0) == "В">>
<<set _$prep = "во ">>
<<else>>
<<set _$prep = "в ">>
<</if>>
<<if Story.has($args[1].ID+"Shoot")>> /% проверка, есть ли параграф с описанием результат выстрела, если нет, то выводится описание-заглушка %/
<<set _$shootResult = $args[1].ID+"Shoot">>
<<else>>
<<set _$shootResult = "[выстрел "+_$prep+$args[1].NameA+"]">>
<<set $isShootSuccess = true>>
<</if>>
<<if $isShootSuccess>> /% проверка, был ли произведён выстрел. Флаг должен быть включён в параграфе [цель]Shoot. Для объектов с описанием-заглушкой флаг включён по-умолчанию %/
<<if $args[0].Ammo > 0>>
<<set $args[0].Ammo-->>
<<else>>
<<set _$shootResult = "Вместо выстрела раздаётся глухое клацанье — кончились патроны.">>
<</if>>
<<set $isShootSuccess = false>>
<</if>>
<<= '<<InterActResult $'+$args[0].ID+' "Выстрелить '+_$prep+$args[1].NameA+'" "'+_$shootResult+'">>'>>
<<set $args[1].Shooted = true>>
<</widget>>
/%
# # # ### ## #
# # # # # # #
#### ### ## # # # # ## ### # # # ###
# # # # # ## ### # ## ## # # # #
# # # ## # # # # # ## ## # # # #
# # # # ## # # # # ## ### ### ### ##
%/
/%
$args[0] = инструмент
$args[1] = цель
%/
<<widget "HackResult">>
<<if Story.has($args[1].ID+"Hack")>> /% проверка, есть ли параграф с описанием результат рубки, если нет, то выводится отрицательное описание-заглушка %/
<<set _$hackResult = $args[1].ID+"Hack">>
<<else>>
<<set _$hackResult = either ( "Рубка "+$args[1].NameG+" "+$args[0].NameI+" ничего не даст.",
"Он заносит "+$args[0].NameA+", но тут же, качая головой, опускает.",
"Он качает головой: «Нет смысла рубить "+$args[1].NameA+"»."
)>>
<</if>>
<<= '<<InterActResult $'+$args[0].ID+' "Ударить '+$args[0].NameI+' '+$args[1].NameA+'" "'+_$hackResult+'">>'>>
<<set $args[1].Hacked = true>>
<</widget>>
/%
#### # # # # ### ## #
# # # # # # #
### # # ### ## ### ### # # ## ### ### # # ## ### # # # ###
# ## # # # # # # # # # ## # # ### # ## ## # # # #
# ## # # # # ## # # # ## # # # # ## ## # # # #
#### # # ## ### # # # ### ### ### # # # # ## ### ### ### ##
###
%/
/%
$args[0] = инструмент
$args[1] = цель
%/
<<widget "ExtinguishResult">>
<<if Story.has($args[1].ID+"Extinguish")>> /% проверка, есть ли параграф с описанием результат рубки, если нет, то выводится отрицательное описание-заглушка %/
<<set _$extinguishResult = $args[1].ID+"Extinguish">>
<<else>>
/%<<set _$extinguishResult = either ( "Рубка "+$args[1].NameG+" "+$args[0].NameI+" ничего не даст.",
"Он заносит "+$args[0].NameA+", но тут же, качая головой, опускает.",
"Он качает головой: «Нет смысла рубить "+$args[1].NameA+"»."
)>>%/
<<set _$extinguishResult = "К счастью, "+$args[1].Name+" сейчас не в огне.">>
<</if>>
<<= '<<InterActResult $'+$args[0].ID+' "Тушить '+$args[1].NameA+' '+$args[0].NameI+'" "'+_$extinguishResult+'">>'>>
<<set $args[1].Extinguished = true>>
<</widget>>
/%
### # ### ## #
# # # # # #
# ### ### ## ### ### # # ## ### # # # ###
# # # ## # ## # # # ### # ## ## # # # #
# # # ## ## # # # # ## ## # # # #
### # # ### ## # ## # # ## ### ### ### ##
%/
/%
$args[0] = то, что вставляется
$args[1] = то, во что вставляется
%/
<<widget "InsertResult">>
<<if Story.has($args[1].ID+"Insert")>> /% проверка, есть ли параграф с описанием результат рубки, если нет, то выводится отрицательное описание-заглушка %/
<<set _$insertResult = $args[1].ID+"Insert">>
<<else>>
<<set _$insertResult = "Нет смысла вставлять "+$args[0].NameA+" в "+$args[1].NameA+".">>
<</if>>
<<= '<<InterActResult $'+$args[0].ID+' "Вставить '+$args[0].NameA+' в '+$args[1].NameA+'" "'+_$insertResult+'">>'>>
<</widget>>
/%
,,
`7MMF' mm db db mm
MM MM ;MM: MM
MM ,pW"Wq. ,p6"bo ,6"Yb.mmMMmm `7MM ,pW"Wq.`7MMpMMMb. ,pP"Ybd ,V^MM. ,p6"bo mmMMmm ,pP"Ybd
MM 6W' `Wb 6M' OO 8) MM MM MM 6W' `Wb MM MM 8I `" ,M `MM 6M' OO MM 8I `"
MM , 8M M8 8M ,pm9MM MM MM 8M M8 MM MM `YMMMa. AbmmmqMA 8M MM `YMMMa.
MM ,M YA. ,A9 YM. , 8M MM MM MM YA. ,A9 MM MM L. I8 A' VML YM. , MM L. I8
.JMMmmmmMMM `Ybmd9' YMbmd' `Moo9^Yo.`Mbmo.JMML.`Ybmd9'.JMML JMML.M9mmmP' .AMA. .AMMA.YMbmd' `MbmoM9mmmP'
%/
/%
# # ## # #
## # # # # #
## # ## # # ## ### # ## ##
# ## # # #### # # # # # #
# ## # # # # # # # # # #
# # ## # # ## ## #### ## ##
%/
/% Локальный глагол без последствий — выводит только описание %/
/%
$args[0] = имя действия
$args[1] = имя параграфа с описанием действия
%/
<<widget "NoActLoc">>
<<set _locActResult = tale.get($args[1]).processText()>>
<<= "<span class='link actloc "+$args[1]+"'><<link '"+$args[0]+"'>><<actlocrefresh '"+$args[0]+"' '"+_locActResult+"'>><</link>></span><br>">>
<</widget>>
/%
# # ## # # ##
## # # # # # # #
## # ## # # ## ### # ## ## # # ### ## ##
# ## # # #### # # # # # # # # # # # # ##
# ## # # # # # # # # # # # # # # # ##
# # ## # # ## ## #### ## ## ## # # ## ##
%/
/% Одноразовый локальный глагол без последствий — выводит только описание %/
/%
$args[0] = имя действия
$args[1] = имя параграфа с описанием действия
%/
<<widget "NoActLocOnce">>
<<= "<<if $"+$args[1]+"_seen>><<set $NALO = $"+$args[1]+"_seen>><</if>>">>
<<if !$NALO>>
<<set _locActResult = tale.get($args[1]).processText()>>
<<= "<span class='link actloc "+$args[1]+"'><<link '"+$args[0]+"'>><<set $"+$args[1]+"_seen = true>><<actlocrefresh '"+$args[0]+"' '"+_locActResult+"'>><</link>></span><br>">>
<</if>>
<<set $NALO = false>>
<</widget>>
/%
## # #
# # # #
# # ## ### # ## ##
#### # # # # # #
# # # # # # # #
# # ## ## #### ## ##
%/
/% Локальный глагол с некоторым кодом %/
/%
$args[0] = имя действия
$args[1] = имя параграфа с описанием действия
%/
<<widget "ActLoc">>
<<set _locActResult = tale.get($args[1]).processText()>>
<<if Story.has($args[1]+"Act")>>
<<set _locAct = $args[1]+"Act">>
<<else>>
<<set _locAct = "NULL">>
<</if>>
<<if Story.has($args[1]+"AfterAct")>> /% !! highly experimental stuff !! %/
<<set _locAfterAct = $args[1]+"AfterAct">>
<<else>>
<<set _locAfterAct = "NULL">>
<</if>>
<<= "<span class='link actloc "+$args[1]+"'><<link '"+$args[0]+"'>><<display '"+_locAct+"'>><<actlocrefresh '"+$args[0]+"' '"+_locActResult+"'>><<display '"+_locAfterAct+"'>><</link>></span><br>">>
<</widget>>
/%
## # # ##
# # # # # #
# # ## ### # ## ## # # ### ## ##
#### # # # # # # # # # # # # ##
# # # # # # # # # # # # # ##
# # ## ## #### ## ## ## # # ## ##
%/
/% Одноразовый локальный глагол с некоторым кодом %/
/%
$args[0] = имя действия
$args[1] = имя параграфа с описанием действия
%/
<<widget "ActLocOnce">>
<<= "<<if $"+$args[1]+"_seen>><<set $ALO = $"+$args[1]+"_seen>><</if>>">>
<<if !$ALO>>
<<set _locActResult = tale.get($args[1]).processText()>>
<<if Story.has($args[1]+"Act")>>
<<set _locAct = $args[1]+"Act">>
<<else>>
<<set _locAct = "NULL">>
<</if>>
<<if Story.has($args[1]+"AfterAct")>> /% !! highly experimental stuff !! %/
<<set _locAfterAct = $args[1]+"AfterAct">>
<<else>>
<<set _locAfterAct = "NULL">>
<</if>>
<<= "<span class='link actloc "+$args[1]+"'><<link '"+$args[0]+"'>><<display '"+_locAct+"'>><<set $"+$args[1]+"_seen = true>><<actlocrefresh '"+$args[0]+"' '"+_locActResult+"'>><<display '"+_locAfterAct+"'>><</link>></span><br>">>
<</if>>
<<set $ALO = false>>
<</widget>>
/%
##
# #
# ##
# ## # #
# # # #
### ##
%/
/% Переход м/у локациями %/
/%
$args[0] = имя действия
$args[1] = локация, в которую осушествляется переход
%/
<<widget "Go">>
<<if Story.has($loc.ID+"GoAct")>>
<<set _locAct = $loc.ID+"GoAct">>
<<else>>
<<set _locAct = "NULL">>
<</if>>
<<if Story.has($loc.ID+"GoAfterAct")>> /% !! highly experimental stuff !! %/
<<set _locAfterAct = $loc.ID+"GoAfterAct">>
<<else>>
<<set _locAfterAct = "NULL">>
<</if>>
<<= "<span class='link actloc Go"+$args[1].ID+"'><<link '"+$args[0]+"'>><<display '"+_locAct+"'>><<set $prevloc = $"+$loc.ID+">><<set $loc = $"+$args[1].ID+">><<moveobj $player $"+$args[1].ID+">><<set $loc.isJustEntered = true>><<examlocrefresh>><<set $loc.isJustEntered = false>><<display '"+_locAfterAct+"'>><</link>></span><br>">>
<</widget>>
/%
# # ##
## # # #
## # ## # ##
# ## # # # ## # #
# ## # # # # # #
# # ## ### ##
%/
/% Запрет выхода из локации %/
/%
$args[0] = имя действия
(опционально) $args[1] = имя параграфа с описанием действия
%/
<<widget "NoGo">>
<<if $args.length == 1>>
<<set $locActResult = $loc.NoGo>>
<<elseif $args.length == 2>>
<<set $locActResult = $args[1]>>
<</if>>
<<if Story.has($locActResult)>>
<<set $locActResult = tale.get($locActResult).processText()>>
<<else>>
<<switch $_time>>
<<case "past">>
<<switch $_sex>>
<<case "M">>
<<set _v = "мог">>
<<case "F">>
<<set _v = "могла">>
<<case "N">>
<<set _v = "могло">>
<<case "P">>
<<set _v = "могли">>
<</switch>>
<<case "present">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "могу">>
<<case "P">>
<<set _v = "можем">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "можешь">>
<<case "P">>
<<set _v = "можете">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "может">>
<<case "P">>
<<set _v = "могут">>
<</switch>>
<</switch>>
<<case "future">>
<<switch $_face>>
<<case 1>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "смогу">>
<<case "P">>
<<set _v = "сможем">>
<</switch>>
<<case 2>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "сможешь">>
<<case "P">>
<<set _v = "сможете">>
<</switch>>
<<case 3>>
<<switch $_sex>>
<<case "M" "F" "N">>
<<set _v = "сможет">>
<<case "P">>
<<set _v = "смогут">>
<</switch>>
<</switch>>
<</switch>>
<<set $locActResult = $PPnNom+" не "+_v+" уйти.">>
<</if>>
<<= "<span class='link actloc NoGo'><<link '"+$args[0]+"'>><<actlocrefresh '"+$args[0]+"' '"+$locActResult+"'>><</link>></span><br>">>
<</widget>>
/%
#### #
# #
### # # ### # # # ## ##
# ## # # #### # # # #
# ## # ## # # # # # #
#### # # # # # # #### ## ##
%/
/% Осмотр локации %/
/%
$args[0] = объект локации
%/
<<widget "ExamLoc">>
<<= "<<set $loc = $"+$loc.ID+">>">> /% обновляем ссылку «$loc» на реальную локацию %/
<<= "<span class='link actloc Exam"+$loc.ID+"'><<link $"+$loc.ID+".Name>><<unset $focus>><<unset $report>><<examlocrefresh>><</link>></span>">>
<</widget>>
/%
,, ,,
`7MM"""Yb. db `7MM
MM `Yb. MM
MM `Mb `7MM ,pP"Ybd `7MMpdMAo. MM ,6"Yb.`7M' `MF'
MM MM MM 8I `" MM `Wb MM 8) MM VA ,V
MM ,MP MM `YMMMa. MM M8 MM ,pm9MM VA ,V
MM ,dP' MM L. I8 MM ,AP MM 8M MM VVV
.JMMmmmdP' .JMML.M9mmmP' MMbmmd'.JMML.`Moo9^Yo. ,V
MM ,V
.JMML. OOb"
%/
/%
## ### # ## #
# # # # # #
# ## ### ## ## ### ### # # ## # ###
# # # # # ## # ## # # # # # # # # # #
# # # # ## ## # # # # # # # # # #
## ## # ## ## # # ### ### ### ### ###
%/<<unset $focus>><<= "<<set $"+$loc.ID+".Visited++>>">><div class="location_name"><p style="position: fixed; display: inline-flex; justify-content: center; left: 0; top: 0; padding: 1em 0; margin: 0; width: 100%; background-color: inherit; z-index: 1;">''<<ExamLoc>>''</p><p style="height: 2.5em;margin: 0;"></p></div>
/% возможный css для того, чтобы название локации всегда было видно:
text-align: center;
position: fixed;
width: 40%;
left: 0;
top: 0;
padding: 1em 0;
margin: 0 30%;
background-color: #111;
%/
<p class="location_enter"><<display $loc.Enter>></p>
<p class="location_description"><p class="animated fadeInDown"><<display $loc.Desc>></p></p>
<p class="location_content"><<LocationContent>></p>
<p class="report"><p class="animated fadeInDown Events"><<display $loc.Events>></p></p> /% Параграф для отображения лога %/
/%<p class="focus"></p>%/
<p class="object_actions" style="text-align:center;margin-bottom: 0px;"></p><p class="location_actions" style="text-align:center;margin-top: 0px;"><<display $loc.Acts>></p>
<p class="inventory" style="line-height:1;"><<display "Inventory">></p>
<<if $Theme == "LightTheme">>
<<LightTheme>>
<<else>>
<<DarkTheme>>
<</if>>
<<if $MODE == "CUTSCENE">>
<<addclass ".link.prop, .link.actloc, .link.obj" "faded">> /% гасим все ссылки для катсцены %/
<</if>>
<p class="link obj prop actloc actobj Cutscene"></p> /% фиктивный элемент для отлова ошибок %/
/%
### #
# #
# ### # # ## ### ### ## ### # #
# # # # # # ## # # # # # # # # #
# # # # # ## # # # # # # # #
### # # # ## # # ## ## # #
#
%/<<set _div0 = 0>>
<<set _div1 = 0>>
<<set _div2 = 0>>
<<for _k0 to 0; _k0 < $player.Children.length; _k0++>>
<<= "<<set _child0 = $"+$player.Children[_k0]+">>">>
<<if !_div0>> /% если выводится первый/единственный предмет, отделить инвентарь чертой, вывести заголовок %/
<<set _div0 = 1>>
<hr>
С собой:
<<else>> /% если в инвентаре уже есть предмет — отделить его и последующие предметы чертой %/
|
<</if>>
<<object _child0.Name _child0>>
<<if _child0.Children.length > 0>> /% если у предмета есть свои «дети», вывести их подобным же образом в скобках %/
(
<<for _k1 to 0; _k1 < _child0.Children.length; _k1++>>
<<= "<<set _child1 = $"+_child0.Children[_k1]+">>">>
<<if !_div1>>
<<set _div1 = 1>>
<<else>>
,
<</if>>
<<object _child1.Name _child1>>
<<if _child1.Children.length > 0>>
(
<<for _k2 to 0; _k2 < _child1.Children.length; _k2++>>
<<= "<<set _child2 = $"+_child1.Children[_k2]+">>">>
<<if !_div2>>
<<set _div2 = 1>>
<<else>>
,
<</if>>
<<object _child2.Name _child2>>
<</for>>
)
<</if>>
<</for>>
)
<</if>>
<</for>>/%
,,
`7MMF' db `7MM
MM MM
MM `7MM `7MMpMMMb. MM ,MP',pP"Ybd
MM MM MM MM MM ;Y 8I `"
MM , MM MM MM MM;Mm `YMMMa.
MM ,M MM MM MM MM `Mb. L. I8
.JMMmmmmMMM .JMML..JMML JMML..JMML. YA.M9mmmP'
%/
/%
# # #
# #
## ### # ## ## ###
# # # # # # ## # #
# # # # # ## # #
## ### # # ## ## ##
#
%/
/% виджет осмотра объекта %/
/%
$args[0] = текст ссылки
$args[1] = объект
$args[2] = дополнительные классы для ссылки
%/
<<widget "object">><<="<span class='link obj "+$args[1].Parent+"-"+$args[1].ID+($args[1].Disabled ? " disabled" : "")+($args[2] ? $args[2] : "")+"'><<obj '"+$args[0]+"' $"+$args[1].ID+">></span>">><</widget>>
/% обрачиваем ссылку в span и задаём ему классы "link", "obj", "[родитель-объект]", плюс, если объект отключён, добавляем класс "disabled" для тушения ссылки %/
<<widget "obj">><<link $args[0]>>
<<set $focus = $args[1]>> /% обновляем фокус %/
<<if $focus.Trigger && $MODE == "NULL">>
<<set $MODE = $focus.Trigger>>
<<set $args[1].Trigger = "NULL">>
<</if>>
<<if $MODE == "NULL">>
<<append ".report">> /% выводим данные объекта в фокусе %/
<p class="animated fadeInDown">
<<UCase $focus.Name "focusName">>
/%<<if Story.get($focus.Parent).tags.contains("obj") and $focus.Parent != "player">> /% если «родитель» объекта тоже объект и не игрок, выводим и его в командную строку %/
/%<<= "<<set $focusParent = $"+$focus.Parent+">>">>
<<UCase $focusParent.Name "focusParentName">>
•
<<if !$focusParent.Disabled>> /% если «родитель» объекта не отключён — выводим его имя ссылкой %/
/% <<object $focusParentName $focusParent>>
<<else>>
<<= $focusParentName>>
<</if>>
:
<<else>>%/
•
/%<</if>>
<<if !$focus.Disabled>>
<<object $focusName $focus>>
<<else>>%/
<<= $focusName>> /% выводим имя объекта %/
/%<</if>>%/
<br>
<<display $focus.Desc>> /% выводим описание объекта %/
<<set $focus.Examined++>>
</p>
<</append>>
<<if $EXAMISACT>> /% если осмотр — полноценный ход, показываем события в локации %/
<<append ".report">>
<<if tale.get($loc.Events).processText().length gt 0 && $args[1]>>
<p class="animated fadeInDown Events">
<<display $loc.Events>>
</p>
<</if>>
<</append>>
<</if>>
<<script>>
$(window).scrollTop($(".report p:last-child").offset().top); /% скроллимся к последней записи репорта %/
<</script>>
<<replace ".object_actions">>
<<if Story.has($focus.Acts)>>
<p class="animated fadeInDown">
<<display $focus.Acts>> /% выводим действия объекта %/
</p>
<</if>>
<</replace>>
<<replace ".location_actions">>
<<if Story.has($loc.Acts)>>
<p class="animated fadeInDown">
<<display $loc.Acts>> /% выводим действия локации%/
</p>
<</if>>
<</replace>>
<<replace ".inventory">>
<<display "Inventory">>
<</replace>>
<<if $EXAMISACT && $MODE == "CUTSCENE">> /% если осмотр — полноценный ход и в нём включается катсцена, то трём все действия и инвентарь %/
/%<<replace ".object_actions">>
<</replace>>
<<replace ".location_actions">>
<</replace>>%/
<<replace ".inventory">>
<</replace>>
<<addclass ".link.obj, .link.prop, .link.actloc, .link.actobj" "faded">> /% гасим все ссылки для катсцены %/
<<removeclass "[class*='Cutscene']" "faded">> /% восстанавливаем ссылки «Далее» для катсцены %/
<</if>>
<<elseif $MODE == "CUTSCENE">>
<<append ".report">> /% выводим данные объекта в фокусе %/
<p class="animated fadeInDown">
<<UCase $focus.Name "focusName">>
<<if Story.get($focus.Parent).tags.contains("obj") and $focus.Parent != "player">> /% если «родитель» объекта тоже объект и не игрок, выводим и его в командную строку %/
<<= "<<set $focusParent = $"+$focus.Parent+">>">>
<<UCase $focusParent.Name "focusParentName">>
•
<<if !$focusParent.Disabled>> /% если «родитель» объекта не отключён — выводим его имя ссылкой %/
<<object $focusParentName $focusParent " faded">>
<<else>>
<<= $focusParentName>>
<</if>>
:
<<else>>
•
<</if>>
<<if !$focus.Disabled>>
<<object $focusName $focus " faded">>
<<else>>
<<= $focusName>> /% выводим имя объекта %/
<</if>>
<br>
<<display $focus.Desc>> /% выводим описание объекта %/
<<set $focus.Examined++>>
</p>
<</append>>
<<script>>
$(window).scrollTop($(".report p:last-child").offset().top); /% скроллимся к последней записи репорта %/
<</script>>
<<replace ".object_actions">>
<<if Story.has($focus.Acts)>>
<p class="animated fadeInDown">
<<display $focus.Acts>> /% выводим действия объекта %/
</p>
<</if>>
<</replace>>
<<replace ".location_actions">>
<</replace>>
<<replace ".inventory">>
<</replace>>
<<addclass ".link.prop, .link.actloc, .link.obj" "faded">> /% гасим все ссылки для катсцены %/
<<elseif $MODE == "pistol_shooting">>
<<ShootResult $pistol $focus>>
<<elseif $MODE == "axe_hacking">>
<<HackResult $axe $focus>>
<<elseif $MODE == "extinguishing">>
<<ExtinguishResult $fireExt $focus>>
<<elseif $MODE == "inserting">>
<<InsertResult $fireExt2 $focus>>
<</if>>
<</link>><</widget>>
/%
### ### ## ###
# # # # # # # #
# # # # # # #
### # ## ###
# #
%/
/%
$args[0] = текст ссылки
$args[1] = объект декорации
%/
/% виджет осмотра декораций %/
<<widget "prop">><<="<span class='link prop "+$args[1].ID+($args[1].Disabled ? " disabled" : "")+"'><<prp '"+$args[0]+"' $"+$args[1].ID+">></span>">><</widget>> /% обрачиваем ссылку в span и задаём ему классы "link", "prop", "[локация]", плюс, если декорация отключена, добавляем класс "disabled" для тушения ссылки %/
<<widget "prp">><<link $args[0]>>
<<set $focus = $args[1]>>
<<append ".report">>
<p class="animated fadeInDown">
<<UCase $focus.Name "focusName">>
• <<= $focusName>>
<br>
<<display $focus.Desc>> /% выводим описание декорации %/
<<set $focus.Examined++>>
</p>
<</append>>
<<if $EXAMISACT>>
<<append ".report">>
<<if tale.get($loc.Events).processText().length gt 0 && $args[1]>>
<p class="animated fadeInDown Events">
<<display $loc.Events>>
</p>
<</if>>
<</append>>
<</if>>
<<script>>
$(window).scrollTop($(".report p:last-child").offset().top); /% скроллимся к последней записи репорта %/
<</script>>
<<replace ".object_actions">><</replace>>
<<replace ".location_actions">>
<<if Story.has($loc.Acts)>>
<p class="animated fadeInDown">
<<display $loc.Acts>> /% выводим действия локации%/
</p>
<</if>>
<</replace>>
<<replace ".inventory">>
<<display "Inventory">>
<</replace>>
<<if $EXAMISACT && $MODE == "CUTSCENE">> /% если осмотр — полноценный ход и в нём включается катсцена, то трём все действия и инвентарь %/
<<replace ".inventory">>
<</replace>>
<<addclass ".link.obj, .link.prop, .link.actloc, .link.actobj" "faded">> /% гасим все ссылки для катсцены %/
<<removeclass "[class*='Cutscene']" "faded">> /% восстанавливаем ссылки «Далее» для катсцены %/
<</if>>
<</link>><</widget>>
/%
,, ,, ,, ,,
`7MM"""Yb. db `7MM `7MM mm mm db
MM `Yb. MM MM MM MM
MM `Mb `7MM ,pP"Ybd `7MMpdMAo. MM ,6"Yb.`7M' `MF' ,6"Yb. MM mmMMmm .gP"Ya `7Mb,od8 ,6"Yb.mmMMmm `7MM ,pW"Wq.`7MMpMMMb. ,pP"Ybd
MM MM MM 8I `" MM `Wb MM 8) MM VA ,V 8) MM MM MM ,M' Yb MM' "'8) MM MM MM 6W' `Wb MM MM 8I `"
MM ,MP MM `YMMMa. MM M8 MM ,pm9MM VA ,V ,pm9MM MM MM 8M"""""" MM ,pm9MM MM MM 8M M8 MM MM `YMMMa.
MM ,dP' MM L. I8 MM ,AP MM 8M MM VVV 8M MM MM MM YM. , MM 8M MM MM MM YA. ,A9 MM MM L. I8
.JMMmmmdP' .JMML.M9mmmP' MMbmmd'.JMML.`Moo9^Yo. ,V `Moo9^Yo..JMML. `Mbmo`Mbmmd'.JMML. `Moo9^Yo.`Mbmo.JMML.`Ybmd9'.JMML JMML.M9mmmP'
MM ,V
.JMML. OOb"
%/
/%
# # #
# # # #
### ## ### ### ## # ### ## ### ###
# # # # # # # ## ### # # # ## ## # #
# ## # # # ## # # ## ## # #
# # ## ## # ## # # ## ### # #
%/
/% виджет обновления экрана по действию %/
/%
$args[0] = объект в фокусе
$args[1] = имя действия
$args[2] = описание действия
(опционально) $args[3] = действие для создания повторной ссылки
%/
<<widget "actrefresh">>
<<if $MODE == "NULL">>
<<set $focus = $args[0]>> /% обновляем фокус %/
/%<<replace ".focus">><</replace>>%/
<<append ".report">>
/%<<if $args[1] || $args[3]>>%/
<p class="animated fadeInDown">
<<if $ACTLOG>> /% проверка, включено ли отражение навзания действия в логе (см. Engine—Initialise) %/
<<if $args[3] && !$focus.Disabled>>
•• <<= $args[3]>> /% выводим ссылку для повторения действия %/
<<else>>
•• <<= $args[1]>> /% выводим имя действия %/
<</if>>
<br>
<<else>>
/%<<set $ACTLOG = true>>%/
<</if>>
<<= $args[2]>> /% выводим описание действия %/
</p>
/%<</if>>%/
<</append>>
<<append ".report">>
<<if tale.get($loc.Events).processText().length gt 0 && $args[1]>>
<p class="animated fadeInDown Events">
<<display $loc.Events>>
</p>
<</if>>
<</append>>
<<script>>
$(window).scrollTop($(".report p:last-child").offset().top); /% скроллимся к последней записи репорта %/
<</script>>
<<replace ".object_actions">>
<<if !$focus.Disabled and Story.has($focus.Acts)>> /% если объект не отключён и у него есть действия — выводим список действий %/
<p class="animated fadeInDown">
<<display $focus.Acts>>
</p>
<</if>>
<</replace>>
<<replace ".location_actions">>
<<if Story.has($loc.Acts)>>
<p class="animated fadeInDown">
<<display $loc.Acts>> /% выводим действия локации%/
</p>
<</if>>
<</replace>>
<<replace ".inventory">>
<<display "Inventory">>
<</replace>>
/%<<unset $quickcommand>>%/
<<removeclass "*" "faded">>
<<removeclass "*" "highlighted">>
<<if $MODE == "CUTSCENE">> /% если в эвенте локации включается катсцена, то трём все действия и инвентарь %/
<<replace ".inventory">>
<</replace>>
<<addclass ".link.obj, .link.prop, .link.actloc, .link.actobj" "faded">> /% гасим все ссылки для катсцены %/
<<removeclass "[class*='Cutscene']" "faded">> /% восстанавливаем ссылки «Далее» для катсцены %/
<</if>>
<<elseif $MODE == "CUTSCENE">>
<<set $focus = $args[0]>> /% обновляем фокус %/
<<append ".report">>
<p class="animated fadeInDown">
<<if $ACTLOG>> /% проверка, включено ли отражение навзания действия в логе (см. Engine—Initialise) %/
•• <<= $args[1]>> /% выводим имя действия %/
<br>
<<else>>
/%<<set $ACTLOG = true>>%/
<</if>>
<<= $args[2]>> /% выводим описание действия %/
</p>
<</append>>
<<script>>
$(window).scrollTop($(".report p:last-child").offset().top); /% скроллимся к последней записи репорта %/
<</script>>
<<replace ".object_actions">>
<<if !$focus.Disabled and Story.has($focus.Acts)>> /% если объект не отключён и у него есть действия — выводим список действий %/
<p class="animated fadeInDown">
<<display $focus.Acts>>
</p>
<</if>>
<</replace>>
<<replace ".location_actions">>
<</replace>>
<<replace ".inventory">>
<</replace>>
<<addclass ".link.prop, .link.actloc, .link.obj" "faded">> /% гасим все ссылки для катсцены %/
<<removeclass "[class*='Cutscene']" "faded">> /% восстанавливаем ссылки «Далее» для катсцены %/
<<elseif $MODE == "talking">>
<<append ".report">>
/%<<if $args[1] || $args[3]>>%/
<p class="animated fadeInDown">
<<if $ACTLOG>> /% проверка, включено ли отражение навзания действия в логе (см. Engine—Initialise) %/
•• <<= $args[1]>> /% выводим имя действия %/
<br>
<</if>>
<<= $args[2]>> /% выводим описание действия %/
</p>
/%<</if>>%/
<</append>>
<<script>>
$(window).scrollTop($(".report p:last-child").offset().top);
<</script>>
<<replace ".object_actions">>
<p class="animated fadeInDown">
<<if !$CurrentTopic>>
<<TopicsList>>
<<else>>
<<Topic $CurrentTopic $PhrasesList>>
<</if>>
</p>
<</replace>>
<<replace ".location_actions">>
<</replace>>
<<addclass ".link.prop, .link.obj, .link.actloc" "faded">>
<<else>>
/%<<replace ".focus">><</replace>>%/
<<replace ".object_actions">>
<p class="animated fadeInDown">
<<InterActCancel $args[0] $args[1]>>
</p>
<</replace>>
<<replace ".location_actions">>
<</replace>>
<<addclass ".link.prop, .link.actloc" "faded">>
<<addclass ".link.obj" "highlighted">>
<</if>>
<</widget>>
/%
# ## # #
# # # # #
### ## ### # ## ## ### ## # ### ## ### ###
# # # # # # # # # # # ## ### # # # ## ## # #
# ## # # # # # # # ## # # ## ## # #
# # ## ## ### ## ## # ## # # ## ### # #
%/
/% виджет обновления экрана по локальному действию %/
/%
$args[0] = имя действия
$args[1] = описание действия
%/
<<widget "actlocrefresh">>
/%<<replace ".location_enter">>
<</replace>>
<<replace ".location_description">>
<<display $loc.Desc>>
<</replace>>%/
<<if $MODE == "NULL">>
<<append ".report">>
<p class="animated fadeInDown">
<<if $ACTLOG>> /% проверка, включено ли отражение навзания действия в логе (см. Engine—Initialise) %/
•• <<= $args[0]>> /% выводим имя действия %/
<br>
<<else>>
/%<<set $ACTLOG = true>>%/
<</if>>
<<= $args[1]>> /% выводим описание действия %/
</p>
<</append>>
<<append ".report">>
<<if tale.get($loc.Events).processText().length gt 0>>
<p class="animated fadeInDown Events">
<<display $loc.Events>>
</p>
<</if>>
<</append>>
/%<<replace ".focus">><</replace>>%/
<<script>>
$(window).scrollTop($(".report p:last-child").offset().top); /% скроллимся к последней записи репорта %/
<</script>>
<<replace ".object_actions">><</replace>>
<<replace ".location_actions">>
<<if Story.has($loc.Acts)>>
<p class="animated fadeInDown">
<<display $loc.Acts>> /% выводим действия локации%/
</p>
<</if>>
<</replace>>
<<replace ".inventory">>
<<display "Inventory">>
<</replace>>
<<removeclass "*" "faded">>
<<if $MODE == "CUTSCENE">> /% если в эвенте локации включается катсцена, то трём все действия и инвентарь %/
<<replace ".inventory">>
<</replace>>
<<addclass ".link.obj, .link.prop, .link.actloc, .link.actobj" "faded">> /% гасим все ссылки для катсцены %/
<<removeclass "[class*='Cutscene']" "faded">> /% восстанавливаем ссылки «Далее» для катсцены %/
<</if>>
<<elseif $MODE == "CUTSCENE">>
<<append ".report">>
<p class="animated fadeInDown">
<<if $ACTLOG>> /% проверка, включено ли отражение навзания действия в логе (см. Engine—Initialise) %/
•• <<= $args[0]>> /% выводим имя действия %/
<br>
<<else>>
/%<<set $ACTLOG = true>>%/
<</if>>
<<= $args[1]>> /% выводим описание действия %/
</p>
<</append>>
<<script>>
$(window).scrollTop($(".report p:last-child").offset().top); /% скроллимся к последней записи репорта %/
<</script>>
<<replace ".object_actions">><</replace>>
<<replace ".location_actions">>
<<if Story.has($loc.Acts)>>
<p class="animated fadeInDown">
<<display $loc.Acts>> /% выводим действия локации%/
</p>
<</if>>
<</replace>>
<<replace ".inventory">><</replace>>
<<addclass ".link.prop, .link.actloc, .link.obj" "faded">> /% гасим все ссылки для катсцены %/
<<removeclass "[class*='Cutscene']" "faded">> /% восстанавливаем ссылки «Далее» для катсцены %/
<</if>>
/%<<unset $quickcommand>>%/
<</widget>>
/%
## # #
# # # #
## # # ### # # # ## ## ### ## # ### ## ### ###
# ## ## # # #### # # # # # # # ## ### # # # ## ## # #
## ## # ## # # # # # # # ## # # ## ## # #
## # # # # # # ### ## ## # ## # # ## ### # #
%/
/% виджет обновления экрана по осмотру локации %/
<<widget "examlocrefresh">>
<<replace ".location_name">><p style="position: fixed; display: inline-flex; justify-content: center; left: 0; top: 0; padding: 1em 0; margin: 0; width: 100%; background-color: inherit; z-index: 1;">''<<ExamLoc>>''</p><p style="height: 2.5em;margin: 0;"></p><</replace>>
<<replace ".location_enter">>
<<if $loc.isJustEntered>>
<p class="animated fadeInDown">
<<display $loc.Enter>>
</p>
<</if>>
<</replace>>
<<replace ".location_description">>
<p class="animated fadeInDown">
<<display $loc.Desc>>
</p>
<</replace>>
<<replace ".location_content">>
<p class="animated fadeInDown">
<<LocationContent>>
</p>
<</replace>>
<<replace ".report">>
<<if tale.get($loc.Events).processText().length gt 0>>
<p class="animated fadeInDown Events">
<<display $loc.Events>>
</p>
<</if>>
<</replace>>
/%<<replace ".focus">><</replace>>%/
<<replace ".object_actions">><</replace>>
<<replace ".location_actions">>
<<if Story.has($loc.Acts)>>
<p class="animated fadeInDown">
<<display $loc.Acts>> /% выводим действия локации%/
</p>
<</if>>
<</replace>>
<<replace ".inventory">>
<<display "Inventory">>
<</replace>>
/%<<unset $quickcommand>>%/
<<if $MODE == "CUTSCENE">>
<<addclass ".link.prop, .link.actloc, .link.obj" "faded">> /% гасим все ссылки для катсцены %/
<<removeclass "[class*='Cutscene']" "faded">> /% …и восстанавливаем ссылки «Далее» для катсцены %/
<</if>>
<</widget>>
/%
# # # ## # #
# # # # # #
# ## ## ### ### ## ## ### # ## ### ### ## ### ###
# # # # # # # # # # # # # # # # # # # ## # # #
# # # # # ## # # # # # # # # # # # # # ## # # #
#### ## ## # # ## ### ## # # ## ## # # ## ## # # ##
%/
/% виджет для печатания описаний объктов «по месту» (если оно у них есть) %/
<<widget "LocationContent">>
<<for _i to 0; _i < $loc.Children.length; _i++>>
<<set _t = $loc.Children[_i]>>
<<set _p = _t+"Place">>
<<if Story.has(_p)>>
/%<<if _i > 0>>
<br><br>
<</if>>%/
<p>
<<display _p>>
</p>
<</if>>
<</for>>
<</widget>>