Ayuda con un pequeсo stock.
#1

pawn Код:
stock bMessage(playerid, const text[]){
    for(new line; line < 6; line ++){
        TextDrawShowForPlayer(playerid, mBox[line]);
    }
    for(new line; line < 6; line++){
        TextDrawHideForAll(mBox[line]);
        if(line < 5){
            mString[line] = mString[line+1];
            TextDrawSetString(mBox[line], mString[line]);
        }
    }
    format(mString[6], 128, "%s", text);
    TextDrawSetString(mBox[5], mString[6]);
    for(new line; line < 6; line++){
        TextDrawShowForAll(mBox[line]);
    }
}
Entonces, me mire un filterscript en samp forum, y yo quise hacer mi propia newsbox de solo 6 mensajes.. pero los textdraws se crean en la misma linea, osea me explico? los texdraws se van borrando y se van creando en la misma linea, alguien me podria ayudar..? :/
Reply
#2

pawn Код:
stock bMessage(playerid, const text[]){
    for(new line; line < 6; line ++){
        TextDrawShowForPlayer(playerid, mBox[line]);
    }
    for(new line; line < 6; line++){
        TextDrawHideForAll(mBox[line]);
        if(line < 5){
            mString[line] = mString[line+1];
            TextDrawSetString(mBox[line], mString[line]);
        }
    }
    format(mString[6], 128, "%s\n", text);
    TextDrawSetString(mBox[5], mString[6]);
    for(new line; line < 6; line++){
        TextDrawShowForAll(mBox[line]);
    }
}
Reply
#3

Al parecer no es eso :/
Reply
#4

їMe puedes pasar todo el cуdigo?

pawn Код:
stock bMessage(playerid, const text[]){
    for(new line; line < 6; line ++){
        TextDrawShowForPlayer(playerid, mBox[line]);
    }
    for(new line; line < 6; line++){
        TextDrawHideForAll(mBox[line]);
        if(line < 5){
            mString[line] = mString[line+1];
            TextDrawSetString(mBox[line], mString[line]);
        }
    }
    format(mString[5], 128, "%s", text);
    TextDrawSetString(mBox[5], mString[5]);
    for(new line; line < 6; line++){
        TextDrawShowForAll(mBox[line]);
    }
}
Reply
#5

Listo, ya lo arregle era solo que estaban mixeados los textdraws.. gracias.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)