1. Updated Resource Submission Rules: All model & skin resource submissions must now include an in-game screenshot. This is to help speed up the moderation process and to show how the model and/or texture looks like from the in-game camera.
    Dismiss Notice
  2. DID YOU KNOW - That you can unlock new rank icons by posting on the forums or winning contests? Click here to customize your rank or read our User Rank Policy to see a list of ranks that you can unlock. Have you won a contest and still havn't received your rank award? Then please contact the administration.
    Dismiss Notice
  3. We have recently started the 16th edition of the Mini Mapping Contest. The theme is mini RPG. Do check it out and have fun.
    Dismiss Notice
  4. Dismiss Notice
  5. The Highway to Hell has been laid open. Come along and participate in the 5th Special Effect Contest.
    Dismiss Notice
  6. Check out the Staff job openings thread.
    Dismiss Notice
Dismiss Notice
60,000 passwords have been reset on July 8, 2019. If you cannot login, read this.

Detect the closest doodat

Discussion in 'World Editor Help Zone' started by Visimirsit, Jul 10, 2010.

  1. Visimirsit

    Visimirsit

    Joined:
    Aug 28, 2009
    Messages:
    52
    Resources:
    0
    Resources:
    0
    Can wold edditor detect the closest doodat?? If you know how pplease tell me if you can. (please no vJass. vJass is the last thing, if it is impossible with gui, then vJass) I wolud love to make a tleleport trigger where you press an arrow key and you move to the closest doodat (invisible).
     
  2. Rushhour2

    Rushhour2

    Joined:
    Apr 30, 2010
    Messages:
    14
    Resources:
    0
    Resources:
    0
    First of all: If you mean "destructables" and not "doodads", then yes: It can be done.

    So you need to do the following:

    • Set ClosestRange=99999999
    • Set ClosestDestr=No destructable
    • Destructable - Pick every destructable in Region/Circle and do:
      • Set Temp_Real=Distance between Destructable and your point/whatever.
      • if Temp_Real < ClosestRange then
        • Set ClosestRange=Temp_Real
        • Set ClosestDestr= Picked Destructable
      • endif

    freehanded
     
  3. -SoulBurn

    -SoulBurn

    Joined:
    Jun 26, 2010
    Messages:
    507
    Resources:
    0
    Resources:
    0
    If you mean doodads, like props and etc, i'm afraid you can't. But you can create a destructible with your prop model and make it invulnerable.
     
  4. Visimirsit

    Visimirsit

    Joined:
    Aug 28, 2009
    Messages:
    52
    Resources:
    0
    Resources:
    0
    ty. this is just what i was looking for :) awesome. +rep