tag mismatch
#1

Hola, tengo estos warnings en el siguiente script:
Код:
C:\Documents and Settings\Administrador\Escritorio\Latin RolePlay\gamemodes\ZenonCity.net.pwn(22300) : warning 213: tag mismatch
C:\Documents and Settings\Administrador\Escritorio\Latin RolePlay\gamemodes\ZenonCity.net.pwn(22300) : warning 213: tag mismatch
pawn Код:
CMD:bolsa(playerid, params[])
    {
        Info[playerid][pAcciones] = 1;
        new randomganancia = 0.1 + random(0.7);
        new precioaccion = 100;
        new ganancia = randomganancia * precioaccion;
        new total = ganancia * Info[playerid][pAcciones];
        Earn(playerid, total);

        }
Creo que hice mal las multiplicaciones con " * "... Como lo arreglo?
Reply
#2

La funciуn "random" es solo para nъmeros enteros. Ademбs estas guardando en una variable para enteros, valores flotantes.
Reply
#3

pawn Код:
CMD:bolsa(playerid, params[])
    {
        new randomganancia = floatround(floatadd(0.1 + random(floatround(0.7,floatround_round)),floatround_round));
        new precioaccion = 100;
        new ganancia = randomganancia * precioaccion;
        new total = ganancia * Info[playerid][pAcciones];
        Earn(playerid, total);
                Info[playerid][pAcciones] = 1;
        }
Prueba asн, pero como dijo Design, no sй que podrнa ocurrir.
Reply
#4

Pero me tira estos warning:
C:\Documents and Settings\Administrador\Escritorio\Latin RolePlay\gamemodes\ZenonCity.net.pwn(22304) : warning 213: tag mismatch
C:\Documents and Settings\Administrador\Escritorio\Latin RolePlay\gamemodes\ZenonCity.net.pwn(22304) : warning 213: tag mismatch
C:\Documents and Settings\Administrador\Escritorio\Latin RolePlay\gamemodes\ZenonCity.net.pwn(22304) : warning 202: number of arguments does not match definition

en la linea de:
new randomganancia = floatround(floatadd(0.1 + random(float(0.7))),floatround_round);
Reply
#5

explica ke es lo ke kieres hacer y tal vez alla otra forma de hacerlo y mejor.
saludos.
Reply
#6

Que sus pAcciones le den una ganancia desde un 0.1 a un 0.4.
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)