Guest Stressed Posted June 16, 2008 Report Share Posted June 16, 2008 Hey people,Seeing sixteen tons didn't give a list of the methodes availlable on EM4 I propose to make a list of them here and explain what they do... I am sure that can help a lot.The best way right now is I think to find them on the 20scripts they made for the 20missions...Of course you can help me by replying and I will edit this first post to be kept updated.SystemSystem::Log(const char * msg,...) : print to the log file the msg. Use the printf syntax.GameGameObjectList Game::GetGameObjects() : ???GameObjectList Game::GetGameObjects(const char * name) : ???MissionMission::PlayHint(const char * msg) : Show the hint called msgAudioAudio::SetMusicLevel(float f) : Change the sound level of the music to f.Audio::PlaySoundtrack("1", 0.0f) : ???Audio::PlaySample(const char* filepath) : Play the audio sample at the filepath (eg "mod:Audio/FX/misc/newobjective.wav")int Audio::PlaySample3D(const char * filepath, Vector position, bool ???) : Start playing the filepath sound at the position and return the id.Audio::StopSample(int i) : Stop the sample with id iCameraCamera::DisableCameraXYMovement()Camera::DisableCameraZMovement()Camera::DisableCameraRotation()ScriptInterfaceScriptInterface::HideRadar()ScriptInterface::HideMap()ScriptInterface::HideNavigator()ScriptInterface::HideInfoBar()ScriptInterface::HideVehicleBrowser()Classesclass GameObject { bool HasName(const char * name) : check the name of the object void Show() void Hide() ???}class GameObjectList { GameObject GetObject(int i) : return the object [i]i[/i] int GetNumObjects() : return the number of object ???}class Person { ???}class Vehicle { Vector GetPosition() : return the position of the vehicle in the map. void AddPassenger(Person* pers) : Add the [i]pers[/i] as passager ???}class Path { ???} Quote Link to comment Share on other sites More sharing options...
Hoppah Posted June 16, 2008 Report Share Posted June 16, 2008 Too much work. You didn't really explain how to actually use this in scripts. For example this:Mission::PlayHint(const char * msg) : Show the hint called msgyou need to use brackets or a constant (const char...) to make that work ingame. For example:Mission::PlayHint("Test 1234"); Quote Link to comment Share on other sites More sharing options...
Guest Stressed Posted June 16, 2008 Report Share Posted June 16, 2008 you need to use brackets or a constant (const char...) to make that work ingame. For example:Mission::PlayHint("Test 1234");I only used the prototype, what I want to do is some kind of header of their api... That really can help scripter to begin... I am sure when you script you always go to the old scripts to know how you did that or that... with this you can easily see all the possibilities and exactly know what you can or can not do"Test 123" is a const char * so with that prototype each programmer knows he can use a const char * and not a string or cstring or whatever Quote Link to comment Share on other sites More sharing options...
Guest Stressed Posted June 16, 2008 Report Share Posted June 16, 2008 Wow... ok finally that already exists... http://www.emergency4spektrum.de/index.php/Kategorie:ScriptsIt is not english, I am not speaking a word of german but I can understand the c++ on it Thank you everyone anyways..Hoppah, are you going to make a script soon for LAMod... I can maybe try to help... of course there is no garantie but there is nothing to lose Quote Link to comment Share on other sites More sharing options...