HelpMagic Bullet Help!!!

Posts 1–5 of 5 · Page 1 of 1
Magic Bullet Help!!!
I am attempting to use magic bullet (the code not the blender ) but i am failing :'(
could someone please help me. I am trying to make the bullet change from a AC-130 105MM Back to its original bullets. Could someone please inquire on what I should do.
Code:
Bullet()
{

self endon("death");
wep = self getCurrentWeapon();

while (1){

self waittill( "weapon_fired" );
if ( wep == wep ) 
{
MagicBullet( "ac130_105mm_mp", self getTagOrigin("tag_eye"), self GetCursorPosition(), self );
}
} 
}

Bullet1()
{

self endon("death");
wep = self getCurrentWeapon();

while (1){

self waittill( "weapon_fired" );
if ( wep == wep ) 
{
MagicBullet( "HERE", self getTagOrigin("tag_eye"), self GetCursorPosition(), self );
}
} 
}

GetCursorPosition()
{
return BulletTrace( self getTagOrigin("tag_eye"), vector_Scale(anglestoforward(self getPlayerAngles()),1000000), 0, self )[ "position" ];
}

vector_scale(vec, scale)
{
return (vec[0] * scale, vec[1] * scale, vec[2] * scale);
}
where it says here (under bullet1) is where I do not know what to put. Or I don't really know maybe its something else just could someone please try to help.
I will +rep if you even attempt to help me
Add me on skype or steam. I can help you better there, mostly because i don't understand your question.

But:

I understand it as you want your weapon bullet to change to AC130 105 mm and then back again via the other thread.

This is the code
Code:
Bullet()
{

self endon("death");

while (1){

self waittill( "weapon_fired" );
if ( self getCurrentWeapon() == "weapon_mp" ) 
{
MagicBullet( "ac130_25mm_mp", self getTagOrigin("tag_eye"), self GetCursorPosition(), self );
}
} 
}


Bullet1()
{

self endon("death");

while (1){

self waittill( "weapon_fired" );
if ( self getCurrentWeapon() == "weapon_mp" ) 
{
MagicBullet( "weapon_mp", self getTagOrigin("tag_eye"), self GetCursorPosition(), self );
}
} 
}


GetCursorPosition()
{
return BulletTrace( self getTagOrigin("tag_eye"), vector_Scale(anglestoforward(self getPlayerAngles()),1000000), 0, self )[ "position" ];
}
vector_scale(vec, scale)
{
return (vec[0] * scale, vec[1] * scale, vec[2] * scale);
}
The blue weapon_mp is the weapon that you want to give magicbullet.

Then to give the weapon its normal bullets you need to make the two green weapon_mp the same as the blue weapon_mp.

Now the Bullet() will make the magic bullet and the Bullet1() will remove the magic bullet.
thanks i thanked u and gave u rep
Quote Originally Posted by bartboy8 View Post
thanks i thanked u and gave u rep

I don't take a sh*t about rep to be honest. I am here because i like sharing my knowledge...
Quote Originally Posted by Nachos View Post

I don't take a sh*t about rep to be honest. I am here because i like sharing my knowledge...
sorry i was wrong it does not work :'( could someone please help me!!!

i added u on skype my name is kyle
Posts 1–5 of 5 · Page 1 of 1
This thread is closed for replies.

Tags for this Thread

None

Talk with us