Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » !spy command help
!spy command help [message #412770] Mon, 30 November 2009 21:25 Go to next message
Distrbd21 is currently offline  Distrbd21
Messages: 743
Registered: September 2008
Karma: 0
Colonel

function OnChat(PlayerId, Type, Message, Target)

if FirstW == "!spy" then

      local iCredits = 1000


      -- |||||||||||||||||||||||||||||||||||||||||||||||||||

      sName = Get_Player_Name_By_ID(pID)

      if Get_Money(pID) > iCredits then
         Attach_Script_Once(Get_GameObj(pID), "RA_Infantry_Spy", "")
         Set_Money(pID, Get_Money(pID) - iCredits)
         InputConsole("page %s You have been made a spy.", sName)
      else
         InputConsole("page %s You need %d credits to buy a spy.", sName, iCredits)
      end

	return 1
end


What perset does this use? a sbh with the script above?


Live Your Life Not Some one Else's.| Sharing Is Caring

http://dsgaming.us/distrbd21/Distrbd21%20siggy.png

Cookie Jar

Suicide
Re: !spy command help [message #412773 is a reply to message #412770] Mon, 30 November 2009 22:11 Go to previous messageGo to next message
Hubba is currently offline  Hubba
Messages: 40
Registered: October 2009
Karma: 0
Recruit
"RA_Infantry_Spy" will make your current char invisible to base defenses. If you want to have a "shb" spy then you first have to change char into shb preset and then attach that script. Note the script will get unattached when you kill a building i think.
Re: !spy command help [message #412798 is a reply to message #412773] Tue, 01 December 2009 02:16 Go to previous messageGo to next message
Distrbd21 is currently offline  Distrbd21
Messages: 743
Registered: September 2008
Karma: 0
Colonel

Hubba wrote on Mon, 30 November 2009 23:11

"RA_Infantry_Spy" will make your current char invisible to base defenses. If you want to have a "shb" spy then you first have to change char into shb preset and then attach that script. Note the script will get unattached when you kill a building i think.

how would i add this to the script?, if i can't figure it out.


Live Your Life Not Some one Else's.| Sharing Is Caring

http://dsgaming.us/distrbd21/Distrbd21%20siggy.png

Cookie Jar

Suicide
Re: !spy command help [message #412825 is a reply to message #412770] Tue, 01 December 2009 09:06 Go to previous messageGo to next message
Hubba is currently offline  Hubba
Messages: 40
Registered: October 2009
Karma: 0
Recruit
Here:
function OnChat(PlayerId, Type, Message, Target)
	if Message == "!spy" then
		if Get_Money(PlayerId) >= 1200 then
			Set_Money(PlayerId, Get_Money(PlayerId)-1200)
			Change_Character(Get_GameObj(PlayerId),"CnC_Nod_FlameThrower_2SF")
			Attach_Script_Once(Get_GameObj(PlayerId), "RA_Infantry_Spy", "")
			InputConsole("msg %s has bought a Spy.", Get_Player_Name_By_ID(PlayerId))
		else
			InputConsole("ppage %d You have not enough money! You need 1200 credits to buy this!", PlayerId)
		end
	end
return 1
end

[Updated on: Tue, 01 December 2009 09:08]

Report message to a moderator

Re: !spy command help [message #412878 is a reply to message #412770] Tue, 01 December 2009 18:05 Go to previous message
Distrbd21 is currently offline  Distrbd21
Messages: 743
Registered: September 2008
Karma: 0
Colonel

ty ty ty
i love you


Live Your Life Not Some one Else's.| Sharing Is Caring

http://dsgaming.us/distrbd21/Distrbd21%20siggy.png

Cookie Jar

Suicide
Previous Topic: !afk command for lua
Next Topic: FTP Uploader script
Goto Forum:
  


Current Time: Sun Dec 29 17:28:04 MST 2024

Total time taken to generate the page: 0.00623 seconds