def criarcenas(): mapa = Cena(img=MAPA) mapa.vai()
class leni(): caes = Elemento(img=CAES) guardas = Elemento(img=GUARDAS) remedio = Elemento(img=REMEDIO) mapa = Elemento(img=MAPA) computador = Elemento(img=COMPUTADOR) lixo = Elemento(img=LIXO) porta = Elemento(img=PORTA) livro = Elemento(img=LIVRO) bilhete = Elemento(img=BILHETE) portao = Elemento(img=PORTAO) saida = Elemento(img=SAIDA) biblioteca = Cena(img=BIBLIOTECA) casa = Cena(img=CASA) laboratorio = Cena(img=LABORATORIO) tunel = Cena(img=TUNEL) portao = Cena(img=PORTAO) pracinha = Cena(img=PRACA) haha = Labirinto(norte=casa, sul=biblioteca, oeste=laboratorio, leste=porta) hehe = Labirinto(leste=porta, sul=tunel, oeste=portao, norte=casa) doente = Elemento(img=DOENTE) doente.entra(casa) faladoente = Texto(casa, "o que aconteceu?") doente.vai = faladoente.vai ajudante = Elemento(img=AJUDANTE) ajudante.entra(norte.casa) falaajudante = Texto( casa, "O cientista foi sequetrado e roubaram as escrituras e seu compuatdor") ajudante.vai = falaajudante.vai #falaajudante=Texto(casa,"Sua primeira missão é achar os comprimidos para que ele fique estável até você encontrar o cientista") #ajudante.vai=falaajudante.vai ladrao = Elemento = (LADRAO) ladrao.entra(norte.casa) ajudante.entra(sul.biblioteca) falaajudante = Texto( biblioteca, "As coordenadas para seu rémedio estão no genótipo de uma doença") ajudante.vai = falaajudante.vai #falaajudante=Texto(biblioteca,"Todas as informações estão guardadas na biblioteca") #ajudante.vai=falaajudante.vai doente.entra(sul.biblioteca) bilhete.entra(sul.biblioteca) falabilhete = Texto(biblioteca, "Sua corordenada é hemofila!") bilhete.vai = falabilhete.vai guardas.entra(sul.biblioteca) livro.entra(sul.biblioteca) cientista = Elemento(img=CIENTISTA) cientista.entra(oeste.laboratorio) doente.entra(oeste.laboratorio) ladrao.entra(oeste.laboratorio) ajudante.entra(oeste.laboratorio) falaajudante = Texto( laboratorio, "doençança onde não há ou há pouca produção de melanina") ladrao.entra(leste.porta) doente.entra(leste.porta) cientista.entra(oeste.laboratorio) falacientista = Texto( laboratorio, "Foi meu ajudante que roubou as escrituras e me sequestrou!!") doente.entra(sul.tunel) cientista.entra(sul.tunel) saida.entra(oestte.portao) doente.entra(oeste.portao) cientista.entra(oeste.portao) doente.entra(leste.pracinha) cientista.entra(leste.pracinha) #hehe.vai() haha.vai()
# grace.grace.main.py # -*- coding: UTF8 -*- # This file is part of program Jogo Inca # Copyright © 2022 Carlo Oliveira <*****@*****.**>, # SPDX-License-Identifier: (GPLv3-or-later AND LGPL-2.0-only) WITH bison-exception from _spy.vitollino.main import Cena, STYLE from random import shuffle STYLE.update(width=800, height=500) TEMPLO = "https://i.imgur.com/OOTUIwl.jpg" templo = Cena(TEMPLO) tumba = list("ABCDE"*3) tesouros = list([1,2,3,4,5,6,7,8,9]*2) tumba += tesouros shuffle(tumba) #input(tumba) cripta = [] mochila = 0 templo.vai() for cam in tumba: cripta += [cam] if input(f"Cripta :{cripta} vai?") != 's': break if cam in tesouros: mochila += cam else: if cam in cripta: input("perdeu") cripta = [] mochila = 0 break #cripta += [cam]
#INVENTARIO.style["min-height"] = "60px" INVENTARIO.elt.style.height = "60px" linkilhadeusas = "https://i.imgur.com/5UvVC5M.png" linkOkami1 = "https://i.imgur.com/hr6DsqU.png" linkWaka1 = "https://i.imgur.com/e641yTi.png" linkArk1 = "https://imgur.com/zzfVPmy.png" linkGruta1 = "https://4.bp.blogspot.com/-MplqVVRjFCo/VzYD90Cm5jI/AAAAAAAAX_Q/x2JbhgAwJwAi0cNTQq2l2j6hLCEX--gZgCLcB/s1600/Gruta%2Bde%2BBacaetava.jpg" linkRat1 = "https://i.imgur.com/Mm8ebIk.png" linkArk2 = "https://i.imgur.com/DhV0DOD.png" inventario = "https://i.imgur.com/OhT5Wxa.png" quest_img = "https://i.imgur.com/rVZ1nFW.png" option_img = "https://i.imgur.com/xmMC1Se.png" okami_fala = 0 """As cenas são criadas primeiro, aqui em cima""" cenaIlha = Cena(img="https://i.imgur.com/5UvVC5M.png") cena_gruta = Cena(img=linkGruta1) def gruta(_=0): """Você tem um 'def' (função) para cada cena, esta aqui faz a cena da gruta""" global cenaIlha cena_gruta = Cena(img=linkGruta1) rat1 = Elemento(img=linkRat1, tit="Rat godess", y=300, x=170, h=400, w=400) rat1.entra(cena_gruta) txtrat1 = Texto( cena_gruta, "afie minha espada mas por um porem prove sue valor completando ésa missão." ) rat1.vai = txtrat1.vai
def abre_desafio(event=None): desafio = Cena(imagem_desafio) desafio.vai() texto_1 = Texto(desafio, txt='Complete o quadrado:') texto_1.vai()
# vera.mar.main.py from _spy.vitollino.main import Cena, STYLE, Texto STYLE["width"], STYLE["height"] = 1200, "650px" from elemento.main import Elemento PRAIA = "https://i.imgur.com/slKTEBc.png" ILHAMAR = "https://i.imgur.com/3FUDzbn.jpg" BARCO = "https://i.imgur.com/ckjd6cI.png" BOIA = "https://i.imgur.com/GmzOUTL.png" ilhamar = Cena(ILHAMAR) def vai_trilha(*_): from trilhacaverna.main import Caverna Caverna().vai() praia = Elemento(PRAIA, cena=ilhamar, x=700, y=398, h=900, style=dict(width=500, height="650px"), vai=vai_trilha) Texto(ilhamar, "mimi").vai() ilhamar.vai() def vai_fundo(*_): from perigo1.main import Perigo Perigo().vai()
def __init__(self): self.Biblioteca_entrada = Cena(biblioteca_faixada) self.BIBLIOTECA = Cena(biblioteca_faixada2) self.BIBLIOTECA2 = Cena(biblioteca_faixada2) self.BIBLIOTECA3 = Cena(biblioteca_faixada2) self.BIBLIOTECA4 = Cena(biblioteca_faixada2) self.BIBLIOTECA5 = Cena(biblioteca_faixada2) self.BIBLIOTECA6 = Cena(biblioteca_faixada2) self.BIBLIOTECA7 = Cena(biblioteca_faixada2) self.BIBLIOTECA8 = Cena(biblioteca_faixada2) #ELEMENTOS ATO2.1 self.PORTA = Elemento( porta, tit="click", w=238, h=695, x=350, y=-10, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.Biblioteca_entrada) self.BONECA2 = Elemento( imagem_boneca2, tit="Hipátia", w=250, h=350, x=50, y=340, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.Biblioteca_entrada) self.CONTINUA = Elemento(continua, tit="Próximo", w=100, h=60, x=800, y=550, cena=self.BIBLIOTECA8) #ELEMENTOS BIBLIOTECA self.DESAFIO = Elemento( desafio1, tit="", w=300, h=300, x=310, y=280, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.BIBLIOTECA) self.T_AZUL = Elemento(triangulo_azul, tit="Monte o quebra-cabeça.", h=80, w=80, x=100, y=150, cena=self.BIBLIOTECA) self.T_AMARELO = Elemento(triangulo_amarelo, tit="Monte o quebra-cabeça.", h=80, w=80, x=200, y=150, cena=self.BIBLIOTECA) self.T_VERMELHO = Elemento(triangulo_vermelho, tit="Monte o quebra-cabeça.", h=80, w=80, x=300, y=150, cena=self.BIBLIOTECA) self.T_VERDE = Elemento(triangulo_verde, tit="Monte o quebra-cabeça.", h=80, w=80, x=400, y=150, cena=self.BIBLIOTECA) self.T_ROXO = Elemento(triangulo_roxo, tit="Monte o quebra-cabeça.", h=80, w=80, x=500, y=150, cena=self.BIBLIOTECA) self.T_ROSA = Elemento(triangulo_rosa, tit="Monte o quebra-cabeça.", h=80, w=80, x=600, y=150, cena=self.BIBLIOTECA) self.T_LARANJA = Elemento(triangulo_laranja, tit="Monte o quebra-cabeça.", h=80, w=80, x=700, y=150, cena=self.BIBLIOTECA) self.T_CIANO = Elemento(triangulo_ciano, tit="Monte o quebra-cabeça.", h=80, w=80, x=800, y=150, cena=self.BIBLIOTECA) self.BOTAO_AJUDA = Elemento(imagem_botaoajuda, tit="PLAY", w=55, h=58, x=200, y=300, cena=self.BIBLIOTECA) #ELEMENTOS BIBLIOTECA2 self.DESAFIO2 = Elemento( desafio2, tit="", w=300, h=300, x=310, y=280, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.BIBLIOTECA2) self.T_AZUL2 = Elemento(triangulo_azul, tit="Monte o quebra-cabeça.", h=80, w=80, x=100, y=150, cena=self.BIBLIOTECA2) self.T_AMARELO2 = Elemento(triangulo_amarelo, tit="Monte o quebra-cabeça.", h=80, w=80, x=200, y=150, cena=self.BIBLIOTECA2) self.T_VERMELHO2 = Elemento(triangulo_vermelho, tit="Monte o quebra-cabeça.", h=80, w=80, x=300, y=150, cena=self.BIBLIOTECA2) self.T_VERDE2 = Elemento(triangulo_verde, tit="Monte o quebra-cabeça.", h=80, w=80, x=400, y=150, cena=self.BIBLIOTECA2) self.T_ROXO2 = Elemento(triangulo_roxo, tit="Monte o quebra-cabeça.", h=80, w=80, x=500, y=150, cena=self.BIBLIOTECA2) self.T_ROSA2 = Elemento(triangulo_rosa, tit="Monte o quebra-cabeça.", h=80, w=80, x=600, y=150, cena=self.BIBLIOTECA2) self.T_LARANJA2 = Elemento(triangulo_laranja, tit="Monte o quebra-cabeça.", h=80, w=80, x=700, y=150, cena=self.BIBLIOTECA2) #ELEMENTOS BIBLIOTECA 3 self.DESAFIO3 = Elemento( desafio3, tit="", w=300, h=300, x=310, y=280, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.BIBLIOTECA3) self.T_AMARELO3 = Elemento(triangulo_amarelo, tit="Monte o quebra-cabeça.", h=80, w=80, x=200, y=150, cena=self.BIBLIOTECA3) self.T_VERMELHO3 = Elemento(triangulo_vermelho, tit="Monte o quebra-cabeça.", h=80, w=80, x=300, y=150, cena=self.BIBLIOTECA3) self.T_VERDE3 = Elemento(triangulo_verde, tit="Monte o quebra-cabeça.", h=80, w=80, x=400, y=150, cena=self.BIBLIOTECA3) self.T_ROXO3 = Elemento(triangulo_roxo, tit="Monte o quebra-cabeça.", h=80, w=80, x=500, y=150, cena=self.BIBLIOTECA3) self.T_ROSA3 = Elemento(triangulo_rosa, tit="Monte o quebra-cabeça.", h=80, w=80, x=600, y=150, cena=self.BIBLIOTECA3) self.T_LARANJA3 = Elemento(triangulo_laranja, tit="Monte o quebra-cabeça.", h=80, w=80, x=700, y=150, cena=self.BIBLIOTECA3) #ELEMENTOS BIBLIOTECA 4 self.DESAFIO4 = Elemento( desafio4, tit="", w=300, h=300, x=310, y=280, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.BIBLIOTECA4) self.T_AMARELO4 = Elemento(triangulo_amarelo, tit="Monte o quebra-cabeça.", h=80, w=80, x=200, y=150, cena=self.BIBLIOTECA4) self.T_VERDE4 = Elemento(triangulo_verde, tit="Monte o quebra-cabeça.", h=80, w=80, x=400, y=150, cena=self.BIBLIOTECA4) self.T_ROXO4 = Elemento(triangulo_roxo, tit="Monte o quebra-cabeça.", h=80, w=80, x=500, y=150, cena=self.BIBLIOTECA4) self.T_ROSA4 = Elemento(triangulo_rosa, tit="Monte o quebra-cabeça.", h=80, w=80, x=600, y=150, cena=self.BIBLIOTECA4) self.T_LARANJA4 = Elemento(triangulo_laranja, tit="Monte o quebra-cabeça.", h=80, w=80, x=700, y=150, cena=self.BIBLIOTECA4) #ELEMENTOS BIBLIOTECA 5 self.DESAFIO5 = Elemento( desafio5, tit="", w=300, h=300, x=310, y=280, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.BIBLIOTECA5) self.T_AMARELO5 = Elemento(triangulo_amarelo, tit="Monte o quebra-cabeça.", h=80, w=80, x=200, y=150, cena=self.BIBLIOTECA5) self.T_VERDE5 = Elemento(triangulo_verde, tit="Monte o quebra-cabeça.", h=80, w=80, x=400, y=150, cena=self.BIBLIOTECA5) self.T_ROXO5 = Elemento(triangulo_roxo, tit="Monte o quebra-cabeça.", h=80, w=80, x=500, y=150, cena=self.BIBLIOTECA5) self.T_ROSA5 = Elemento(triangulo_rosa, tit="Monte o quebra-cabeça.", h=80, w=80, x=600, y=150, cena=self.BIBLIOTECA5) #ELEMENTOS BIBLIOTECA 6 self.DESAFIO6 = Elemento( desafio6, tit="", w=300, h=300, x=310, y=280, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.BIBLIOTECA6) self.T_VERDE6 = Elemento(triangulo_verde, tit="Monte o quebra-cabeça.", h=80, w=80, x=400, y=150, cena=self.BIBLIOTECA6) self.T_ROXO6 = Elemento(triangulo_roxo, tit="Monte o quebra-cabeça.", h=80, w=80, x=500, y=150, cena=self.BIBLIOTECA6) self.T_ROSA6 = Elemento(triangulo_rosa, tit="Monte o quebra-cabeça.", h=80, w=80, x=600, y=150, cena=self.BIBLIOTECA6) #ELEMENTOS BIBLIOTECA 7 self.DESAFIO7 = Elemento( desafio7, tit="", w=300, h=300, x=310, y=280, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.BIBLIOTECA7) self.T_VERDE7 = Elemento(triangulo_verde, tit="Monte o quebra-cabeça.", h=80, w=80, x=400, y=150, cena=self.BIBLIOTECA7) self.T_ROSA7 = Elemento(triangulo_rosa, tit="Monte o quebra-cabeça.", h=80, w=80, x=600, y=150, cena=self.BIBLIOTECA7) #ELEMENTOS BIBLIOTECA 8 self.DESAFIO8 = Elemento( desafio8, tit="", w=300, h=300, x=310, y=280, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.BIBLIOTECA8) #TEXTO BIBLIOTECA self.texto_1_1 = Texto(self.Biblioteca_entrada, txt="Entre na biblioteca interditada.") self.texto_2_2 = Texto( self.BIBLIOTECA, txt="A porta esta trancada. Resolva o desafio para abri-la") self.texto_1 = Texto( self.BIBLIOTECA, txt='Clique na peça que se encaixa no quadrado vermelho.') self.texto_2 = Texto(self.BIBLIOTECA, txt='Esta não é a peça correta.') self.texto_3 = Texto(self.BIBLIOTECA2, txt='Esta não é a peça correta.') self.texto_4 = Texto(self.BIBLIOTECA3, txt='Esta não é a peça correta.') self.texto_5 = Texto(self.BIBLIOTECA4, txt='Esta não é a peça correta.') self.texto_6 = Texto(self.BIBLIOTECA5, txt='Esta não é a peça correta.') self.texto_7 = Texto(self.BIBLIOTECA6, txt='Esta não é a peça correta.') self.texto_8 = Texto(self.BIBLIOTECA7, txt='Esta não é a peça correta.') self.texto_9 = Texto( self.BIBLIOTECA8, txt='Parabéns! Você conseguiu completar o desafio!') self.texto_10 = Texto( self.BIBLIOTECA, txt= "O desafio é um quebra cabeça. Clique na peça que compõe a imagem para completá-lo." ) #BOTAO BIBLIOTECA 1 self.T_CIANO.elt.bind("click", self.desafio1) self.T_AZUL.elt.bind("click", self.botao_errado) self.T_VERMELHO.elt.bind("click", self.botao_errado) self.T_AMARELO.elt.bind("click", self.botao_errado) self.T_VERDE.elt.bind("click", self.botao_errado) self.T_ROXO.elt.bind("click", self.botao_errado) self.T_ROSA.elt.bind("click", self.botao_errado) self.T_LARANJA.elt.bind("click", self.botao_errado) self.BOTAO_AJUDA.elt.bind("click", self.AJUDA) #BOTAO BIBLIOTECA2 self.T_AZUL2.elt.bind("click", self.desafio2) self.T_VERMELHO2.elt.bind("click", self.botao_errado2) self.T_AMARELO2.elt.bind("click", self.botao_errado2) self.T_VERDE2.elt.bind("click", self.botao_errado2) self.T_ROXO2.elt.bind("click", self.botao_errado2) self.T_ROSA2.elt.bind("click", self.botao_errado2) self.T_LARANJA2.elt.bind("click", self.botao_errado2) #BOTAOBIBLIOTECA3 self.T_VERMELHO3.elt.bind("click", self.desafio3) self.T_AMARELO3.elt.bind("click", self.botao_errado3) self.T_VERDE3.elt.bind("click", self.botao_errado3) self.T_ROXO3.elt.bind("click", self.botao_errado3) self.T_ROSA3.elt.bind("click", self.botao_errado3) self.T_LARANJA3.elt.bind("click", self.botao_errado3) #BOTAOBIBLIOTECA4 self.T_AMARELO4.elt.bind("click", self.botao_errado4) self.T_VERDE4.elt.bind("click", self.botao_errado4) self.T_ROXO4.elt.bind("click", self.botao_errado4) self.T_ROSA4.elt.bind("click", self.botao_errado4) self.T_LARANJA4.elt.bind("click", self.desafio4) #BOTAOBIBLIOTECA5 self.T_AMARELO5.elt.bind("click", self.desafio5) self.T_VERDE5.elt.bind("click", self.botao_errado5) self.T_ROXO5.elt.bind("click", self.botao_errado5) self.T_ROSA5.elt.bind("click", self.botao_errado5) #BOTAOBIBLIOTECA6 self.T_VERDE6.elt.bind("click", self.botao_errado6) self.T_ROXO6.elt.bind("click", self.desafio6) self.T_ROSA6.elt.bind("click", self.botao_errado6) #BOTAOBIBLIOTECA7 self.T_VERDE7.elt.bind("click", self.desafio7) self.T_ROSA7.elt.bind("click", self.botao_errado7) #botao ato2.1 self.PORTA.elt.bind("click", self.abre_porta) self.CONTINUA.elt.bind("click", self.chama_sala)
# phyllis.roxanne.main.py from _spy.vitollino.main import Cena, Elemento, Texto MAR = "https://i.imgur.com/fk9FgaR.jpg" MORANGO = " https://i.imgur.com/TYqfeqN.png" CAMPO = " https://i.imgur.com/JD7nQxw.jpg" ABELHA = "https://i.imgur.com/koKQC7y.png" mar=Cena(img= MAR) morango = Elemento( img= MORANGO) morango.entra(mar) campo =Cena(img=CAMPO) mar.direita=campo campo.esquerda=mar abelha = Elemento(img= ABELHA) abelha.entra(campo) mar.vai ()
def _main(): document['pydiv'].html = "" plano_fundo = Cena(img=plano_fundo) plano_fundo.vai()
def __init__(self): self.fundo = Cena(FUNDO, direita=start()) self.comp1 = Elemento(LIVRO, h=100, w=100, x=0, y=0, cena=self.fundo) self.comp1.elt.bind("click", self.opcao)
from _spy.vitollino.main import Cena, Elemento, STYLE, Texto Imagem_Biblioteca_porta = "https://media.istockphoto.com/vectors/closed-door-drawing-vector-id865663698" Imagem_Biblioteca_porta2 = "https://image.freepik.com/vetores-gratis/porta-aberta-dos-desenhos-animados-entrada-do-corredor-do-apartamento-entrada-do-escritorio_53562-8532.jpg" Imagem_Biblioteca_dentro = "https://secult.es.gov.br/Media/secult/BPES/IMG_7650.JPG" STYLE["width"] = 500 # width = 300 (default) STYLE["heigth"] = '600px' # min-height = "300px" Biblioteca_entrada = Cena(Imagem_Biblioteca_porta) Biblioteca_entrada.vai() Biblioteca_porta = Cena(Imagem_Biblioteca_porta2) Biblioteca_dentro = Cena(Imagem_Biblioteca_dentro) Imagem_botao = "https://images-na.ssl-images-amazon.com/images/I/71nQDXqkyDL.png" def desafio_porta1(event=None): Biblioteca_porta.vai() BOTAO = Elemento( Imagem_botao, tit="click", w=30, h=36, x=450, y=300, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=Biblioteca_entrada)
def Historia(): cenaPly = Cena( img= "http://www.pureviagem.com.br/noticia/as-10-montanhas-mais-altas-do-mundo_a9087/11#11" ) cenaPly.vai()
def __init__ (self): def remover_carta(carta): self.lista_de_cartas.append(carta) carta.elt.style.left = Pilha_cartas_left carta.elt.style.top = Pilha_cartas_top self.tabuleiro[carta.img.tabuleiro][casa.img.casa].img.ocupado = 0 carta.img.tabuleiro = "null" carta.img.casa = "null" def move_carta(casa): casa_destino = casa.target.id tabuleiro_target = casa.target.tabuleiro carta_a_mover = self.lista_de_cartas.pop() self.cartas_no_tabuleiro.append(carta_a_mover) elemento_casa_do_tabuleiro = self.tabuleiro[tabuleiro_target][casa_destino].elt carta_a_mover.elt.style.left = elemento_casa_do_tabuleiro.style.left carta_a_mover.elt.style.top = elemento_casa_do_tabuleiro.style.top carta_a_mover.elt.onclick = remover_carta carta_a_mover.img.casa = casa_destino carta_a_mover.img.tabuleiro = tabuleiro_target self.tabela_fase1 = tabelafase1 = Cena(img=FUNDO) self.lista_de_cartas =[] self.cartas_no_tabuleiro = [] Pilha_Cartas = [] for f in range (24): Pilha_Cartas.append(QAZUL) ### TABULEIRO DA ESQUERDA E DA DIREITA#### TBX, TBY = 80, 80 self.tabuleiro = dict(esquerda = {}, direita = {}) inicio_x, inicio_y = 390, 128 for coluna_ in range(3): for linha_ in range(4): nome = "{}_{}".format(linha_, coluna_) self.tabuleiro["esquerda"][nome] = Elemento(FUNDO, tit=nome+"_", style=dict( width=TBX-15, height="{}px".format(TBY-8), left=inicio_x - coluna_*TBX - (TBX-15), top=inicio_y+linha_*TBY))#-15 o quadradinho diminui na largura self.tabuleiro["esquerda"][nome].entra(tabelafase1) self.tabuleiro["esquerda"][nome].img.id = nome self.tabuleiro["esquerda"][nome].img.tabuleiro = "esquerda" self.tabuleiro["esquerda"][nome].img.ocupado = 0 self.tabuleiro["esquerda"][nome].elt.onclick = move_carta inicio_x, inicio_y = 430, 128 for coluna_ in range(3): for linha_ in range(4): nome = "{}_{}".format(linha_, coluna_) self.tabuleiro["direita"][nome] = Elemento(FUNDO, tit=nome+"_", style=dict( width=TBX-15, height="{}px".format(TBY-8), left=inicio_x+coluna_*TBX, top=inicio_y+linha_*TBY)) self.tabuleiro["direita"][nome].entra(tabelafase1) self.tabuleiro["direita"][nome].img.id = nome self.tabuleiro["direita"][nome].img.tabuleiro = "direita" self.tabuleiro["direita"][nome].img.ocupado = 0 self.tabuleiro["direita"][nome].elt.onclick = move_carta ###PILHA DE CARTAS### Pilha_Cartas_top = 30 Pilha_Cartas_left = 30 for carta in Pilha_Cartas: a_carta_a_ser_empilhada = Elemento (carta, tit= "carta", style=dict( width="65px", height="70px", left=Pilha_Cartas_left, top=Pilha_Cartas_top)) a_carta_a_ser_empilhada.img.casa = "null" a_carta_a_ser_empilhada.img.tabuleiro = "null" self.lista_de_cartas.append(a_carta_a_ser_empilhada) a_carta_a_ser_empilhada.entra(tabelafase1) def recoloca_clique_aqui(_): self.cliqueaqui.entra(tabelafase1) for nome in self.tabuleiro["direita"]: self.tabuleiro["direita"][nome].elt.onclick = recoloca_clique_aqui for nome in self.tabuleiro["esquerda"]: self.tabuleiro["esquerda"][nome].elt.onclick = recoloca_clique_aqui ####SEGUNDA FASE#### def segunda_fase(self): class Tabuleiro2: def __init__ (self): def remover_carta(carta): self.lista_de_cartas.append(carta) carta.elt.style.left = Pilha_cartas_left carta.elt.style.top = Pilha_cartas_top self.tabuleiro[carta.img.tabuleiro][casa.img.casa].img.ocupado = 0 carta.img.tabuleiro = "null" carta.img.casa = "null" def move_carta(casa): casa_destino = casa.target.id tabuleiro_target = casa.target.tabuleiro carta_a_mover = self.lista_de_cartas.pop() self.cartas_no_tabuleiro.append(carta_a_mover) elemento_casa_do_tabuleiro = self.tabuleiro[tabuleiro_target][casa_destino].elt carta_a_mover.elt.style.left = elemento_casa_do_tabuleiro.style.left carta_a_mover.elt.style.top = elemento_casa_do_tabuleiro.style.top carta_a_mover.elt.onclick = remover_carta carta_a_mover.img.casa = casa_destino carta_a_mover.img.tabuleiro = tabuleiro_target self.tabela_fase1 = tabelafase1 = Cena(img=FUNDO) self.lista_de_cartas =[] self.cartas_no_tabuleiro = [] Pilha_Cartas = [] for f in range (36): Pilha_Cartas.append(QVERMELHO) ### TABULEIRO DA ESQUERDA E DA DIREITA#### TBX, TBY = 80, 80 self.tabuleiro = dict(esquerda = {}, direita = {}) inicio_x, inicio_y = 390, 50 for coluna_ in range(3): for linha_ in range(6): nome = "{}_{}".format(linha_, coluna_) self.tabuleiro["esquerda"][nome] = Elemento(FUNDO, tit=nome+"_", style=dict( width=TBX-15, height="{}px".format(TBY-8), left=inicio_x - coluna_*TBX - (TBX-15), top=inicio_y+linha_*TBY))#-15 o quadradinho diminui na largura self.tabuleiro["esquerda"][nome].entra(tabelafase2) self.tabuleiro["esquerda"][nome].img.id = nome self.tabuleiro["esquerda"][nome].img.tabuleiro = "esquerda" self.tabuleiro["esquerda"][nome].img.ocupado = 0 self.tabuleiro["esquerda"][nome].elt.onclick = move_carta inicio_x, inicio_y = 430, 50 for coluna_ in range(3): for linha_ in range(6): nome = "{}_{}".format(linha_, coluna_) self.tabuleiro["direita"][nome] = Elemento(FUNDO, tit=nome+"_", style=dict( width=TBX-15, height="{}px".format(TBY-8), left=inicio_x+coluna_*TBX, top=inicio_y+linha_*TBY)) self.tabuleiro["direita"][nome].entra(tabelafase2) self.tabuleiro["direita"][nome].img.id = nome self.tabuleiro["direita"][nome].img.tabuleiro = "direita" self.tabuleiro["direita"][nome].img.ocupado = 0 self.tabuleiro["direita"][nome].elt.onclick = move_carta ###PILHA DE CARTAS### Pilha_Cartas_top = 30 Pilha_Cartas_left = 30 for carta in Pilha_Cartas: a_carta_a_ser_empilhada = Elemento (carta, tit= "carta", style=dict( width="65px", height="70px", left=Pilha_Cartas_left, top=Pilha_Cartas_top)) a_carta_a_ser_empilhada.img.casa = "null" a_carta_a_ser_empilhada.img.tabuleiro = "null" self.lista_de_cartas.append(a_carta_a_ser_empilhada) a_carta_a_ser_empilhada.entra(tabelafase2) def recoloca_clique_aqui(_): self.cliqueaqui.entra(tabelafase2) for nome in self.tabuleiro["direita"]: self.tabuleiro["direita"][nome].elt.onclick = recoloca_clique_aqui for nome in self.tabuleiro["esquerda"]: self.tabuleiro["esquerda"][nome].elt.onclick = recoloca_clique_aqui #tabelafase2.direita = segunda_fase.vai() #if tabelafase1.direita(self): #self.segunda_fase() #Tabuleiro2() tabelafase2.vai() Tabuleiro2() ###TERCEIRA FASE### def terceira_fase(): class Tabuleiro3: def __init__ (self): def remover_carta(carta): self.lista_de_cartas.append(carta) carta.elt.style.left = Pilha_cartas_left carta.elt.style.top = Pilha_cartas_top self.tabuleiro[carta.img.tabuleiro][casa.img.casa].img.ocupado = 0 carta.img.tabuleiro = "null" carta.img.casa = "null" def move_carta(casa): casa_destino = casa.target.id tabuleiro_target = casa.target.tabuleiro carta_a_mover = self.lista_de_cartas.pop() self.cartas_no_tabuleiro.append(carta_a_mover) elemento_casa_do_tabuleiro = self.tabuleiro[tabuleiro_target][casa_destino].elt carta_a_mover.elt.style.left = elemento_casa_do_tabuleiro.style.left carta_a_mover.elt.style.top = elemento_casa_do_tabuleiro.style.top carta_a_mover.elt.onclick = remover_carta carta_a_mover.img.casa = casa_destino carta_a_mover.img.tabuleiro = tabuleiro_target self.tabela_fase3 = tabelafase3 = Cena(img=FUNDO) self.lista_de_cartas =[] self.cartas_no_tabuleiro = [] Pilha_Cartas = [] for f in range (42): Pilha_Cartas.append(QVERDE) ### TABULEIRO DA ESQUERDA E DA DIREITA#### TBX, TBY = 80, 80 self.tabuleiro = dict(esquerda = {}, direita = {}) inicio_x, inicio_y = 700, 50 for coluna_ in range(7): for linha_ in range(3): nome = "{}_{}".format(linha_, coluna_) self.tabuleiro["esquerda"][nome] = Elemento(FUNDO, tit=nome+"_", style=dict( width=TBX-15, height="{}px".format(TBY-8), left=inicio_x - coluna_*TBX - (TBX-15), top=inicio_y+linha_*TBY))#-15 o quadradinho diminui na largura self.tabuleiro["esquerda"][nome].entra(tabelafase3) self.tabuleiro["esquerda"][nome].img.id = nome self.tabuleiro["esquerda"][nome].img.tabuleiro = "esquerda" self.tabuleiro["esquerda"][nome].img.ocupado = 0 self.tabuleiro["esquerda"][nome].elt.onclick = move_carta inicio_x, inicio_y = 155, 330 for coluna_ in range(7): for linha_ in range(3): nome = "{}_{}".format(linha_, coluna_) self.tabuleiro["direita"][nome] = Elemento(FUNDO, tit=nome+"_", style=dict( width=TBX-15, height="{}px".format(TBY-8), left=inicio_x+coluna_*TBX, top=inicio_y+linha_*TBY)) self.tabuleiro["direita"][nome].entra(tabelafase3) self.tabuleiro["direita"][nome].img.id = nome self.tabuleiro["direita"][nome].img.tabuleiro = "direita" self.tabuleiro["direita"][nome].img.ocupado = 0 self.tabuleiro["direita"][nome].elt.onclick = move_carta ###PILHA DE CARTAS### Pilha_Cartas_top = 30 Pilha_Cartas_left = 30 for carta in Pilha_Cartas: a_carta_a_ser_empilhada = Elemento (carta, tit= "carta", style=dict( width="65px", height="70px", left=Pilha_Cartas_left, top=Pilha_Cartas_top)) a_carta_a_ser_empilhada.img.casa = "null" a_carta_a_ser_empilhada.img.tabuleiro = "null" self.lista_de_cartas.append(a_carta_a_ser_empilhada) a_carta_a_ser_empilhada.entra(tabelafase3) def recoloca_clique_aqui(_): self.cliqueaqui.entra(tabelafase3) for nome in self.tabuleiro["direita"]: self.tabuleiro["direita"][nome].elt.onclick = recoloca_clique_aqui for nome in self.tabuleiro["esquerda"]: self.tabuleiro["esquerda"][nome].elt.onclick = recoloca_clique_aqui #tabelafase2.direita = segunda_fase.vai() #if tabelafase1.direita(self): #self.segunda_fase() #Tabuleiro2() tabelafase3.vai() Tabuleiro3() tabelafase1.vai()
# This file is part of program Jogo Inca # Copyright © 2022 Carlo Oliveira <*****@*****.**>, # SPDX-License-Identifier: (GPLv3-or-later AND LGPL-2.0-only) WITH bison-exception from random import shuffle from _spy.vitollino.main import Cena, STYLE from random import shuffle STYLE.update(width=1000, height=500) TEMPLO = "https://i.imgur.com/OOTUIwl.jpg" TESOURO = "https://i.imgur.com/OuPgmla.jpg" MONSTRO = "https://i.imgur.com/lcvvL1B.png" ARANHA = "https://i.imgur.com/p2jHT5d.png" COBRA = "https://i.imgur.com/ho6ZMAL.png" CHAMAS = "https://i.imgur.com/G2u6KB1.jpg" MUMIA = "https://i.imgur.com/awwkaBO.jpg" DESABA = "https://i.imgur.com/hZ0ohTz.jpg" templo = Cena(TEMPLO) cena_tesouro = Cena(TESOURO) cena_monstro = Cena(MONSTRO) jogar = input ("Quer jogar o tesouro Inca?") tumba = list("AMCDI"*3) tesouro = [1,2,3,4,5,6,7,8,9]*2 tumba += tesouro shuffle(tumba) corredor = [] mochila = 0 templo.vai() if jogar == 's': input("simbora!") for camara in tumba: dois_monstros = (camara not in tesouro) and (camara in corredor) eh_tesouro = camara in tesouro
# margaret.parisa.main.py from _spy.vitollino.main import Cena CENA = "https://i.imgur.com/gjHwE6J.jpg" SEREIAMONSTRO = "https://i.imgur.com/7Hfx7Vd.jpg" FLORESTA = "https://i.imgur.com/Jfr1Ww9.jpg" templo = Cena(CENA) sereiamonstro = Cena(SEREIAMONSTRO) floresta = Cena(FLORESTA) templo.direita = sereiamonstro sereiamonstro.esquerda = templo sereiamonstro.direita = floresta floresta.esquerda = templo templo.vai()
# roberta.julia.main.py # SPDX-License-Identifier: GPL-3.0-or-later """ XXXXX .. codeauthor:: Camila Silveira <*****@*****.**> Changelog --------- .. versionadded:: - XXX """ from _spy.vitollino.main import Cena, STYLE STYLE["width"] = 900 STYLE["heigth"] = "900px" FLORESTA = "https://macmagazine.uol.com.br/wp-content/uploads/2015/04/16-floresta.jpg" floresta_verde = Cena(FLORESTA) floresta_verde.vai()
# SPDX-License-Identifier: GPL-3.0-or-later """ Projeto sem descrição, (mude esta linha). .. codeauthor:: Nome Sobrenome <*****@*****.**> Changelog --------- .. versionadded:: 20.09 Descreva o que você adicionou no código. """ from _spy.vitollino.main import Cena, STYLE MUNDO = "http://www.pngall.com/wp-content/uploads/1/World-Map.png" ARCO = "https://i.ytimg.com/vi/ynxZPR27gi4/maxresdefault.jpg" LAPIS = "https://i.ytimg.com/vi/5igYewGEoFo/maxresdefault.jpg" ELEMENTO="https://external-content.duckduckgo.com/iu/?u=https%3A%2F%2Fi.redd.it%2Fxgorxiy1z4s11.png" STYLE["width"] = 900 STYLE["heigth"] = "900px" cena_direita = Cena(ARCO) cena_esquerda =Cena(LAPIS) cena_fundo = Cena(MUNDO, esquerda=cena_esquerda, direita=cena_direita) cena_esquerda.direita = cena_fundo cena_direita.esquerda = cena_fundo cena_fundo.vai()
def vai(self): """ Mostra a cena do tabuleiro """ Cena(TABULEIRO).vai()
def Historia(): cenaHouse = Cena( img= "https://vignette.wikia.nocookie.net/teenwolfserie/images/1/14/Teen_Wolf_Season_3_Episode_1_Beacon_Hills_Street_Night.png/revision/latest?cb=20180411122138&path-prefix=pt-br" ) cenaHouse.vai()
def __init__(self): """ Mostra o tabuleiro com o botão start""" self.cena = Cena(TABULEIRO, direita=Tabuleiro()) self.start = Elemento(BOTAO, x=50, y=50, cena=self.cena)
def __init__(self): # floresta_faca = FlorestaFaca() -XX- ERRO! self.floresta_inicio = None floresta_faca = CenaProxy(self.floresta_inicio) self.floresta_inicio = Cena(FLORESTA, direita=floresta_faca) rede = Rede(self.floresta_inicio)
CRITERIO_COR_VERMELHO = "https://imgur.com/ggv9wva.png" #domensoes = 52x52 * CRITERIO_CIRCULO_A = "https://imgur.com/E5GTyil.png" #domensoes = 52x52 * #CRITERIO_GRANDE = "https://imgur.com/yBD04Wg.png" GEOMETRICO_CIRCULO_VERMELHO = "https://imgur.com/CZJ0xTb.png" #domensoes = 33x33* from browser import document pdiv = document["pydiv"] pdiv.style.minHeight = "1100px" pdiv.style.marginLeft = "-120px" pdiv.style.marginTop = "-40px" from _spy.vitollino.main import Cena, Elemento, STYLE STYLE.update(width = 1920, height = '1080px') # width = 300 (default) #STYLE["heigth"] = "300px" # min-height = "300px" fundo_estatico = Cena (BACKGROUND) tronco_base = Elemento(TRONCO_BASE , x =550, y=550, w=416, h=523, cena = fundo_estatico)# ok ramo_nivel_tres = Elemento(BRANCH_TRES_NIVEL_UM , x =402, y=593, w=169, h=239, cena = fundo_estatico)# ok ramo_nivel_tres__ = Elemento(BRANCH_TRES_NIVEL_DOIS , x =433, y=830, w=160, h=98 , cena = fundo_estatico)# ok ramo_nivel_tres_um = Elemento(BRACO_UM_UM , x =561, y=892, w=81 , h=100, cena = fundo_estatico)# ok ramo_nivel_tres_dois = Elemento(BRACO_UM_DOIS , x =478, y=928, w=52 , h=93 , cena = fundo_estatico)# ok ramo_nivel_tres_dois = Elemento(BRACO_UM_TRES , x =359, y=873, w=98 , h=85 , cena = fundo_estatico)# ok criterio_cor_vermelho = Elemento(CRITERIO_COR_VERMELHO , x =490, y=805, w=52 , h=52 , cena = fundo_estatico)# ok criterio_circulo_A = Elemento(CRITERIO_CIRCULO_A , x =535, y=672, w=52 , h=52 , cena = fundo_estatico)# ok geometrico_vermelho = Elemento(GEOMETRICO_CIRCULO_VERMELHO, x =611, y=961, w=33 , h=33 , cena = fundo_estatico) fundo_estatico.vai()
# elizabeth.sara.main.py from _spy.vitollino.main import Cena, Elemento, STYLE, Texto porta_fechada = "https://media.istockphoto.com/vectors/closed-door-drawing-vector-id865663698" Imagem_botao = "https://images-na.ssl-images-amazon.com/images/I/71nQDXqkyDL.png" imagem_desafio = 'https://s2.static.brasilescola.uol.com.br/img/2019/10/quadrado-abcd.jpg' Biblioteca_entrada = Cena(porta_fechada) Biblioteca_entrada.vai() def abre_desafio(event=None): desafio = Cena(imagem_desafio) desafio.vai() texto_1 = Texto(desafio, txt='Complete o quadrado:') texto_1.vai() BOTAO = Elemento( Imagem_botao, tit="click", w=30, h=36, x=450, y=300, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=Biblioteca_entrada) BOTAO.elt.bind("click", abre_desafio)
def __init__(self): castelo = Cena(CASTELO, direita=Fazenda()) castelo.vai()
STYLE["width"] = 960 STYLE["height"] = "600px" wall = "https://i.imgur.com/OclGL7S.png" window_ = "https://i.imgur.com/O1pEa77.png" window_2 = "https://i.imgur.com/mHVwSU8.png" torch_ = "https://i.imgur.com/GYdWkb0.png" torch_2 = "https://i.imgur.com/GYdWkb0.png" glow1 = "https://i.imgur.com/qlN7awe.png" glow_1 = "https://i.imgur.com/qlN7awe.png" glow2 = "https://i.imgur.com/bCji6HU.png" glow3 = "https://i.imgur.com/GHc47CQ.png" glow4 = "https://i.imgur.com/W3OysVW.png" glow5 = "https://i.imgur.com/EajKgg3.png" door = "https://i.imgur.com/MwjexQO.png" os_glows = [glow1, glow2, glow3, glow4, glow5] cena = Cena(wall) window = Elemento(window_, style=dict(left=0, top=-50, width="420px", height="600px", overflow="hidden")) window.img.style = dict(position="relative", left="-200px") window2 = Elemento(window_2, style=dict(left=540, top=-45, width="420px", height="590px", overflow="hidden")) window2.img.style = dict(position="relative", right="-230px") torch = Elemento(torch_,
def mostra(self, tit="", txt="", act=None, **kwargs): kwargs = kwargs if kwargs else self.kwargs act = act if act else lambda *_: None self.elt = Popup.POP.popup self.cena.elt <= self.elt Popup.POP.esconde = self.esconde Popup.POP.mostra(act, tit=tit, txt=txt, **kwargs) def vai(self, ev=NoEv()): # self.elt = Popup.POP.popup ev.stopPropagation() self.cena.elt <= Popup.POP.popup self.mostra(self.tit, self.txt, act=self.esconde) return False if __name__ == "__main__": from _spy.vitollino.main import Cena, Elemento def mostra(op="YY"): cao.elt.title =op Texto(predio, f"escolheu {op}").vai() PREDIO= "https://i.imgur.com/K7xS3Oa.jpg" Doggie = "https://i.imgur.com/1YbsNfD.png" predio = Cena(PREDIO) cao = Elemento(Doggie, cena=predio) predio.vai() a = Texto(predio, "oi", foi=mostra , A="ee", B="uu") a.vai()
.. versionadded:: 20.07 Descreva o que você adicionou no código. """ from _spy.vitollino.main import Cena, INVENTARIO, STYLE from random import choice STYLE["width"] = 840 STYLE["height"] = 550 TABULEIRO = "http://www.infcross.com.br/mestrado/tabuleiro.jpg" BOTAO = "https://imgur.com/oC9lAgW" DADO_1 = "http://infcross.com.br/mestrado/dado%1.png" tabuleiro = Cena(TABULEIRO) tabuleiro.vai() dado_1 = Cena(DADO_1) dado_1.vai() """def cena_principal(): inicio = Cena(img=tabuleiro) inicio_e = Elemento (img = botao, tit="Gravidade", style = dict(left= 70,top=170, width=1150, height=550,bottom=100)) lado1 = Cena(img=tabuleiro, direita =inicio) inicio_e.entra(inicio) inicio.vai()
def __init__(self): self.castelo = Cena(CASTELO)
def __init__(self): self.ENTRADA_ADM = Cena(porta_adm) self.ADM = Cena(sala_adm) self.ADM2 = Cena(sala_adm) self.ADM3 = Cena(sala_adm) self.COMPUTADOR = Cena(computador) self.COMPUTADOR2 = Cena(computador) self.MAPA = Cena(mapa) self.PORTA1 = Elemento(porta, tit="Abra a porta", w=200, h=400, x=460, y=70, cena=self.ENTRADA_ADM) self.PASTA_FECHADA = Elemento(pasta_confidencial, tit="Abra a pasta", w=50, h=20, x=380, y=400, cena=self.ADM) self.BONECA1 = Elemento( imagem_boneca2, tit="Hipátia", w=300, h=400, x=100, y=240, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.ENTRADA_ADM) self.BONECA2 = Elemento( imagem_boneca2, tit="Hipátia", w=300, h=400, x=100, y=240, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.ADM) self.BONECA3 = Elemento( imagem_boneca2, tit="Hipátia", w=300, h=400, x=100, y=240, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.ADM2) self.BONECA4 = Elemento( imagem_boneca2, tit="Hipátia", w=300, h=400, x=100, y=240, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.ADM3) self.SENHA = Elemento( coordenadas, tit="Coordenada", w=500, h=264, x=240, y=140, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.COMPUTADOR) self.SENHA2 = Elemento( coordenadas_rj, tit="Coordenada", w=500, h=264, x=240, y=140, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.COMPUTADOR2) self.mini_mapa = Elemento( mapa, tit="Mini Mapa", w=100, h=50, x=240, y=140, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.COMPUTADOR2) self.BIBLIOTECA = Elemento( click_biblioteca, tit="CLICK", w=55, h=58, x=610, y=300, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.MAPA) self.CABANA = Elemento( click_cabana, tit="CLICK", w=55, h=58, x=250, y=500, # ou x=eixo_x, y=eixo_y, w=largura, h=altura cena=self.MAPA) self.PASTA_ABERTA = Elemento(pasta, tit="pasta", w=700, h=450, x=100, y=100, cena=self.ADM2) self.PASTA_ABERTA2 = Elemento(pasta, tit="pasta", w=700, h=450, x=100, y=100, cena=self.ADM3) self.CARTA = Elemento(carta, tit="carta", w=300, h=200, x=480, y=240, cena=self.ADM2) self.CARTA_ABERTA = Elemento(carta_aberta, tit="carta", w=300, h=450, x=480, y=100, cena=self.ADM3) self.JORNAL = Elemento(jornal, tit="Jornal", w=350, h=300, x=50, y=150, cena=self.ADM2) self.JORNAL2 = Elemento(jornal, tit="Jornal", w=350, h=300, x=50, y=150, cena=self.ADM3) self.SENHA_PC = Elemento(senha, tit="SEGUIR", w=100, h=40, x=570, y=350, cena=self.ADM3) self.PORTA1.elt.bind("click", self.abre_porta) self.PASTA_FECHADA.elt.bind("click", self.abre_pasta) self.SENHA_PC.elt.bind("click", self.botao_seguir) self.SENHA.elt.bind("click", self.desafio4) self.mini_mapa.elt.bind("click", self.abre_mapa) self.CARTA.elt.bind("click", self.abre_carta) self.CABANA.elt.bind("click", self.chama_sala) self.texto_1 = Texto( self.ENTRADA_ADM, txt= 'Parabéns, Hipátia! Você conseguiu escapar. Entre na diretoria da biblioteca para mais informações' ) self.texto_2 = Texto(self.ADM, txt='Encontre a pasta confidencial.') self.texto_3 = Texto( self.ADM2, txt= "Após ler as informações, Hipátia percebeu que havia uma carta. Clique para descobrir o que esta escrito." ) self.texto_4 = Texto( self.ADM3, txt= "Descubra o código e anote-o. Hipátia precisará dele para seu próximo passo." ) self.texto_5 = Texto(self.COMPUTADOR, txt="Insira o código descoberto na última etapa.") self.texto_6 = Texto(self.MAPA, txt="Vá até a cabana.")
def criarsalas(): a_leste = Cena(img=A_LESTE) aa_leste = Cena(img=AA_LESTE) a_leste.meio = aa_leste aaa_leste = Cena(img=AAA_LESTE) aa_leste.meio = aaa_leste aaaa_leste = Cena(img=AAAA_LESTE) aaa_leste.meio = aaaa_leste b_leste = Cena(img=B_LESTE) aaaa_leste.meio = b_leste b_norte = Cena(img=B_NORTE) b_sul = Cena(img=B_SUL, esquerda=b_leste) b_norte.direita = b_leste b_leste.direita = b_sul b_leste.esquerda = b_norte c_leste= Cena(img=C_LESTE) b_leste.meio = c_leste c_norte = Cena(img=C_NORTE) c_sul = Cena(img=C_SUL, esquerda=c_leste) c_oeste = Cena(img=C_OESTE, esquerda=c_sul, direita=c_norte, meio=b_sul) c_norte.direita = c_leste c_norte.esquerda = c_oeste c_leste.direita = c_sul c_leste.esquerda = c_norte c_sul.direita = c_oeste d_sul = Cena(img=D_SUL) c_leste.meio = d_sul bau = Elemento(img=TRANSPARENTE, tit="bau misterioso", style=dict(left=150, top=160, width=60, height=30)) bau.entra(c_leste) cbau = Texto(c_leste, "A morte estÃÂÂÂá prÃÂÂÂóxima") #inv.bota(bau, "bau", vai.vai) bau.vai = cbau.vai d_norte = Cena(img=D_NORTE) d_leste = Cena(img=D_LESTE, esquerda=d_norte, direita=d_sul) d_oeste = Cena(img=D_OESTE, esquerda=d_sul, direita=d_norte) d_norte.direita = d_leste d_norte.esquerda = d_oeste d_norte.meio = c_norte d_norte.direita = d_leste d_norte.esquerda = d_oeste d_sul.direita = d_oeste d_sul.esquerda = d_leste h_sul = Cena(img=H_SUL) d_sul.meio = h_sul h_norte = Cena(img=H_NORTE) h_leste = Cena(img=H_LESTE, direita=h_sul, esquerda=h_norte) h_oeste = Cena(img=H_OESTE, esquerda=h_sul, direita=h_norte) h_norte.direita = h_leste h_norte.esquerda = h_oeste h_sul.direita = h_oeste h_sul.esquerda = h_leste h_norte.meio = d_norte i_leste = Cena(img=I_LESTE) h_leste.meio = i_leste chave = Elemento(img=CHAVE, tit="chave", style=dict(left=200, top=180, width=30, height=15)) chave.entra(h_leste) cchave = Texto(h_leste, "NÃÂÂÂão sei o que abre") chave.vai = cchave.vai sangue = Elemento(img=TRANSPARENTE, tit="sangue", style=dict(left=80, top=230, width=25, height=15)) sangue.entra(h_sul) vai = Texto(h_sul, "Nossa, quanto sangue") sangue.vai = vai.vai espada = Elemento(img=TRANSPARENTE, tit="espada", style=dict(left=0, top=60, width=70, height=200)) espada.entra(h_leste) vai = Texto(h_leste, "A espada foi criada no ano I a.C. e ÃÂÂÂé uma ÃÂÂÂótima arma para causar ferimentos") espada.vai = vai.vai i_oeste = Cena(img=I_OESTE) i_norte = Cena(img=I_NORTE, direita = i_leste, esquerda = i_oeste) i_sul = Cena(img=I_SUL, direita = i_oeste, esquerda = i_leste) i_oeste.direita = i_norte i_oeste.esquerda = i_sul i_leste.direita = i_sul i_leste.esquerda = i_norte j_leste = Cena(img=J_LESTE) i_leste.meio = j_leste i_oeste.meio = h_oeste folhangue = Elemento(img=FOLHANGUE, tit="papel", style=dict(left=100, top=200, width=40, height=25)) folhangue.entra(i_leste) vai = Texto(i_leste, "As manchas de sangue impedem de ler tudo! PorÃÂÂÂém vocÃÂÂÂê consegue ler 'SOCORRO! AlguÃÂÂÂém...'") folhangue.vai = vai.vai j_oeste = Cena(img=J_OESTE) j_norte = Cena(img=J_NORTE, direita = j_leste, esquerda = j_oeste) j_sul = Cena(img=J_SUL, direita = j_oeste, esquerda = j_leste) j_oeste.direita = j_norte j_oeste.esquerda = j_sul j_leste.direita = j_sul j_leste.esquerda = j_norte j_oeste.meio = i_oeste e_norte = Cena(img=E_NORTE) j_norte.meio = e_norte k_leste = Cena(img=K_LESTE) j_leste.meio = k_leste saidabloq = Elemento(img=TRANSPARENTE, tit="saida bloqueada", style=dict(left=100, top=100, width=150, height=200)) saidabloq.entra(j_sul) vai = Texto(j_sul, "Esta saÃÂÂÂÃÂÂÂda estÃÂÂÂá bloqueada") saidabloq.vai = vai.vai e_oeste = Cena(img=E_OESTE, direita=e_norte) e_leste = Cena(img=E_LESTE, esquerda=e_norte) e_sul = Cena(img=E_SUL, esquerda=e_leste, direita=e_oeste) e_oeste.esquerda = e_sul e_leste.direita = e_sul e_norte.direita = e_leste e_norte.esquerda = e_oeste e_sul.meio = j_sul carta = Elemento(img=CARTA, tit="carta", style=dict(left=200, top=115, width=50, height=10)) carta.entra(e_oeste) vai = Texto(e_oeste, "A vida nÃÂÂÂão ÃÂÂÂé boa mais. NÃÂÂÂão hÃÂÂÂá esperanÃÂÂÂça. Adeus, mundo cruel!") carta.vai = vai.vai k_oeste = Cena(img=K_OESTE) k_sul = Cena(img=K_SUL, esquerda=k_leste, direita=k_oeste) k_norte = Cena(img=K_NORTE, esquerda=k_oeste, direita=k_leste) k_oeste.direita = k_norte k_oeste.esquerda = k_sul k_leste.direita = k_sul k_leste.esquerda = k_norte k_oeste.meio = j_oeste l_leste = Cena(img=L_LESTE) k_leste.meio = l_leste pano = Elemento(img=PANO, tit="pano", style=dict(left=170, top=230, width=40, height=10)) pano.entra(k_norte) vai = Texto(k_norte, "O pano estÃÂÂÂá cheio de sangue") pano.vai = vai.vai a_leste.vai()