User Tag List

Results 1 to 10 of 23

Thread: Fire Rod

Hybrid View

Previous Post Previous Post   Next Post Next Post
  1. #1
    Octorok Lelouche Vi Britannia's Avatar
    Join Date
    Oct 2015
    Location
    Britannia - Area 11
    Posts
    173
    Mentioned
    9 Post(s)
    Tagged
    0 Thread(s)
    vBActivity - Stats
    Points
    1,112
    Level
    11
    vBActivity - Bars
    Lv. Percent
    46.5%
    Ok so here is the data from my first attempt.

    Code:
    const int BOLT_NOUSE = 64;//1 second pause
    const int FLIP_NO = 0;//no flipping
    const int FLIP_H = 1;//Flip Horrizontal
    const int FLIP_V = 2;//Flip Vertical
    const int FLIP_B = 3;//Rotate 180 degrees
    const int BOLTCSET_NF = 6;
    const int BOLTCSET_F = 0;
    
    item script BoltSpell //basic use a wand and cast a spell stuff
    {
    	void run(int power, int arrowSprite, int speed, int wandSprite)
    	{
    		int startX;
    		int startY;
    		lweapon l;
    		lweapon bolt;
    		startX = Link->X+8;
    		startY = Link->Y+4;
    		Link->Action = LA_ATTACKING;
    		l = NextToLink(LW_WAND,8);
    		l->Tile = wandSprite;
    		if (Link->Dir == DIR_UP)
    		{
    			l->Flip = FLIP_NO;
    		}
    		if (Link->Dir == DIR_DOWN)
    		{
    			l->Flip = FLIP_V;
    		}
    		if (Link->Dir == DIR_RIGHT)
    		{
    			l->Tile++;
    			l->Flip = FLIP_NO;
    		}
    		if (Link->Dir == DIR_LEFT)
    		{
    			l->Tile++;
    			l->Flip = FLIP_H;
    		}
    		bolt = NextToLink(LW_ARROW, 8);
    		bolt->UseSprite(arrowSprite);
    		if (Link->Dir == DIR_UP)
    		{
    			bolt->Flip = FLIP_NO;
    		}
    		if (Link->Dir == DIR_DOWN)
    		{
    			bolt->Flip = FLIP_V;
    		}
    		if (Link->Dir == DIR_RIGHT)
    		{
    			bolt->Tile++;
    			bolt->Flip = FLIP_NO;
    		}
    		if (Link->Dir == DIR_LEFT)
    		{
    			bolt->Tile++;
    			bolt->Flip = FLIP_H;
    		}
    		bolt->Damage = power;
    		bolt->Step = speed;
    		Link->ItemJinx = BOLT_NOUSE;
    	}
    }
    Problem 1: The wand is being rendered too high vertically on Link's spirte. I compared it to the sword location and it appears to be a good 6 pixels or so higher (about nose level instead of hand level). I tried reducing the Y position to +4 from +8 (line 18), but that had no visual effect at all on the placement of the sprite. How do I fix this so it looks like a normal use of the wand?

    Problem 2: Not sure if this is possible but can the damage type of the attack be changed to fire? This is supposed to be a fire rod after all. Also would like to know how to get the bolt to render an actual flame at the impact point.

    Next Steps: Currently contemplating using an advanced dark room script to make LttP style braziers. I thought it would be possible to allow the Fire Rod to light them either by using an invulnerable enemy that is invisible set on the brazier. However the thought also occurred that this would probably work better as an FFC script but I am rubbish at those currently.

    Currently for the "Next Steps" portion I am considering using the "Subpar Dark Room Script" found on Pure, unless someone could suggest a better one?
    Lost my wings and grew 8 tentacles... I've seen enough Hentai to know where this is going....

  2. #2
    The Timelord
    QDB Manager
    ZC Developer

    Join Date
    Oct 2006
    Location
    Prydon Academy
    Posts
    1,396
    Mentioned
    112 Post(s)
    Tagged
    1 Thread(s)
    vBActivity - Stats
    Points
    4,765
    Level
    21
    vBActivity - Bars
    Lv. Percent
    69.76%
    Quote Originally Posted by Lelouche Vi Britannia View Post
    Ok so here is the data from my first attempt.

    Code:
    const int BOLT_NOUSE = 64;//1 second pause
    const int FLIP_NO = 0;//no flipping
    const int FLIP_H = 1;//Flip Horrizontal
    const int FLIP_V = 2;//Flip Vertical
    const int FLIP_B = 3;//Rotate 180 degrees
    const int BOLTCSET_NF = 6;
    const int BOLTCSET_F = 0;
    
    item script BoltSpell //basic use a wand and cast a spell stuff
    {
    	void run(int power, int arrowSprite, int speed, int wandSprite)
    	{
    		int startX;
    		int startY;
    		lweapon l;
    		lweapon bolt;
    		startX = Link->X+8;
    		startY = Link->Y+4;
    		Link->Action = LA_ATTACKING;
    		l = NextToLink(LW_WAND,8);
    		l->Tile = wandSprite;
    		if (Link->Dir == DIR_UP)
    		{
    			l->Flip = FLIP_NO;
    		}
    		if (Link->Dir == DIR_DOWN)
    		{
    			l->Flip = FLIP_V;
    		}
    		if (Link->Dir == DIR_RIGHT)
    		{
    			l->Tile++;
    			l->Flip = FLIP_NO;
    		}
    		if (Link->Dir == DIR_LEFT)
    		{
    			l->Tile++;
    			l->Flip = FLIP_H;
    		}
    		bolt = NextToLink(LW_ARROW, 8);
    		bolt->UseSprite(arrowSprite);
    		if (Link->Dir == DIR_UP)
    		{
    			bolt->Flip = FLIP_NO;
    		}
    		if (Link->Dir == DIR_DOWN)
    		{
    			bolt->Flip = FLIP_V;
    		}
    		if (Link->Dir == DIR_RIGHT)
    		{
    			bolt->Tile++;
    			bolt->Flip = FLIP_NO;
    		}
    		if (Link->Dir == DIR_LEFT)
    		{
    			bolt->Tile++;
    			bolt->Flip = FLIP_H;
    		}
    		bolt->Damage = power;
    		bolt->Step = speed;
    		Link->ItemJinx = BOLT_NOUSE;
    	}
    }
    Problem 1: The wand is being rendered too high vertically on Link's spirte. I compared it to the sword location and it appears to be a good 6 pixels or so higher (about nose level instead of hand level). I tried reducing the Y position to +4 from +8 (line 18), but that had no visual effect at all on the placement of the sprite. How do I fix this so it looks like a normal use of the wand?

    Problem 2: Not sure if this is possible but can the damage type of the attack be changed to fire? This is supposed to be a fire rod after all. Also would like to know how to get the bolt to render an actual flame at the impact point.

    Next Steps: Currently contemplating using an advanced dark room script to make LttP style braziers. I thought it would be possible to allow the Fire Rod to light them either by using an invulnerable enemy that is invisible set on the brazier. However the thought also occurred that this would probably work better as an FFC script but I am rubbish at those currently.

    Currently for the "Next Steps" portion I am considering using the "Subpar Dark Room Script" found on Pure, unless someone could suggest a better one?


    In general, you want LW_SCRIPT for this, or LW_BEAM, or even LW_REFMAGIC.

    There was a recent request on Pure for this sort of thing, but I frankly do not want to do it until 2.54 is out, and I can make it both cleaner, and easier.

Thread Information

Users Browsing this Thread

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

Tags for this Thread

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