Renegade Public Forums
C&C: Renegade --> Dying since 2003™, resurrected in 2024!
Home » Renegade Discussions » Mod Forum » C++ Question
Re: C++ Question [message #340319 is a reply to message #340314] Fri, 11 July 2008 10:38 Go to previous messageGo to previous message
HeavyX101- Left is currently offline  HeavyX101- Left
Messages: 633
Registered: April 2008
Location: WindowsJail=ZipFolder
Karma:
Colonel
//Made By Ferkhat Shubladze
class presetbuildChatCommand : public ChatCommandClass {
	void Triggered(int ID,const TokenClass &Text,int ChatType) {
		GameObject *obj = Get_GameObj(ID);


char *preset = (char *)Text[1].c_str();

Vector3 position;
position = Commands->Get_Position(obj);
position.Z += 0;
position.X += (float)(5*cos(Commands->Get_Facing(Get_GameObj(ID))*(3.14 / 180)));
position.Y += (float)(5*sin(Commands->Get_Facing(Get_GameObj(ID))*(3.14 / 180))); // this is gonna be fixed soon
 {

Commands->Create_Object(preset,position);
Console_Input(StrFormat("msg WORKS!").c_str());
	Commands->Set_Facing(obj, Commands->Get_Facing(obj)-180);

 }
	}
	
};
ChatCommandRegistrant<presetbuildChatCommand> presetbuildChatCommandReg("!pbuild",CHATTYPE_ALL,1,GAMEMODE_AOW);


This account is no longer being active.

[Updated on: Fri, 11 July 2008 10:39]

Report message to a moderator

 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Steath effect skin
Next Topic: DUB Hummer
Goto Forum:
  


Current Time: Fri Dec 27 05:44:33 MST 2024

Total time taken to generate the page: 0.00891 seconds