Tibia Brasil

www.tibiabrazil-blog.blogspot.com


    Atack tal Monstro com tal magia

    Compartilhe
    avatar
    ADM Altair Junior
    Admin

    Mensagens : 73
    Data de inscrição : 13/05/2009
    Idade : 25

    Atack tal Monstro com tal magia

    Mensagem  ADM Altair Junior em Dom Mar 14, 2010 1:34 pm

    const
    frigo = ['banshee'];
    flam = ['ancient scarab'];
    tera = ['cyclops'];
    vis = ['acolyte of the cult'];
    mort = ['black knight'];
    useWand = 0 //se estiver com Wand 1 sem wand 0

    function GetExoriType(Crea: TCreature): String;
    begin
    Result := '';

    for z := Low(frigo) to High(frigo) do
    begin
    if AnsiLowerCase(Crea.Name) = AnsiLowerCase(frigo[z]) then
    Result := 'exori frigo';
    end;

    for z := Low(flam) to High(flam) do
    begin
    if AnsiLowerCase(Crea.Name) = AnsiLowerCase(flam[z]) then
    Result := 'exori flam';
    end;

    for z := Low(tera) to High(tera) do
    begin
    if AnsiLowerCase(Crea.Name) = AnsiLowerCase(tera[z]) then
    Result := 'exori tera';
    end;

    for z := Low(vis) to High(vis) do
    begin
    if AnsiLowerCase(Crea.Name) = AnsiLowerCase(vis[z]) then
    Result := 'exori vis';
    end;

    for z := Low(mort) to High(mort) do
    begin
    if AnsiLowerCase(Crea.Name) = AnsiLowerCase(mort[z]) then
    Result := 'exori mort';
    end;

    end;

    function GetCreatureByID(ID: integer): TCreature;
    var
    x: integer;
    begin
    Result := nil;
    for x := 0 to Creatures.Count - 1 do
    begin
    if x >= Creatures.Count then Break;
    if Creatures.Creature[x].ID = ID then
    begin
    Result := Creatures.Creature[x];
    Exit;
    end;
    end;
    end;

    begin
    sleepTime := 1100;
    if useWand = 0 then
    sleepTime := 1000;

    while not terminated do
    begin
    updateworld;
    if Self.Attacking <> nil then
    begin
    creature := GetCreatureByID(self.attacking);
    if creature <> nil then
    begin
    exori := GetExoriType(creature);
    if exori <> '' then
    begin
    updateworld;
    if (abs(creature.x - self.x) <= 3) and (abs(creature.y - self.y) <= 3) then
    begin
    if Self.Attacking > 0 then
    if creature.visible then
    self.say(exori);
    end;
    end;
    end;
    end;
    sleep(sleepTime);
    end;
    end;

    Legenda:
    Vermelhor: Altere os nomes dos bixos a seu gosto
    Azul: 1 Para usar Wando/Rod e 0 para não usar

    Download

    Megaman9

    Mensagens : 148
    Data de inscrição : 05/11/2011

    Re: Atack tal Monstro com tal magia

    Mensagem  Megaman9 em Ter Nov 08, 2011 1:59 pm



    Pagina Ownada !!!


    Pixel lfie by zeruel[ pixellife.foro.bz/forum]

      Data/hora atual: Seg Ago 21, 2017 1:32 am