Announcement

Collapse
No announcement yet.

How do i add new weapons and ammo?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • #31
    It worked, thank you.
    I am like a stray dog, lost in between what I do and what I should do.
    But sometimes, all you need is Imagination.

    Comment


    • #32
      Sssg

      Now thats what we need. A proton accelerator shotgun made with a infinitely looping feed of projectiles. Frustrated that that ogre over there got that lucky shot with the Gl? Just use 138867547725599 grains of 12 gauge buckshot and create a black hole to end it all.

      Im in the mood to try and create a new model for Quake for the first time in awhile. I could make a shotgun with 9 barrels on it just for your test mod.
      But i need to know if your going to be working with any extra frames or if its the standard from shot2.mdl.


      Well now since i know for sure the tools for MD3 and IQM are no longer functional for 3ds i have to try and export my crap to blender. But FBX, OBJ, and even COLLADA keep killing my anims.
      RAAAAAGE
      Last edited by M_Luminoth; 08-17-2014, 09:52 AM. Reason: Update with picture
      We primarily speak english here...
      Is english a second language for you? If you are having trouble getting your point across please confront me on the forum or send me a PM. German is a second language for me and i will be able to provide the most help to those from deutschland.

      Comment


      • #33
        I think the QuakeForge project has some really good MDL im-and exporters for Blender.

        The QuakeForge Project: Downloads

        Don't mess with those other formats. Either use MDL or make the model entirely in Blender and export it to IQM (Darkplaces/FTE support this.)
        Scout's Journey
        Rune of Earth Magic

        Comment


        • #34
          Originally posted by golden_boy View Post
          I think the QuakeForge project has some really good MDL im-and exporters for Blender.

          The QuakeForge Project: Downloads

          Don't mess with those other formats. Either use MDL or make the model entirely in Blender and export it to IQM (Darkplaces/FTE support this.)
          IQM in blender is giving me grief at the moment. It wont hold my anim's.
          and the MD3 is writing to the wrong texture file, but it has anim's.
          Ill figure it out one day how to use IQM, as i want to make my own game in DP.
          But for now i have to thank you to that pointer to the MDL format tools. We need more q1 MDL tools for more programs. +rep
          We primarily speak english here...
          Is english a second language for you? If you are having trouble getting your point across please confront me on the forum or send me a PM. German is a second language for me and i will be able to provide the most help to those from deutschland.

          Comment


          • #35
            YEEEEAAA.zip

            I know im doubleposting but i have new content.
            12 gauge rape is ready.
            YEEEAAA.zip
            Attached Files
            We primarily speak english here...
            Is english a second language for you? If you are having trouble getting your point across please confront me on the forum or send me a PM. German is a second language for me and i will be able to provide the most help to those from deutschland.

            Comment


            • #36
              Originally posted by M_Luminoth View Post
              I know im doubleposting but i have new content.
              12 gauge rape is ready.
              YEEEAAA.zip
              I tried this out. The model isn't well defined in terms of making out any detail and it's probably too wide. Also the kick back goes much too far back. The sound is a bit loud for my tastes but not a bad addition. It would be cool if the barrel rotated for each double buck shot. Like to the other side? Or is it suppose to be like firing 4 barrels at once?

              Comment


              • #37
                Originally posted by PrimalLove View Post
                I tried this out. The model isn't well defined in terms of making out any detail and it's probably too wide. Also the kick back goes much too far back. The sound is a bit loud for my tastes but not a bad addition. It would be cool if the barrel rotated for each double buck shot. Like to the other side? Or is it suppose to be like firing 4 barrels at once?
                I made the model in about 10 minutes. Im actually impressed that i got it to import without the plugins i used to use. I had to use blender. (i only had 7 frames to work with btw)
                It isnt supposed to be refined. If this was an official mod instead of just test work id probably download the source code for progs and work on that a little more.

                The idea here wasnt to make a functional model for the mod (yet)
                i just wanted to make the supershotgun as ridiculous as possible.

                If i can get the IQM exporter to work in blender we actually might have somthing to work with.
                I also have some plans to add my own personal models to quake at some point.
                I have some fixes for the Axe to make it work better with new textures from PrimeEvil.
                And i have a badass karambit model i made, but it has to be properly linked to the fist model.
                Last edited by M_Luminoth; 08-18-2014, 06:23 AM.
                We primarily speak english here...
                Is english a second language for you? If you are having trouble getting your point across please confront me on the forum or send me a PM. German is a second language for me and i will be able to provide the most help to those from deutschland.

                Comment


                • #38
                  @M_Luminoth

                  Ah I see. Carry on.

                  Comment


                  • #39
                    I figured that this was pretty relevant to this thread, so instead of starting my own, I figured I would ask here.

                    I am adding a new weapon to the game and am getting an error when trying to compile. The error is occurring in my change weapons function. The error is: weapons.qc: 1359: error: Unkown Value "else".

                    Code:
                    ============
                    W_ChangeWeapon
                    
                    ============
                    */
                    void() W_ChangeWeapon =
                    {
                    	local	float	it, am, fl;
                    	
                    	it = self.items;
                    	am = 0;
                    	
                    	if (self.impulse == 1)
                    	{
                    		fl = IT_AXE;
                    	}
                    	else if (self.impulse == 2)
                    	{
                    		self.enemy = world;
                    		self.currentammo = 6;
                    		if (self.currentammo > self.ammo_shells)
                    			self.currentammo = self.ammo_shells;
                    			
                    		fl = IT_SHOTGUN;
                    		if (self.ammo_shells < 1)
                    			am = 1;
                    	}
                    	else if (self.impulse == 3)
                    	{					
                    			if(self.weapon == IT_SUPER_SHOTGUN) [COLOR="red"] // THE NEW CODE[/COLOR]
                    			{
                    					fl = IT_RSHOT;
                    					if (self.ammo_shells < 2)
                    					am = 1;
                    			}
                    			else
                    			{
                    			fl = IT_SUPER_SHOTGUN;
                    			if (self.ammo_shells < 2)
                    			am = 1;
                    	}		
                    	else if (self.impulse == 4)  [COLOR="Red"]// HERE IS WHERE THE ERROR IS HAPPENING[/COLOR]
                    	{
                    		fl = IT_NAILGUN;
                    		if (self.ammo_nails < 1)
                    			am = 1;
                    	}
                    	else if (self.impulse == 5)
                    	{
                    		fl = IT_SUPER_NAILGUN;
                    		if (self.ammo_nails < 2)
                    			am = 1;
                    	}
                    	else if (self.impulse == 6)
                    	{
                    		fl = IT_GRENADE_LAUNCHER;
                    		if (self.ammo_rockets < 1) {
                    			am = 1;
                    		} else {
                    			self.cnt = 0;
                    			self.currentammo = 3;
                    			if (self.currentammo > self.ammo_rockets)
                    				self.currentammo = self.ammo_rockets;
                    		}
                    	}
                    	else if (self.impulse == 7)
                    	{
                    		fl = IT_ROCKET_LAUNCHER;
                    		if (self.ammo_rockets < 1)
                    			am = 1;
                    	}
                    	else if (self.impulse == 8)
                    	{
                    		fl = IT_LIGHTNING;
                    		if (self.ammo_cells < 1)
                    			am = 1;
                    	}
                    
                    	self.impulse = 0;
                    	
                    	if (!(self.items & fl))
                    	{	// don't have the weapon or the ammo
                    		sprint (self, "no weapon.\n");
                    		return;
                    	}
                    	
                    	if (am)
                    	{	// don't have the ammo
                    		sprint (self, "not enough ammo.\n");
                    		return;
                    	}
                    
                    //
                    // set weapon, set ammo
                    //
                    	self.weapon = fl;		
                    	W_SetCurrentAmmo ();
                    };
                    
                    /*
                    Am trying to add a new weapon that will be toggle-able by pressing "3" on the keyboard to share a spot with the ssg.
                    Really not sure what to do here. I fixed my other errors, but this one I can't figure out. Thanks.

                    Comment


                    • #40
                      pro tip: use consistant indentation.
                      the issue would be obvious if you did.
                      Some Game Thing

                      Comment


                      • #41
                        Originally posted by Spike View Post
                        pro tip: use consistant indentation.
                        the issue would be obvious if you did.
                        Yeah, I feel like an idjit. Shortly after, I posted, I got it working. Fixed the problem code like this:

                        Code:
                        	else if (self.impulse == 2)
                        	{
                        		self.enemy = world;
                        		self.currentammo = 6;
                        		if (self.currentammo > self.ammo_shells)
                        			self.currentammo = self.ammo_shells;
                        			
                        		fl = IT_SHOTGUN;
                        		if (self.ammo_shells < 1)
                        			am = 1;
                        	}
                        [COLOR="Red"]	else if (self.impulse == 3)
                        	{					
                        		if(self.weapon == IT_SUPER_SHOTGUN)
                        			{
                        			fl = IT_RSHOT;
                        			}
                        			else
                        			{
                        			fl = IT_SUPER_SHOTGUN;
                        			}
                        			if (self.ammo_shells < 2)
                        			am = 1;
                        	}		[/COLOR]
                        	else if (self.impulse == 4)
                        	{
                        		fl = IT_NAILGUN;
                        		if (self.ammo_nails < 1)
                        			am = 1;
                        	}
                        I do have another issue though, My weapon seems to be using 3 ammo instead of two. Not sure why this is. Which function do I have to double check? The W_fire seems to be fine.

                        Here is the fire code:
                        Code:
                        void() W_FireRC =
                        {
                        	local vector dir, back;
                        
                        	if (self.ammo_shells < 2)
                        	{
                        		self.weapon = W_BestWeapon ();
                        		W_SetCurrentAmmo ();
                        		return;
                        	}
                        		
                        	if (self.weaponframe < 2)
                        		sound (self ,CHAN_WEAPON, "weapons/rshotgn.wav", 1, ATTN_NORM);	
                        
                        	self.punchangle_x = -4;
                        
                        	self.currentammo = self.ammo_shells = self.ammo_shells - 1;
                        	makevectors(self.v_angle);
                        	dir = v_forward; //aim (self, 100000);
                        	
                        	FireBullets (30, dir, '0.20 0.15 0');
                        	
                        	back = dir * 35 * 5;
                        	self.velocity = self.velocity - back;
                        	self.avelocity = vectoangles (self.velocity);
                        };
                        If I change the "self.currentammo = self.ammo_shells = self.ammo_shells - 1;" to " self.currentammo = self.ammo_shells = self.ammo_shells - 2;" it actually uses more than two shells.

                        Is there another area/function that can control the amount of ammo used that I'm not aware of or may have accidentally tweaked?
                        Last edited by Legend; 08-18-2014, 03:31 PM.

                        Comment

                        Working...
                        X