Solved Get monster spawner on creature spawn event

Discussion in 'Plugin Development' started by padili, Jun 21, 2014.

Thread Status:
Not open for further replies.
  1. Offline

    padili

    Any way to get it? I want to access it's metadata to spawn a custom mob from config file.
     
  2. padili
    There's no good way to get it, but I guess you could loop through the nearby blocks and look for a monster spawner, though there might be more than 1 around so the possibility of it returning wrong spawner is high.
     
    padili likes this.
  3. Offline

    padili

    Really? And how about setting the metaData of any mob spawned by the spawner?
     
  4. Offline

    RawCode

    1) Download cbukkit source (with all related libs)
    2) Download notepad++
    3) Use spawner spawn creature and similar keywords for seaching over cbukkit source files
    3) Find source with name MobSpa*****

    4) Navigate to section that actually place mob to world

    5) now you have answer
     
  5. Offline

    padili

    I don't want to do it using craftbukkit or nms just using bukkit!
     
  6. Offline

    RawCode

    then no hope for you. padili
     
  7. Offline

    padili

    Can't be impossible?? A very important thing missing in bukkit api??
     
  8. Offline

    RawCode

    nothing missing, you just don't want to learn, do what i stated and we will continue padili
     
  9. Offline

    padili

    How can I search the keywords in all of the files, using the grep command?? My computer doesn't run notepad++

    Yeah and what should I do with with this? https://github.com/Bukkit/CraftBukk...et/minecraft/server/SpawnerCreature.java#L240, normally you write answers to a thread instead of making a quiz!

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jun 9, 2016
  10. Offline

    Garris0n

    To be fair, it's something that really should be in the API.
     
  11. Offline

    padili

    Yeah he just needs attention, however, is there any other way to spawn special mobs from config in certain areas (instead of doing it using mob spawners) ?
     
  12. Offline

    RawCode

    padili
    I never spoonfeed, you must provide valid proof of own work.
    Your current proof of work is not valid, read carefully my posts, especially ones you simply ignored.
    Just opening first class you found wont work.

    Garris0n
    Sadly TS (just like majority of this forum) does not want to learn, but i still willing to teach anyone who want.
    Including teaching about how to fork and post pull requirests. (actually this is waste of time)
    How to mod core classes. (and get your threads locked)
    How to reinstrument live classes with unsafe. (actually there is no way to teach this, especially if subject dont know how to install programs)
     
  13. Offline

    fireblast709

    RawCode perhaps you should take a look in the javadocs yourself before giving them advanced advice.
    padili Assist 's idea should work fine, afaik dungeons cannot generate inside each other, the shortest radius should give you the correct spawner even if there are two close to each other.
    One thing I like to add is to check for the spawn reason, to make sure it was spawned by a spawner
     
    padili likes this.
  14. Offline

    RawCode

    fireblast709
    You also shoud read and follow my post.
    Your answer have nothing with how it actually implemented by cbukkit.
     
  15. Offline

    xTigerRebornx

    RawCode A recommendation since the OP cant use Notepad++ for some reason:
    GitHub has a very powerful search function as well, I found (what I believe) what should/could be modified to support this using the search function and the CB GitHub repo.
     
  16. Offline

    fireblast709

    RawCode because he asked for an implementation that relies solely on Bukkit. No need to go through any cb code for this
     
  17. Offline

    RawCode

    fireblast709
    follow my instructions and then we will talk.
     
  18. Offline

    padili

    May be the bad way, but however thanks for help!
     
  19. Offline

    RawCode

    same again, dont want to learn and seek for spoonfeeding, this is sad...
     
  20. At which point was he requesting to be spoonfed? And why should you try to attempt something more advanced if there is an easier option?
     
  21. Offline

    fireblast709

    RawCode Get off your high horse and then I am willing to talk. I was merely replying to the OPs requests.

    [addition] I started a conversation if you wish to continue this in pm, so please don't continue here
     
Thread Status:
Not open for further replies.

Share This Page