User Tag List

Results 1 to 7 of 7

Thread: EW_Brang sprites.

  1. #1
    Octorok Archangel's Avatar
    Join Date
    Apr 2008
    Age
    34
    Posts
    362
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    1,732
    Level
    13
    vBActivity - Bars
    Lv. Percent
    94.69%

    Wink EW_Brang sprites.

    Code:
    import "std.zh"
    int ewbrangsprite = 100; //Replace that number with sprite ID.
    
    global script EW_Brang{
    	void run(){
    		while(true){
    			for(int count = 1; count <= Screen->NumEWeapons(); count++){
    				eweapon test = Screen->LoadEWeapon(count);
    				if(test->ID == 131) test->UseSprite(ewbrangsprite);
    			}
    			Waitframe();
    		}
    	}
    }
    Have you gotten sick of those Goriyas using the same boomerang Link has by default? Well this script replaces that sprite with a custom one you choose.

    To implement it. You first need to make the sprite, write down the ID of the sprite. And replace the number 100 in line 2 with the ID of whatever sprite you want to use for the EW_Brang.

    Thanks to Joe123 for helping me figure out the method of going by doing this.
    -Archangel-
    Keeping the ZC Developers busy with heavy beta testing skills and experimentation is what I do best. May ZC be bug free!

    You should seriously check advmath.zh out if you use ZC.

  2. #2
    &&
    ZC Developer
    Joe123's Avatar
    Join Date
    Sep 2006
    Age
    32
    Posts
    3,061
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    7,303
    Level
    26
    vBActivity - Bars
    Lv. Percent
    8.7%

    Re: EW_Brang sprites.

    Please replace that 255 with 'Screen->NumEWeapons()'

  3. #3
    Octorok Archangel's Avatar
    Join Date
    Apr 2008
    Age
    34
    Posts
    362
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    1,732
    Level
    13
    vBActivity - Bars
    Lv. Percent
    94.69%

    Re: EW_Brang sprites.

    Quote Originally Posted by Joe123 View Post
    Please replace that 255 with 'Screen->NumEWeapons()'
    Yeah, that would probably work better anyways.
    -Archangel-
    Keeping the ZC Developers busy with heavy beta testing skills and experimentation is what I do best. May ZC be bug free!

    You should seriously check advmath.zh out if you use ZC.

  4. #4
    &&
    ZC Developer
    Joe123's Avatar
    Join Date
    Sep 2006
    Age
    32
    Posts
    3,061
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    7,303
    Level
    26
    vBActivity - Bars
    Lv. Percent
    8.7%

    Re: EW_Brang sprites.

    It's not that it would work better (or at least, it wouldn't appear to).
    It'd just stop you from checking through about 250 non-existent EWeapons every single frame, which isn't a great idea.

  5. #5
    Octorok Archangel's Avatar
    Join Date
    Apr 2008
    Age
    34
    Posts
    362
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    1,732
    Level
    13
    vBActivity - Bars
    Lv. Percent
    94.69%

    Re: EW_Brang sprites.



    Say what? It's 255 last time I checked, it's the max that it checks, but the idea of using Screen->NumEWeapon would make much sense.
    -Archangel-
    Keeping the ZC Developers busy with heavy beta testing skills and experimentation is what I do best. May ZC be bug free!

    You should seriously check advmath.zh out if you use ZC.

  6. #6
    Lynel
    ZC Developer
    pkmnfrk's Avatar
    Join Date
    Jan 2004
    Location
    Toronto
    Age
    37
    Posts
    1,248
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    3,142
    Level
    18
    vBActivity - Bars
    Lv. Percent
    10.49%

    Re: EW_Brang sprites.

    Yes, 255 total. But, at most, 6-8 would be on screen at once (in normal circumstances), and maybe 3 will be goriyas? Yeah.

    Anyway, anything to reduce the running time of the script by 2 orders of magnitude is a good thing.
    Tale of the Cave - a web comic - Updates Monday, Wednesday, Friday
    ZC Tutorials - Tutorials and Script Library - Updated July 30, 2008
    ZeldaGuard - Corruption in my save files? It's more likely than you think!
    I do script requests!

  7. #7
    &&
    ZC Developer
    Joe123's Avatar
    Join Date
    Sep 2006
    Age
    32
    Posts
    3,061
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    7,303
    Level
    26
    vBActivity - Bars
    Lv. Percent
    8.7%

    Re: EW_Brang sprites.

    Well yes, and not trying to check the ID attribute of an unassigned pointer.

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
About us
Armageddon Games is a game development group founded in 1997. We are extremely passionate about our work and our inspirations are mostly drawn from games of the 8-bit and 16-bit era.
Social