Deprecated: The behavior of unparenthesized expressions containing both '.' and '+'/'-' will change in PHP 8: '+'/'-' will take a higher precedence in /home/iano/public_html/tpforums-vb5/forum/includes/class_core.php on line 5842

PHP Warning: Use of undefined constant MYSQL_NUM - assumed 'MYSQL_NUM' (this will throw an Error in a future version of PHP) in ..../includes/init.php on line 165

PHP Warning: Use of undefined constant MYSQL_ASSOC - assumed 'MYSQL_ASSOC' (this will throw an Error in a future version of PHP) in ..../includes/init.php on line 165

PHP Warning: Use of undefined constant MYSQL_BOTH - assumed 'MYSQL_BOTH' (this will throw an Error in a future version of PHP) in ..../includes/init.php on line 165

PHP Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in ..../includes/functions_navigation.php on line 588

PHP Warning: "continue" targeting switch is equivalent to "break". Did you mean to use "continue 2"? in ..../includes/functions_navigation.php on line 612

PHP Warning: Use of undefined constant misc - assumed 'misc' (this will throw an Error in a future version of PHP) in ..../global.php(29) : eval()'d code(6) : eval()'d code on line 1

PHP Warning: Use of undefined constant index - assumed 'index' (this will throw an Error in a future version of PHP) in ..../global.php(29) : eval()'d code(6) : eval()'d code on line 1

PHP Warning: Use of undefined constant misc - assumed 'misc' (this will throw an Error in a future version of PHP) in ..../includes/class_bootstrap.php(1422) : eval()'d code(4) : eval()'d code on line 1

PHP Warning: Use of undefined constant index - assumed 'index' (this will throw an Error in a future version of PHP) in ..../includes/class_bootstrap.php(1422) : eval()'d code(4) : eval()'d code on line 1

PHP Warning: Use of undefined constant onlinestatusphrase - assumed 'onlinestatusphrase' (this will throw an Error in a future version of PHP) in ..../includes/class_core.php(4684) : eval()'d code on line 6

PHP Warning: Use of undefined constant onlinestatusphrase - assumed 'onlinestatusphrase' (this will throw an Error in a future version of PHP) in ..../includes/class_core.php(4684) : eval()'d code on line 6

PHP Warning: Use of undefined constant onlinestatusphrase - assumed 'onlinestatusphrase' (this will throw an Error in a future version of PHP) in ..../includes/class_core.php(4684) : eval()'d code on line 6

PHP Warning: Use of undefined constant onlinestatusphrase - assumed 'onlinestatusphrase' (this will throw an Error in a future version of PHP) in ..../includes/class_core.php(4684) : eval()'d code on line 6

PHP Warning: Use of undefined constant onlinestatusphrase - assumed 'onlinestatusphrase' (this will throw an Error in a future version of PHP) in ..../includes/class_core.php(4684) : eval()'d code on line 6

PHP Warning: Use of undefined constant onlinestatusphrase - assumed 'onlinestatusphrase' (this will throw an Error in a future version of PHP) in ..../includes/class_core.php(4684) : eval()'d code on line 6

PHP Warning: Use of undefined constant onlinestatusphrase - assumed 'onlinestatusphrase' (this will throw an Error in a future version of PHP) in ..../includes/class_core.php(4684) : eval()'d code on line 6

PHP Warning: Use of undefined constant onlinestatusphrase - assumed 'onlinestatusphrase' (this will throw an Error in a future version of PHP) in ..../includes/class_core.php(4684) : eval()'d code on line 6

PHP Warning: Use of undefined constant onlinestatusphrase - assumed 'onlinestatusphrase' (this will throw an Error in a future version of PHP) in ..../includes/class_core.php(4684) : eval()'d code on line 6

PHP Warning: Use of undefined constant onlinestatusphrase - assumed 'onlinestatusphrase' (this will throw an Error in a future version of PHP) in ..../includes/class_core.php(4684) : eval()'d code on line 6
Battle List Problem
Page 1 of 2 12 LastLast
Results 1 to 10 of 11

Thread: Battle List Problem

  1. #1

    Battle List Problem

    Hello I have a big problem in my battle list, because i have refresh list. when monsters aren't on screen application not delete with list, Why?

    [code=delphi]var
    i : integer ;
    x : string;
    begin
    memo1.Clear;
    memo2.clear;
    memo3.Clear;
    memo4.clear;
    memo5.Clear;
    for i := 1 to 250 do
    if memReadstring(Bl_start + i*168 +4) <> '' then
    memo2.lines.add(memReadstring(Bl_start + i*168 +4));
    for i := 1 to 250 do
    if (Readmeminteger(Bl_start + i*168)) >= 1 then
    memo1.Lines.add(inttostr(Readmeminteger(Bl_start + i*168)));
    for i := 1 to 250 do

    if (Readmeminteger(Bl_start + i*168)) >= 1 then
    memo3.lines.add(inttostr(Readmeminteger(Bl_start + i*168+36)));
    for i := 1 to 250 do

    if (Readmeminteger(Bl_start + i*168)) >= 1 then
    memo4.lines.add(inttostr(Readmeminteger(Bl_start + i*168+40)));
    for i := 1 to 250 do

    if (Readmeminteger(Bl_start + i*168)) >= 1 then
    memo5.lines.add(inttostr(Readmeminteger(Bl_start + i*168+44)));

    end;
    [/code]

  2. #2
    Senior Member
    Join Date
    Mar 2008
    Location
    Poland
    Posts
    176

    RE: Battle List Problem

    First use one loop from 0
    Second not all monsters on bl are on screen
    Third you need check if monster z = your z and check is monster on screen like that
    Code:
    abx:= my_abs(player.x - monster_x);
    aby:= My_abs(player.y - monster_y);
    IF (abx <= 7) and (aby <= 5) then begin
    ...
    end;

  3. #3

    RE: Battle List Problem

    Look for image in Attachment I was next to house and i dont see people.

  4. #4
    Super Moderator
    Join Date
    May 2007
    Posts
    1,191

    RE: Battle List Problem

    http://code.google.com/p/tibiaapi/source/browse/trunk/tibiaapi/Addresses/Creature.cs#22

  5. #5

    RE: Battle List Problem

    I have good adress.

  6. #6
    Senior Member
    Join Date
    Mar 2008
    Location
    Poland
    Posts
    176

    RE: Battle List Problem

    Did you readed my post?

  7. #7

    RE: Battle List Problem

    How i can write it there? I dont know because it's my fifth day with Tibia-Delphi ;p

  8. #8
    Senior Member
    Join Date
    Nov 2009
    Posts
    320

    RE: Battle List Problem

    Quote Originally Posted by matigi12
    Look for image in Attachment I was next to house and i dont see people.
    Monster / Players / NPC's will still appear in your battlelist....
    It's normal..
    You just need to check if the Creature HP > 0, if is on the same floor and if THE X and Y positions are near...
    Simple XD
    oi amiguinhos

  9. #9

    RE: Battle List Problem

    Looks again. This is again.
    It's not work because tibia save in memory they position;/

  10. #10
    Super Moderator
    Join Date
    May 2007
    Posts
    1,191

    RE: Battle List Problem

    Quote Originally Posted by Blaster_89
    http://code.google.com/p/tibiaapi/source/browse/trunk/tibiaapi/Addresses/Creature.cs#22
    Again, use this offset to display VISIBLE creatures/players/NPCs, you can further filter the results by comparing creature.z to player.z

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •