• 🏆 Texturing Contest #33 is OPEN! Contestants must re-texture a SD unit model found in-game (Warcraft 3 Classic), recreating the unit into a peaceful NPC version. 🔗Click here to enter!
  • It's time for the first HD Modeling Contest of 2024. Join the theme discussion for Hive's HD Modeling Contest #6! Click here to post your idea!

Apply Here Thread

Status
Not open for further replies.
Level 9
Joined
Jul 18, 2005
Messages
319
HT try using this if your looping thourgh structs

JASS:
//==============================================================================
//  Collections -- STRUCT STORAGE SYSTEM BY COHADAR -- v2.1
//==============================================================================
//
//  PURPOUSE:
//      * Storing structs for spells that require variable number of data
//      * Great for algorithms that need random access.
//      * Able to create 100% MUI spells.
//
//  REFERENCE:
//      * This system was inspired by java Collection interface
//        [url]http://java.sun.com/docs/books/tutorial/collections/interfaces/collection.html[/url]
//        [url]http://java.sun.com/javase/6/docs/api/java/util/Iterator.html[/url]
//
//  DETAILS:
//      * Collections are now implemented as static-only classes
//        this removes limitations in number of elements from version 1.3
//
//      * Main purpouse of collections is fast storing and removing of structs,
//        Structs in Collection are NOT ordered in any way.
//        Structs can change place inside collection at any time.
//        Iterators are the only safe way to access collection elements.
//
//      * Do NOT create or destoy Collection or Iterator classes,
//        there is no point to that because all operations are static
//
//      * Each Collection has exactly one iterator (for performanse reasons)
//
//      * Collections are implemented with global array that is created
//        by calling a collection macro inside a trigger scope.
//        you can have 8191 structs stored in one collection.
//
//      * Since collections are just a wrapper around of global array $X$_buff
//        some people will feel the need to inline collection calls.
//        Please do NOT do this unless it is really necessary for performanse.
//        This will almost never be the case, collections are extremely fast.
//
//
//  HOW TO USE:
//      * For a trigger to use collections it MUST be inside a scope.
//        At the beginning of scope insert this macro call
//        //! runtextmacro COLLECTION("A")
//
//      * This will create global array and other fields and methods 
//        needed for collection manipulation
//
//      * To prevent lag when collections are first used put this into spells InitTrigger
//        call CollectionA.init()   // This is optional
//
//---------------------------------------------------------------------------
//  BASIC LOOP:  (data is your custom struct)
//---------------------------------------------------------------------------
//
//        call IteratorA.reset()   // <-- positions iterator at the beginning of collection
//        loop
//            exitwhen IteratorA.noNext()
//            set data = IteratorA.next()
//    
//            if SomeExitCondition(data)
//			     call data.destroy()	
//               call IteratorA.remove()
//		      else
//               -- Process data --
//            endif		
//        endloop
//
//---------------------------------------------------------------------------
//  LIST OF FUNCTIONS:  (all methods are static)
//---------------------------------------------------------------------------
//      struct CollectionX
//          .init()
//          .isEmpty() -> boolean
//          .size() -> integer
//          .contains(integer) -> boolean
//          .add(integer) -> boolean
//          .remove(integer) -> boolean
//          .clear()
//      endstruct
//
//      struct IteratorX
//          .reset()
//          .noNext() -> boolean
//          .next() -> integer
//          .remove()
//      endstruct
//---------------------------------------------------------------------------
//
//  HOW TO IMPORT:
//       * Just create a trigger named Collections
//       * convert it to text and replace the whole trigger text with this one
//
//==============================================================================


globals
    integer MAX_COLLECTION_SIZE = 8191
endglobals

//! textmacro COLLECTION takes X

// Do NOT use this fields directly
globals
    // Collection fields
    private integer array $X$_buff
    private integer $X$_size = 0
    
    // Iterator fields
    private integer  $X$_index = -1               
    private boolean  $X$_removeOK = false
endglobals

