åã®èšäºã¯ããã¬ã€ã€ãŒãããã¹ããèªã¿ãåçãèŠãŠãããããã®å±éã«åœ±é¿ãäžããããšãã§ãããšããäºå®ã§çµãããŸããã Braslavskyã®æ¬ã²ãŒã ã移æ€ããããChoice of Gamesã®ç²Ÿç¥ã§CYOAãæžããããããªããããã§ååã§ãããã ããããããã²ãŒã·ã§ã³ã«é¢ããã²ãŒã ã§ã¯ãå°ãªããšãããã²ãŒã·ã§ã³èªäœã®ã·ã³ãã«ãªã€ã³ã¿ãŒãã§ã€ã¹ãå¿ èŠã§ãã Sunless Seaã®ãããªæ¬æ Œçãªã·ãã¥ã¬ãŒã¿ãŒãæ§ç¯ããã«ã¯ãRen'Pyã§ãå¯èœã§ãããåŽåéçŽçã§ãããäžè¬ã«ç¡æå³ã§ãã ããã«ãããªã€ãŒãããã¹ã§ç¬èªã®ãµã³ã¬ã¹æµ·ãäœããããªãã®ã§ããã¹ããŒã¹ã¬ã³ãžã£ãŒãºãã®ã°ããŒãã«ãããã®ãããªãã®ã«å¶éããŸããåå°ç¹ããããã€ãã®é£æ¥ããå°ç¹ã«ç§»åã§ããŸãã ãã®ãããªãã®ïŒ
ãã£ã¹ãã¬ã€ãç»é¢ãã¬ã€ã€ãŒ
ã€ã³ã¿ãŒãã§ã€ã¹èªäœã«ã€ããŠã¯ããã¿ã³ïŒåãã€ã³ãã«1ã€ïŒãšèæ¯ç»åã衚瀺ããã ãã§ãã ããã«ã¯Displayableã¿ã€ãã®Imagemapã§ååã§ãã åºæ¬çã«ãHTMLã®å¯Ÿå¿ãããã®ãšããã»ã©éãã¯ãããŸãããããã¯ãããããç¬èªã®ã¢ã¯ã·ã§ã³ãæã€ã¢ã¯ãã£ããŸãŒã³ãå®çŸ©ãããŠããå³ã§ãã ãã ãã裞ã®Displayableã§äœæ¥ããã®ã¯äžäŸ¿ã§ãããã¢ãŒããã¯ãã£ã®èŠ³ç¹ããèŠããšãã§ãã ãããã£ãŠãã³ãŒããå®è¡ããåã«ãRen'Pyã衚瀺ããèŠçŽ ã®éå±€ãç解ããããšã¯äŸ¡å€ããããŸãã
æäžäœã¬ãã«ã¯Displayablesã§ããã€ãŸããç¹å®ã®ã²ãŒã ã®éçºè ãçµã¿èŸŒã¿ãŸãã¯äœæãããŠã£ãžã§ããã§ãã ãããã¯ãããããããã€ãã®åºæ¬çãªæ©èœãå®è¡ããŸããç»åã®è¡šç€ºãããã¹ãã®è¡šç€ºãå ¥åã®æäŸãªã©ã§ãã Displayableã¯éåžžãããæœè±¡çãªå¯Ÿè©±ãæäŸããç»é¢ã«ã°ã«ãŒãåãããŸã ãããšãã°ãããã¹ãåºåãšã²ãŒã å ã¡ãã¥ãŒã¯ãå®éã®ããã¹ããèæ¯ããã¬ãŒã ãã¡ãã¥ãŒãã¿ã³ãå«ãnvlç»é¢ã«ãã£ãŠå®è¡ãããŸãã åæã«ã奜ããªã ãç»é¢ã衚瀺ã§ããŸããããšãã°ã1ã€ã«ã¯ããã¹ãããããä»ã®ãã¿ã³ã«ã¯é³æ¥œã®é³éãå¶åŸ¡ãã3ã€ç®ã®ç»é¢ã«ã¯ãã®äžã«éªãé£ã³ãŸãã å¿ èŠã«å¿ããŠãããã²ãŒã ã§åã ã®ç»é¢ã衚瀺ãŸãã¯åé€ããããã¡ãã¥ãŒãã²ãŒã ã«å¿ èŠãªä»ã®ãã¹ãŠãä¿åãããã§ããŸãã ãããŠæåŸã«ã ã¬ã€ã€ãŒããããŸã ã ã¬ã€ã€ãŒãçŽæ¥æäœããå¿ èŠã¯ãããŸããããã¬ã€ã€ãŒã®ååšãç¥ãå¿ èŠããããŸãã ããšãã°ãå£çŽã¯ç»é¢ã·ã¹ãã ãšã¯é¢ä¿ããªãããã¹ã¿ãŒã¬ã€ã€ãŒã§ãã®äžã«è¡šç€ºãããŸãã
ãããã£ãŠãæ è¡ç»é¢ã®èª¬æã¯æ¬¡ã®ãšããã§ãã
screen map_screen(): tag map modal True zorder 2 imagemap: auto 'images/1129map_%s.png' # Main cities hotspot monet.hotspot action Travel(monet) hotspot tartari.hotspot action Travel(tartari) # ⊠# More of the same boilerplate # ⊠add 'images/1024ship.png': at shiptransform(old_coords, coords) anchor (0.5, 1.0) id 'ship' transform shiptransform(old_coords, coords): pos old_coords linear 0.5 pos coords
map_screenïŒïŒç»é¢ãæåã«å®£èšãããŸãã ã¿ã°ã¯ãªãã·ã§ã³ã§ãã ã移åã«é¢é£ãããã¹ãŠã®ç»é¢ãåé€ããããªã©ã®ã³ãã³ãã®ç»é¢ãã°ã«ãŒãåããããšãã§ããŸãã Zorderã¯ç»é¢ã®ãé«ããã§ãããããã«ãããã©ã®èŠçŽ ãäºãã«ãããŸãã«ãªããã決å®ãããŸãã zorder = 2ãèšå®ããnvlç»é¢ã«ã¯ããã©ã«ãã®zorder = 1ãèšå®ãããŠãããããæ è¡äžããã¬ãŒã€ãŒã«ã¯ããã¹ãä»ãã®ãŠã£ã³ããŠã¯è¡šç€ºãããŸããã ããããæãéèŠãªããšã¯ããã®ç»é¢ãã¢ãŒãã«ã§ãããšããããšã§ããã€ãŸããç»é¢ã®äžã®èŠçŽ ã¯å ¥åã€ãã³ããåãåããŸããã nvlç»é¢ã¯ãããã®å€èŠ³ã§ãããã¯ãããŠãããããã²ãŒã ã®ç¶æ ãèªåã§è¿œè·¡ããå¿ èŠã¯ãªããããããã¯ãªãã¯ããŠãããã¹ããã¹ã¯ããŒã«ããªãããã«ããå¿ èŠããããŸãã
ã€ã¡ãŒãžãããèªäœã¯ãèªåã¿ã°ãšã¢ã¯ãã£ããŸãŒã³ã®ãªã¹ããšãã2ã€ã®äž»èŠãªèŠçŽ ã§æ§æãããŠããŸãã Autoã«ã¯ãããã¯ã°ã©ãŠã³ããšããŠäœ¿çšãããäžé£ã®ãã¡ã€ã«ãžã®ãªã³ã¯ãå«ãŸããŠããŸãã ããã¯ã»ããã§ãããåäžã®ç»åã§ã¯ãããŸããããã¹ãŠã®ãã¿ã³ãéã¢ã¯ãã£ããšããŠæç»ããããã¡ã€ã«ãšã¯å¥ã«ããã¹ãŠãæŒããããªã©ã®ãã¡ã€ã«ãåå¥ã«ååšããŸãã ãããŠãRen'Pyã¯ãã§ã«åãã¡ã€ã«ããç®çã®ãã©ã°ã¡ã³ããéžæããç»é¢äžã®ç»åãã³ã³ãã€ã«ããŸãã ãããŠæåŸã«ãã¢ã¯ãã£ããŸãŒã³ïŒãããã¹ãããïŒã ãããã¯ã4ã€ã®æŽæ°ïŒåº§æšãšãµã€ãºïŒã®ã¿ãã«ãšã¢ã¯ã·ã§ã³ã®ãªããžã§ã¯ãã«ãã£ãŠèšè¿°ãããŸãã ã¿ãã«ãããŒãã³ãŒãããã®ã§ã¯ãªãããªããžã§ã¯ãã®å±æ§ã䜿çšããŸãã ç»é¢ã®èª¬æã§ã¯ãå€ã®ä»£ããã«å€æ°ãŸãã¯å±æ§ããã€ã§ãæ¿å ¥ã§ããŸãã ã¢ã¯ã·ã§ã³ãªããžã§ã¯ãã¯ããã¿ã³ãæŒããããšãã«äœãèµ·ããããèšè¿°ãããã¿ã³ããã®æç¹ã§ã¢ã¯ãã£ãã«ãããã©ãããå¶åŸ¡ããŸãã Ren'Pyã¯ãã¹ã¯ãªããã®åãæ¿ããã²ãŒã ã®ä¿åãªã©ã®æ¥åžžçãªã¿ã¹ã¯ã®ããã«ãããªãã®æ°ã®çµã¿èŸŒã¿ã¢ã¯ã·ã§ã³ãæäŸããŸãããç¬èªã®ã¢ã¯ã·ã§ã³ãå®è¡ããããšãã§ããŸãã æåŸã«ãè¹ã®æç»ãšå€æãæåŸã«è¿œå ãããŸããããã¯ãç»é¢ã«è¡šç€ºãããã ãã§ãªãããã€ã³ãAãããã€ã³ãBã«ç§»åããŸããå€æã¯ãå¥ã®ATLïŒã¢ãã¡ãŒã·ã§ã³ãšå€æèšèªïŒã§èšè¿°ãããŸãã
1ã€ã®èœãšãç©Žãç»é¢ã«é¢é£ä»ããããŠããŸããç»é¢ã³ãŒãã¯ã衚瀺ãããçŽåã«å®è¡ãããã®ã§ã¯ãªããäºåã«å®è¡ãããŸãã ããã¯ããšã³ãžã³ãå¿ èŠãšããåæ°ãšå¿ èŠãªåæ°ã§çºçããããããã®ã³ãŒãã§ã¢ã¯ã»ã¹ããããã¹ãŠã®ãã®ã¯ãã²ãŒã ã®éå§åã«åæåããå¿ èŠããããä»ã®éèŠãªå€æ°ã®ç¶æ ã«ã¯åœ±é¿ããŸããã
ãã©ã³ã
åã®èšäºã§ãRen'Pyã§ã€ã³ã¿ãŒãã§ãŒã¹ãäœæãã2ã€ã®æ¹æ³ã瀺ãããšãçŽæããŸããã æåã«èŠãã®ã¯ãéåžžã«åçŽã§ããã決ããŠæ®éçãªãã®ã§ã¯ãããŸããã ããšãã°ãç»é¢äžã®èšèªã§ããŠã¹ã䜿çšããŠãªããžã§ã¯ãããã©ãã°ããæ¹æ³ã説æããè¡çªãåŠçããæ¹æ³ã«ã€ããŠã¯ãŸã ç解ããŠããŸããã§ããã ãŸãã¯ãç»é¢äžã®èŠçŽ ã®æ°ãã²ãŒã äžã«æ±ºå®ãããå Žåã®ç»é¢ã®ã¬ã€ã¢ãŠãæ¹æ³ã ãããããDisplayableã¯å®å šãªãŠã£ãžã§ããã§ããä»ã®Displayableãå«ããããå ¥åã€ãã³ãããã£ããããããå¿ èŠã«å¿ããŠå€æŽãããã§ããŸãã ãããã£ãŠãå¥ã®ã¢ããªã±ãŒã·ã§ã³ã®å Žåãšã»ãŒåãæ¹æ³ã§ãããã²ãŒã å šäœã1ã€ã®Displayableã§èšè¿°ãããããžã§ã¯ãã«æ¿å ¥ã§ããŸãã
ããã²ãŒã ã«ãŒãããããŸãã äž»äººå ¬ã®æœåšçã«æçšãªè²¡ç£ãšç¥èã¯ãã¹ãŠã匷ããç¥èãé°è¬ããéã®4ã€ã®ã¹ãŒãã§1ãã10ã®é¡é¢ãæã€ã«ãŒãã®åœ¢ã§æ瀺ãããŸãã 匷ãã¯ã人ãæ¯ãåžãå Žæã«ã€ããŠã®è²Žéãªç¥èã§ããã8人ã®é°è¬ã¯å¯èŒžæ¥è ã®éã§ã®Officeã®ãšãŒãžã§ã³ãã®ä¿¡é Œã§ãããªã¹ãã§ãã è³briã䜿çšããåçŽãªã²ãŒã ã¯ããã¬ã€ã€ãŒãåã«åé¡ã«å¯ŸåŠãããã©ãããããã³åã£ããŸãã¯è² ããã¹ãŒãã決å®ããŸãã ãã®çµæãçŽäºã¯æ倧8ã€ã®çµæãããããå¯èœæ§ããããŸããåã¹ãŒãã§ã®åå©ãšæåã¯ãååãšããŠãç°ãªãçµæã«ã€ãªããå¯èœæ§ããããŸãã
ã«ãŒãã²ãŒã ãšã¯ãã«ãŒãããã®äžã«è¡šç€ºãããããšãæå³ããŸãã å°ããªå°å³ã衚瀺ããDisplayableã®ã³ãŒãã¯æ¬¡ã®ããã«ãªããŸãã
class CardSmallDisplayable(renpy.Displayable): """ Regular card displayable """ suit_bg = {u'': 'images/MoneySmall{0}Card.jpg', u'': 'images/KnowledgeSmall{0}Card.jpg', u'': 'images/IntrigueSmall{0}Card.jpg', u'': 'images/ForceSmall{0}Card.jpg'} def __init__(self, card, **kwargs): super(CardSmallDisplayable, self).__init__(xysize=(100, 140), xfill=False, yfill=False, **kwargs) self.bg = Image(self.suit_bg[card.suit].format((card.spendable and 'Spendable' or 'Permanent'))) self.text = Text(u'{0}'.format(card.number), color = '#6A3819', font='Hangyaboly.ttf') self.xpos = 0 self.ypos = 0 self.xsize = 100 self.ysize = 140 self.x_offset = 0 self.y_offset = 0 self.transform = Transform(child=self) def render(self, width, height, st, at): """ Return 100*140 render for a card """ bg_render = renpy.render(self.bg, self.xsize-4, self.ysize-4, st, at) text_render = renpy.render(self.text, width, height, st, at) render = renpy.Render(width, height, st, at) render.blit(bg_render, (2, 2)) render.blit(text_render, (15-int(text_render.width/2), 3)) render.blit(text_render, (88-int(text_render.width/2), 117)) return render def visit(self): return[self.bg, self.text]
ããã¯ãæ¬è³ªçã«æãç°¡åãªDisplayableã§ãã ããã¯ãã¹ãŒãã«å¿ããŠéžæãããèæ¯ç»åãšãé¡é¢ã®ããããã¹ãã®2ã€ã®èŠçŽ ã§æ§æãããŠããŸãã Displayableãæ©èœããã«ã¯ãã³ã³ã¹ãã©ã¯ã¿ãŒãé€ãäž¡æ¹ã®ã¡ãœãããå¿ èŠã§ããself.renderã¯ãã¯ã¹ãã£ãè¿ããself.visitã¯-
ããã«å«ãŸãããã¹ãŠã®Displayableã®ãªã¹ãã 圌女ã¯å°ããªå°å³ãæããŸãã ãããç»é¢ã«è¡šç€ºããããããã®ã«ãŒãã®ããã€ãã次ã«ç€ºããŸãã
ãã§ã«æªãã¯ãããŸããããã«ãŒãèªäœã¯ç»é¢äžã«ãã衚瀺ã§ããã誰ããããã«çœ®ããå Žåã®ã¿ã§ãã å®éã«ããã²ãŒã ããã¬ã€ã§ããããã«ããã«ã¯ãå ¥åãåŠçããã²ãŒã ããžãã¯ãèšç®ã§ããå€éšDisplayableãè¿œå ããå¿ èŠããããŸãã ããã¹ããã£ãŒã«ããšèæ¯ããããã®äžéšã§ããã®ãšåãæ¹æ³ã§ãããããšä»ã®ã€ã³ã¿ãŒãã§ã€ã¹èŠçŽ ãå«ãŸããŸãã ãã®Displayableã¯ãå ¥åãšããŠPyGameã€ãã³ããåãåãself.eventïŒïŒã¡ãœããã®ååšãç°ãªããŸãã PYGAME.EVENTãžã®ãªã³ã¯æ¬¡ã®ãããªãã®ïŒå®å šãªã³ãŒãã¯ãTableã¯ã©ã¹ã®githubã§å©çšå¯èœã§ãïŒïŒ
def event(self, ev, x, y, st): if ev.type == pygame.MOUSEBUTTONDOWN and ev.button == 1: # ⊠# Process click at x, y # ⊠elif ev.type == pygame.MOUSEMOTION and self.dragged is not None: # ⊠# Process dragging card to x, y # ⊠renpy.restart_interaction()
ã€ãã³ãã®ãã¥ãŒã«ã€ããŠå¿é ããå¿ èŠã¯ãããŸããããšã³ãžã³èªäœã¯ãçŸåšã¢ã¯ãã£ããªãã¹ãŠã®èŠçŽ ã«ãã¹ãŠã®ã€ãã³ããé ä¿¡ããŸãã ãã®ã¡ãœããã«æ®ã£ãŠããã®ã¯ãã€ã³ã·ãã³ãã«é¢å¿ããããã©ããã確èªããã€ãã³ãã«å¿çããŠçžäºäœçšãå®äºããããšã§ãã Ren'Pyã®çžäºäœçšã¯ãä»ã®ãšã³ãžã³ã®ã²ãŒã ããžãã¯ã®ãã£ãã¯ãšã»ãŒåçã§ãããæéã«å¶éã¯ãããŸããã äžè¬çãªå Žåãããã¯1人ã®ãã¬ã€ã€ãŒã®ããŒã ãšããã«å¯Ÿå¿ããã²ãŒã ã®å¿çã§ãããå Žåã«ãã£ãŠã¯ïŒããšãã°ãããã¹ããã¹ã¯ããŒã«ãããšãïŒã察話ã¯èªåã§çµäºããããšãã§ããŸãã
ãã®Displayableã¯ãä»ã®ãã¹ãŠã®äººãšåæ§ã«ãç»é¢ã«ãŸãšããŠããŸãã
screen conflict_table_screen(): modal True zorder 9 add conflict_table
ãã®å Žåã®conflict_tableã¯ã¯ã©ã¹åã§ã¯ãªãã察å¿ããDisplayableãæ ŒçŽãããã°ããŒãã«å€æ°ã§ãã ã¹ã¯ãªãŒã³ã³ãŒãã¯ååãšããŠãã€ã§ãå®è¡ã§ããŸãããã·ã§ãŒã®åã«å¿ ãå®è¡ãããŸããããããªããšãã²ãŒã ã¯å®éã«è¡šç€ºããå¿ èŠããããã®ãèªèããŸããã ãããã£ãŠãconflict_table.set_decksïŒplayer_deckãopponent_deckïŒã®ãããªããšãè¡ãããã¬ã€ã€ãŒãå¿ èŠãªãã®ãæ£ç¢ºã«èŠã€ãããšããäºå®ã«äŸåããããšã¯ãããã²ãŒã ã®çŽåã«å®å šã«å®å šã§ãã åæ§ã«ãããã²ãŒã ã®æåŸã«ãåããªããžã§ã¯ãã«ä¿åãããŠããçµæã«ã¢ã¯ã»ã¹ã§ããŸãã
ã°ããŒãã«å€æ°ã®äœ¿çšã¯Ren'Pyã®å¶éã§ã¯ãªããç§ãã¡èªèº«ã®æ±ºå®ã§ãããšèšããªããã°ãªããŸããã ç»é¢ãšDisplayableããµããŒããããŠãããåŒæ°ãåãåã£ãŠå€ãè¿ãããšãã§ããŸããããããã¯ããè€éã§ãã ãŸãããã®ãããªç»é¢ã®åäœã¯ååã«ææžåãããŠããŸããã å°ãªããšããç»é¢ãæåã®ã€ã³ã¿ã©ã¯ã·ã§ã³ãéå§ããæ£ç¢ºãªç¬éãšãæ£ç¢ºã«ã¹ã¯ãªããã«å¶åŸ¡ãæ»ãã¿ã€ãã³ã°ãææ¡ããããšã¯éåžžã«å°é£ã§ãã ããã¯éåžžã«éèŠãªè³ªåã§ããçããããããªãå Žåã競åãå§ãŸãåã«ç«¶åã®åã®ããã¹ãå šäœã衚瀺ããã競åã®åŸã®ããã¹ãã衚瀺ãããªãããšãä¿èšŒããã®ã¯å°é£ã§ãã 第äºã«ãã°ããŒãã«å€æ°ã䜿çšãããšãããã²ãŒã ã«å¿ èŠãªãªããžã§ã¯ãã®ã»ãšãã©ãäžåºŠã ãåæåãããå®è¡ãããã³ã«å±æ§ãå€æŽãããŸãã ããããªããšã競åãçºçãããã³ã«å¿ èŠãªãã¡ã€ã«ããã¹ãŠããŒãããå¿ èŠããããŸãã HDDã«åæã«ã¢ã¯ã»ã¹ããå Žåãããšãã°ãã¬ã³ããšãŠã€ã«ã¹å¯Ÿçã®å Žåãã²ãŒã ã¯å€§å¹ ã«é ããŸãã æåŸã«ã競åç»é¢ã ãã§ãªããä»ã®ããã€ãã®ç»é¢ãã«ãŒããåç §ããŠãããããå¿ èŠãªå Žæã§åãDisplayableã䜿çšããã®ãè«ççã§ãã
ããšãã
ããã«ãããéçºã®å®éã®ãœãããŠã§ã¢éšåãçµäºããã²ãŒã ãžã®ã³ã³ãã³ãã®å å¡«ãéå§ãããŸãã ã²ãŒã å ã®æç®ã¯äž»ã«ç§ãäœæãããã®ã§ã¯ãªããããã¹ããŒãªãŒã®æ§é ãšã¹ã¿ã€ã«ã«ã€ããŠã¯èª¬æããŸããã ãã®ããŒãã«ã€ããŠã¯ãããšãã°CYOAã®æ§é ã«é¢ããå€å žçãªèšäºãèªãããšããå§ãããŸãã ãŸãã¯ã 80æ¥éã®èæ¬å®¶ãã説åŸåã®ããç¬ç«ããNPCãäœæããããã®åªããã¬ã€ãã§ãã
ãã®ä»ã®ãªã³ã¯ïŒããã³æè¿ã®è±èªã®äœåãšé¢é£èšäºã®ã¬ãã¥ãŒïŒã¯ã Emily Shortã®ããã°ã«ãããŸãã