obetuno 431 Posted April 25, 2013 Preciso de uma tela de login que permita mudar aleatoriamente as backgrounds cada vez que se abre o jogo... Alguém sabe programar isto ? Deve ser coisa boba... PS: As backgrounds são 7 ! E elas estão com seus respectivos ficheiros SUB: EXEMPLO: - login.jpg e login.sub (principal) - bg1.jpg e login1.sub - bg2.jpg e login2.sub - bg3.jpg e login3.sub e por ai vai... Me ajudar e dou http://cyber-gamers.org/public/style_emoticons/default/451960.gif Além de uma dedicatória ! ;) Share this post Link to post Share on other sites
ĦČŢÖŞ 8 Posted April 25, 2013 Algo simples e interessante! Uma boa idéia que vai ajudar muita gente. Share this post Link to post Share on other sites
тнєℓιƒє 488 Posted April 25, 2013 Aqui tens: Descompactas o locale_xx . Depois vais a locale/ xx / ui/ loginwindow.py Altera: { "name" : "bg2", "type" : "expanded_image", "x" : 0, "y" : 0, "x_scale" : float(SCREEN_WIDTH) / 1024.0, "y_scale" : float(SCREEN_HEIGHT) / 768.0, "image" : "locale/pt/ui/login.sub", }, Por: { "name" : "bg2", "type" : "expanded_image", "x" : 0, "y" : 0, "x_scale" : float(SCREEN_WIDTH) / 1024.0, "y_scale" : float(SCREEN_HEIGHT) / 768.0, "delay" : 6, "images" : ( "locale/pt/ui/login/1.sub", "locale/pt/ui/login/2.sub", "locale/pt/ui/login/3.sub", "locale/pt/ui/login/4.sub", "locale/pt/ui/login/5.sub", "locale/pt/ui/login/6.sub", "locale/pt/ui/login/7.sub", "locale/pt/ui/login/8.sub", ) }, PS: Não tenho a certeza se no name é bg1 ou bg2. 2 obetuno and Origin. reacted to this Share this post Link to post Share on other sites
obetuno 431 Posted April 25, 2013 Vou testar... Ja vos digo. Share this post Link to post Share on other sites
тнєℓιƒє 488 Posted April 25, 2013 Vou testar... Ja vos digo. em prencipios não vai funcionar. Esqueci-me de uma coisa: { "name" : "bg2", "type" : "expanded_image", "x" : 0, "y" : 0, "type" : "ani_image", "x_scale" : float(SCREEN_WIDTH) / 1024.0, "y_scale" : float(SCREEN_HEIGHT) / 768.0, "delay" : 6, "images" : ( "locale/loginscreen/ani/1.sub", "locale/loginscreen/ani/2.sub", "locale/loginscreen/ani/3.sub", "locale/loginscreen/ani/4.sub", "locale/loginscreen/ani/5.sub", "locale/loginscreen/ani/6.sub", "locale/loginscreen/ani/7.sub", "locale/loginscreen/ani/8.sub", ) }, 1 obetuno reacted to this Share this post Link to post Share on other sites
obetuno 431 Posted April 25, 2013 Que http://cyber-gamers.org/public/style_emoticons/default/lol.gif ! funciona sim... Mas o intervalo de tempo para alterar está curto demais ! kkkkk Será se é no "delay" para mudar ? Vou tentar acá. Share this post Link to post Share on other sites
тнєℓιƒє 488 Posted April 25, 2013 Que http://cyber-gamers.org/public/style_emoticons/default/lol.gif ! funciona sim... Mas o intervalo de tempo para alterar está curto demais ! kkkkk Será se é no "delay" para mudar ? Vou tentar acá. Sim, é no delay, Quanto mais aumentas, mais tempo ele demora a rodar ^^. 1 Origin. reacted to this Share this post Link to post Share on other sites
obetuno 431 Posted April 25, 2013 Muito Obrigado ! Me ajudou demais. http://cyber-gamers.org/public/style_emoticons/default/451960.gif por isto... O meu terminou assim: { "name" : "bg2", "type" : "expanded_image", "x" : 0, "y" : 0, "type" : "ani_image", "x_scale" : float(SCREEN_WIDTH) / 1024.0, "y_scale" : float(SCREEN_HEIGHT) / 768.0, "delay" : 200, "images" : ( "locale/de/ui/login1.sub", "locale/de/ui/login2.sub", "locale/de/ui/login3.sub", "locale/de/ui/login4.sub", "locale/de/ui/login5.sub", "locale/de/ui/login6.sub", ) }, Tópico resolvido. Share this post Link to post Share on other sites
тнєℓιƒє 488 Posted April 25, 2013 Muito Obrigado ! Me ajudou demais. http://cyber-gamers.org/public/style_emoticons/default/451960.gif por isto... O meu terminou assim: Tópico resolvido. De nada. 1 Origin. reacted to this Share this post Link to post Share on other sites
quenii 981 Posted April 25, 2013 Resolvido, fechado Share this post Link to post Share on other sites