//==============================================================================
private struct Collection$X$
    
    // prevents the lag by forcing wc3 to allocate whole array at once
    static method init takes nothing returns nothing
        set $X$_buff[MAX_COLLECTION_SIZE-1] = 1
    endmethod
    
    // checks if collection is empty
    static method isEmpty takes nothing returns boolean
        return $X$_size <= 0
    endmethod
    
    // returns the current size of collection
    static method size takes nothing returns integer
        return $X$_size
    endmethod
    
    // checks is element e is inside collection
    static method contains takes integer e returns boolean
        local integer i = 0
        loop
            exitwhen i >= $X$_size
            if e == $X$_buff[i] then
                return true
            endif
            set i = i + 1
        endloop
        return false
    endmethod
    
    // adds element e into collection
    static method add takes integer e returns boolean
        if $X$_size < MAX_COLLECTION_SIZE then
            set $X$_buff[$X$_size] = e
            set $X$_size = $X$_size + 1
            return true
        else
            call BJDebugMsg("|C00FF0000ERROR: Collection$X$ overflow in scope " + SCOPE_PREFIX)
            return false
        endif
    endmethod
    
    // removes first element that matches e from collection
    static method remove takes integer e returns boolean
        local integer i = 0
        loop
            exitwhen i >= $X$_size
            if e == $X$_buff[i] then
                set $X$_size = $X$_size - 1
                set $X$_buff[i] = $X$_buff[$X$_size]
                return true
            endif
            set i = i + 1
        endloop
        return false        
    endmethod
    
    // removes ALL elements from collection
    static method clear takes nothing returns nothing
        set $X$_size = 0
    endmethod
    
endstruct

//==============================================================================
private struct Iterator$X$
    // Use before any looping to reset iterator to the beginning of collection
    static method reset takes nothing returns nothing
        set $X$_index = -1
        set $X$_removeOK = false
    endmethod
    
    // returns true if at the end of collection
    static method noNext takes nothing returns boolean
        return $X$_index >= ($X$_size-1)
    endmethod
    
    // Not safe operation, use only if noNext returns false
    static method next takes nothing returns integer
        set $X$_index = $X$_index + 1
        set $X$_removeOK = true
        return $X$_buff[$X$_index]
    endmethod
    
    //This method can be called only once per call to next.
    static method remove takes nothing returns nothing
        if $X$_removeOK then
            set $X$_size = $X$_size - 1
            set $X$_buff[$X$_index] = $X$_buff[$X$_size]    
            set $X$_index = $X$_index - 1
            set $X$_removeOK = false
        else
            call BJDebugMsg("|c00FF0000ERROR: Iterator$X$ attempted invalid remove in scope" + SCOPE_PREFIX)
        endif
    endmethod
    
endstruct

//! endtextmacro

Thts how I got my Web spell workin

-Av3n
 
Level 25
Joined
Mar 25, 2004
Messages
4,880
Try skimming through the 250 lines of code and look for some small things that may have caused the problem. Perhaps a type-o or something. Sure it'll take a bit to recheck, but it will be worth while in the end once you fix it and it works properly. :)
~Craka_J
 
Level 9
Joined
Jul 18, 2005
Messages
319
I encpuntered the worsest bug with the first few spells i done... Some of them might need to have unnecessary coding because of it...
Oh Craka I should of asked on msn but i didn't should I make Block and Parry custom for equipment effects? My WoW friend told me tht block and parry chance is based on equipment if not I'll set them on 5%

-Av3n
 
Level 6
Joined
Mar 12, 2007
Messages
225
I'm really interested in being a part of this awsome project. I am a terrainer and I also play WoW (TAUREN RULE!!!) so I could help you out with that kind of stuff. I am a little busy right now to post some pictures, but I will post some later, just thought I would let you know I am very interested. Here is my terrain showcase for a map I am making though :
http://www.hiveworkshop.com/forums/showthread.php?t=39228

-thesandwraith
 
Level 25
Joined
Mar 25, 2004
Messages
4,880
Not looking for a terrain of your... caliber, lets say.
And he did not answer any question because there was no question to be answered. All TheSandWraith said was he wanted to let us know that he was interested in becoming a terrain for Wc3:WoW pretty much. I saw no questions in that entire post, therefor, Gilles must have been mistaken.
~Craka_J
 
