Results 1 to 9 of 9
  1. #1
    edub18's Avatar
    Join Date
    Aug 2010
    Gender
    male
    Location
    Germany
    Posts
    146
    Reputation
    10
    Thanks
    12
    My Mood
    Bored

    Moving Objectives

    Hey guys,
    im trying to make an objective (yellow dot on map) follow a player but i cant get it working... It stays where i spawn it ...

    Code:
    doTrackPlayer()
    {
      self endon("disconnect");
      self endon("death");
                            
      self.tracker = spawn("script_model", self.origin);
      self.tracker doTrack();                             
    }
    
    doTrack()
    {
    	self endon ( "disconnect" ); 
    	self endon ( "death" ); 
    
    		curObjID = maps\mp\gametypes\_gameobjects::getNextObjID();	
    		name = precacheShader("compass_waypoint_panic");	
    		objective_add(curObjID, "invisible", (0,0,0));
    		objective_position(curObjID, self.origin);
    		objective_state(curObjID, "active");
    		objective_team(curObjID, self.team);
    		objective_icon(curObjID, name);
    		self.objIdFriendly = curObjID;
    		
    		while(1)
    		{
          objective_position(self.objIdFriendly, self.origin);
          wait 0.1;
        }
    }

  2. #2
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,675
    Reputation
    905
    Thanks
    18,543
    My Mood
    Angelic
    Because you just set the position and don't make it move.

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  3. #3
    edub18's Avatar
    Join Date
    Aug 2010
    Gender
    male
    Location
    Germany
    Posts
    146
    Reputation
    10
    Thanks
    12
    My Mood
    Bored
    uh ok o.˘ and how to move it?
    i thought settings its position is moving?

  4. #4
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,675
    Reputation
    905
    Thanks
    18,543
    My Mood
    Angelic
    Quote Originally Posted by Vanoq View Post
    uh ok o.˘ and how to move it?
    i thought settings its position is moving?
    Want to know what you did wrong?
    Code:
    doTrack()
    {
    	self endon ( "disconnect" ); 
    	self endon ( "death" ); 
    
    		curObjID = maps\mp\gametypes\_gameobjects::getNextObjID();	
    		name = precacheShader("compass_waypoint_panic");	
    		objective_add(curObjID, "invisible", (0,0,0));
    		objective_position(curObjID, self.origin);
    		objective_state(curObjID, "active");
    		objective_team(curObjID, self.team);
    		objective_icon(curObjID, name);
    		self.objIdFriendly = curObjID;
    		
    		while(1)
    		{
          objective_position(self.objIdFriendly, self.origin);
          wait 0.1;
        }
    }
    Do that you.
    (I guess you have copied this one..)

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  5. #5
    edub18's Avatar
    Join Date
    Aug 2010
    Gender
    male
    Location
    Germany
    Posts
    146
    Reputation
    10
    Thanks
    12
    My Mood
    Bored
    Why do you quote my code? o.˘

  6. #6
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,675
    Reputation
    905
    Thanks
    18,543
    My Mood
    Angelic
    Its what you gone use
    Its fixed now.

    Have fun.
    (You did wrong. So just the 1 thread)

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  7. The Following User Says Thank You to Jorndel For This Useful Post:

    pyrozombie (07-08-2011)

  8. #7
    edub18's Avatar
    Join Date
    Aug 2010
    Gender
    male
    Location
    Germany
    Posts
    146
    Reputation
    10
    Thanks
    12
    My Mood
    Bored
    Thanks but it doesnt work ^.^
    No yellow dot appears on the minimap

    // EDIT: K i got it working. Thank you
    Last edited by edub18; 07-08-2011 at 07:17 AM.

  9. #8
    Jorndel's Avatar
    Join Date
    Jul 2010
    Gender
    male
    Location
    Norway
    Posts
    8,675
    Reputation
    905
    Thanks
    18,543
    My Mood
    Angelic
    No problem.

     
    Contributor 01.27.2012 - N/A
    Donator 07-17-2012 - Current
    Editor/Manager 12-16-12 - N/A
    Minion 01-10-2013 - 07.17.13
    Former Staff 09-20-2012 - 01-10-2013 / 07-17-2013 - Current
    Cocksucker 20-04-2013 - N/A

  10. The Following User Says Thank You to Jorndel For This Useful Post:

    pyrozombie (07-08-2011)

  11. #9
    Moto's Avatar
    Join Date
    Dec 2008
    Gender
    male
    Location
    Bay Area, CA
    Posts
    13,057
    Reputation
    707
    Thanks
    13,439
    My Mood
    Blah
    /solved
    /closed

    Jorndel, thank you for helping.



Similar Threads

  1. move objectives???
    By kuyakyloo in forum Call of Duty Modern Warfare 2 GSC Modding Help/Discussion
    Replies: 2
    Last Post: 03-17-2011, 10:06 AM
  2. CPS as a moving object
    By HeroicSlayr in forum Call of Duty Modern Warfare 2 Help
    Replies: 8
    Last Post: 08-18-2010, 09:33 AM
  3. Replies: 10
    Last Post: 03-06-2007, 05:52 PM
  4. Nick Burns + Wang! MOVE!!!
    By arunforce in forum General
    Replies: 4
    Last Post: 02-22-2007, 11:11 PM
  5. MPGH being moved again...
    By Dave84311 in forum News & Announcements
    Replies: 0
    Last Post: 01-31-2007, 02:07 PM