onilink_ Modérateur
Messages : 9180 Localisation : Montpellier Projet Actuel : Planet Centauri
OniDev
| Sujet: Probleme room_add_tile Lun 31 Mai 2010 - 0:09 | |
| Voila j'ai un petit soucis avec room_tile_add Quand je cree unne room avec room_add et que j'y place des tiles ils ont un blending aléatoire avec background0 le back blanc par defaut - Code:
-
r = room_add() room_set_width(r,256) room_set_height(r,192) room_tile_add(r, background0, 16, 0, 16, 16, 0, 0, 0) room_tile_add(r, background0, 16, 0, 16, 16, 0, 16, 0) room_tile_add(r, background0, 16, 0, 16, 16, 16, 0, 0) room_tile_add(r, background0, 16, 0, 16, 16, 16, 16, 0) room_goto(r)
Pourquoi les tuiles ne s'affichent pas blanches ? Vous avez une idée (bien que j'ai trouvé une truc pour contourner le probleme mais bon, c'est quand meme un truc louche ce blending) EDIT1 j'ai essayé ça et s'a ne fonctionne pas x) pour infos draw_set_color(c_white) room_set_background_color(r, c_white, 1) room_tile_add_ext(r, background0, 0, 0, 16, 16, 32, 32, 0, 1, 1, 1) Pour ceux que ça interresse j'ai contourner le probleme en ajoutant un code de depart a ma room et c'est ce code qui cree les tiles. Le probleme c'est qu'il s'execute a chaque changement de la room... |
|
Johny Wessmuller Utilisateur confirmé: Rang *
Messages : 233
| Sujet: Re: Probleme room_add_tile Lun 31 Mai 2010 - 9:19 | |
| Il parait que c'est un bug http://gmc.yoyogames.com/index.php?showtopic=358475http://gmc.yoyogames.com/index.php?showtopic=330299Il y a des réponse à ton probleme qq part en anglais dedans "You probably have to add tiles to the current room with tile_add when you visit the room, or put a room creation code to set the blending color of all tiles in the room correctly." "Yes. It is a bug with GM. After adding the tiles, you need to set their blend color to white again. It screws with the color." "The id that room_tile_add returns is only meaningful in that room. So, you have to scan the room to find every tile (using tile_layer_find) when you're in that room. You could set a room creation code to run the code to scan tiles, or even easier, set up the room creation code to add tiles with tile_add." _________________ C'est bon je suis passé tu peux mettre résolu
|
|
onilink_ Modérateur
Messages : 9180 Localisation : Montpellier Projet Actuel : Planet Centauri
OniDev
| Sujet: Re: Probleme room_add_tile Lun 31 Mai 2010 - 10:12 | |
| je vois finalement c'est ce que j'avais fait pour contourner le probleme merci d'avoir repondu, au moins je suis fixé |
|
Topaze22 *Excellent utilisateur*
Messages : 6213 Localisation : Sur la Lune Projet Actuel : Projet HELLO/TOPAZE22 Mario Bros World
| Sujet: Re: Probleme room_add_tile Mer 2 Juin 2010 - 11:07 | |
| Je ne connaissais pas ce soucis que je risque de rencontrer. Merci les gards ! _________________ Topique pour le Projet Hello Mario en préparation. Sorti du topique lorsque la première démo sera disponible.
|
|
Contenu sponsorisé
| Sujet: Re: Probleme room_add_tile | |
| |
|