Level 34
Joined
Sep 6, 2006
Messages
8,873
Craka was right, he didn't, I was mistaken. I said that because I knew Craka wouldn't want a terrainer of SnadWraith's "caliber". If you look at previous posts, I asked a while ago and was politely denied. It would take someone pretty special for Craka to want them (HernanG for example)
 
Level 25
Joined
Mar 25, 2004
Messages
4,880
Here's a list of people I'd accept as terrains most likely:
  • [Death] (If he was still an active mod guy for Wc3)
  • Born2Modificate
  • xXm0rPH3usXx
  • Beam
  • PheoniX_VII
  • Zurg
  • ~Void~
And those are the people just off the top of my head!

Oh and no hard feelings Gilles. :smile:
~Craka_J
 
Level 6
Joined
Mar 12, 2007
Messages
225
Oh, ok I get it. Ok then, thanks anyway. Just thought maybe you might need some more people. Anyway, thanks again. I guess i'll go try and get better.
 
Level 25
Joined
Mar 25, 2004
Messages
4,880
Zurg is in fact a good terrainer IMO. His terrain for CotD could have been a lot better though I believe, at least in the city. But I found his terrain for his "Broken Kingdom" map to be very good. He's great with cinematics though, I won't argue about that. Can't believe he didn't even win third place in Blizzards old cinematic contest. @_@
~Craka_J
 
Level 3
Joined
May 3, 2007
Messages
27
oops i didnt realize thsi thread existed (XD) and i made a entry for joining the team as a beta tester here is a link to the message i posted about joining http://www.hiveworkshop.com/forums/showthread.php?t=40430 as i said i want to help the team in the only way i can and i will do a very good job of it because i play wc3 atleast 5 hours a day, the only thing keeping me is that my brother also need a turn on the computer
 
Level 3
Joined
May 3, 2007
Messages
27
again i thank you buty comp got busted yesterday the scrren keeps pixalating after about 30 minutes of play and now it got worse 10 minutes of play so i think ill just buy a new computer and battle chest that way i might also be able to host :) but for now, my comp is busted
 
Level 3
Joined
May 3, 2007
Messages
27
nvm im still in the te4am i found the intervel its about 1minute to about a hour that it mbreaks last time i played i got preety good play time and i9 found alot of bugs so im still in the team
 
Level 11
Joined
Aug 4, 2007
Messages
642
I would like to be a concept artist
Old drawing i did
 

Attachments

  • anubis inverted.jpg
    anubis inverted.jpg
    29.5 KB · Views: 134
Level 34
Joined
Sep 6, 2006
Messages
8,873
Do you have a showcase? The Dragonball Z ORPG that robot_dude is working on does not have all that great of a terrain.
 
Level 25
Joined
Mar 25, 2004
Messages
4,880
The need of a concept artist is... very low. Blizzard Entertainment provides all the concept art we need to be honest.
However, we may need a concept artist in the far future when we begin designing our own PvP/PvE tier gears and so on. Perhaps you can draw a bunch and PM them to me.
~Craka_J
 
Level 25
Joined
Mar 25, 2004
Messages
4,880
Animate a peasant. The animation must be good too. Good animations keep the whole body moving, while the arms move, the rest does a slight something as well. Hopefully you know this already. If you have any exported WoW models, you can check the animations and they're very realistic because every body part moves, and not just one or two like a robot.
If I think your animated peasant is good, I'll be more than happy to recruit you!
~Craka_J
 
Level 25
Joined
Mar 25, 2004
Messages
4,880
Yeah. Just animate the Peasant doing something cool. Make sure the animations aren't clippy either, please. If you can't animate a Peasant, fine. Animate a Villager Male instead.

Animations neccessary are:
  • Waving.
  • Laughing.
  • Dancing.
  • Sitting on the ground.
  • Laying down animation.(It'd be clever to make the units tummy buldge up and down as if he's breathing to add on to realism)
  • Jumping.

You are not required to make all of those animations. Doing one or two would be fine. Although making all of them would show quality.
~Craka_J
 
Status
Not open for further replies.
Top