Modding/Pikachuk Modding Engine

The Pikachuk Modding Engine is a modding engine made by Pikachuk to help making mods, this page is made to help users of the Pikachuk Modding Engine to use it

Page under construction, the page is not complete yet

Estimated release date of Pikachuk Modding Engine : 22/06/2017 - 28/06/2017

Part 1 : Setup the Pikachuk Modding Engine
1 - To start using the Pikachuk Modding Engine, drop the PME engine files directly on your current Yandere Simulator folder like this 2 - Once done, make sure to set DEBUG.txt in "YandereSimulator_Data/StreamingAssets/PikachukModEngine/DEBUG.txt" to "1" or "true" like on this image 3 - Start Yandere Simulator with ModLauncher.exe to verify that the debug log correctly appears at the top left corner of the game 4 - Start creating your mods

Part 2 : Making a mod with the Engine
To make a mod with the Pikachuk Modding Engine, you'll have need of a text editor, Notepad++ is recommanded.

To make AssetBundles, Unity 4.7.0 pro or unity 4.7.2 pro is required

Once yandere simulator will be updated to unity 5, having a pro version won't be required anymore and bundles will be possible with personnal editions

To convert audio files to ogg, audacity is recommanded

1 - Start making a file named "StartScript.PMS" in the "YandereSimulator_Data/StreamingAssets/PikachukModEngine/Scripts/PMS/" folder

(MAKE SURE IT IS NOT A .TXT ELSE IT WON'T WORK)

2 - Depending on all the scenes you'll load for the mod, create multiple scripts named

"[NameOfScene]Script.PMS" (for example "SchoolSceneScript.PMS" will automatically load when the schoolscene is loaded)

3 - To use a bundle with the engine, drop the bundle on the program named "Encrypt.exe" located in "YandereSimulator_Data/StreamingAssets/PikachukModEngine/Encrypt.exe" 

and put the generated bundle .unity3dCRYPT in the Bundles folder

4 - To use music with the engine, you must first convert the song to ogg and place it in "YandereSimulator_Data/StreamingAssets/PikachukModEngine/Assets/Music/"

5 - When your mod is finished, don't forget to put the engine in release mode (set DEBUG.txt to 0 and remove all the .PMS from the Scripts folder and keep only the .PMSCRYPT (don't forget to play the scripts in game before to allow them to be encrypted automatically or encrypt them yourself with Encrypt.exe))

Part 3 : List of Functions
This list may change A LOT because this engine will update often, be sure to often check this section to be sure to correctly use function

Informations :

a function is always written with this schema "NAMEOFFUNCTION(ARGUMENTS);" never forget the ";" else you will have script errors

float = decimal number (it allows negative values) (examples : "56" ,"85.254", "-150.68")

string = text (examples : "this is a text" "this is another text")

int = decimal number but only integer values without point

Functions : 

1 - SelectGameObject(string);

- This function selects the gameobject by its name in order to apply future functions on it,

(example : SelectGameObject(YandereChan);

there is a special way to write it to select a specific student (SelectGameObject(Student[IDOfStudent]);)

2 - LoadScene(string);

- This function loads a scene by its name, for example LoadScene(SchoolScene); will load the school scene

3 - LoadLevelAdditive(string);

- This function loads a scene without unloading the current scene, so the elements of the selected scene will be added to the current scene

4 - WaitSeconds(float);

- This function waits some seconds before loading the next function

5 - BundleLoad(string);

This function loads a bundle (WARNING : ONE BUNDLE PER SCRIPT, if you want to load a second bundle, make a second script and call the script with LoadPESScript) for example BundleLoad(CharacterBundle.unity3dCRYPT);

6 - LoadPESScript(string);

This function starts a script by its name, for example LoadPESScript(loadthecharacter); would start loadthecharacter.PMS (LoadPESScript starts a script WHILE the current script is running, so the current script will continue to load the next lines at the same time as the other script loads its lines, it allows multiple tasks at the same time)

 7- DebugLog (string);

This function writes a line in the debug log, the debug log appears on screen in debug mode and can be found in "YandereSimulator_Data/PikachukModEngineLog"

example : DebugLog(The script finished this action);

8 - ActivateObjectScripts;

This function activates all the scripts from the selected gameobject, it doesn't require any argument

9 - ActivateObject;

Activates current selected object, this function doesn't require any argument

10 - ActivateChildObjectScripts;

Activates all scripts from the child gameobjects of the current selected object

11 - DisableGameObject;

disables current selected object, this function doesn't require any argument

12 - DisableComponentObject(string);

Disable a component of the selected object by the component name

example DisableComponentObject(StudentScript);

13 - ModelReplace(string);

Replaces the rigged 3d model of the current selected object by the one from the loaded bundle

make sure your model is correctly rigged to the correct boneset of the object you want to replace

example : ModelReplace(FlanModel);

14 - SelectGameObjectInChildren(string);

if the gameobject you want to select is a child of the current selected gameobject, using this function will be faster than SelectGameObject

SelectGameObjectInChildren works the same way as SelectGameObject but searches only in child objects

15 - InstantiateObjectFromBundle(string);

Instantiates a gameobject from an assetbundle by its name and set it automatically as current selected object

example : InstantiateObjectFromBundle(house);

16 - ActivateAllChildObjects;

Activate all the child gameobjects of the selected gameobject, it's useful to activate gameobjects that are not meant to be visible, for example the secret demons from the Hell gameobject

17 - YandereHairstyle(int);

change the current yandere chan hairstyle by its ID, example : YandereHairstyle(0); will make yandere chan bald

18 - ChangeScale(float,float,float OR string);

Change the scale of the current selected object depending either on the 3 X Y and Z value or on the name of an object to get the same values

examples : ChangeScale(0.2,0.2,0.2); will set the selected object size to 0.2

ChangeScale(School); would set the selected object size to the same size as the school

19 - ChangePosition(float,float,float OR string);

Change the Position of the current selected object depending either on the 3 X Y and Z value or on the name of an object to get the same values

examples : ChangePosition(2,2,2); will set the selected object Position to 2

ChangePosition (School); would set the selected object Position to the same Position as the school

20 - ChangeRotation(float,float,float OR string);

Change the Rotation of the current selected object depending either on the 3 X Y and Z value or on the name of an object to get the same values

examples : ChangeRotation(2,2,2); will set the selected object Rotation to 2

ChangeRotation (School); would set the selected object Rotation to the same Rotation as the school

21 - ChangeLocalPosition(float,float,float OR string);

Change the Local Position of the current selected object depending either on the 3 X Y and Z value or on the name of an object to get the same values

examples : ChangeLocalPosition(2,2,2); will set the selected object Rotation to 2

ChangeLocalPosition (School); would set the selected object Local Position to the same Local Position as the school

22 - ChangeLocalRotation(float,float,float OR string);

Change the Local Rotation of the current selected object depending either on the 3 X Y and Z value or on the name of an object to get the same values

examples : ChangeLocalRotation(2,2,2); will set the selected object Rotation to 2

ChangeLocalRotation (School); would set the selected object Local Rotation to the same Local Rotation as the school

23 - ChangeParent(string);

Change the Parent object of the current selected object to the object defined in the argument

example : ChangeParent(YandereChan); would set the parent of the object to yandere chan

it's useful to not disable a specific object when we want to disable a gameobject that is a parent of this object

it can be used too to attach an object to a bone of a charactger for example on the head or the hands

24 - CopyObject(string);

Create a clone of the current selected object, give to this object the name of the string argument and select automatically this object

example : CopyObject(thecopy); will create a clone of the selected object named thecopy

25 - DontDestroyObject;

applies the DontDestroyOnLoad setting to the selected gameobject, the gameobject will still active even when a new scene is loaded

26 - LoadAllBundle;

This command loads all the bundle data from the selected bundle in memory, this is important if we want to load a scene from a bundle it can be used like this

BundleLoad(nameofbundle);

LoadAllBundle;

LoadScene(nameofscenefrombundle);

27 - ChangeMusic(string);

Change the current game music by the one of the argument by its name

example : ChangeMusic(Levan Polka); would replace the music by levan polka

this feature will probably be updated in the future to allow a second argument to chose the music we want to replace since currently it only replaces school musics and all at once except easter eggs

28 - StopTimeClock;

Stops the time of the clock, for example if in the game it is 8:05 AM, it will still 8:05 AM forever

29 - AdjustClipping(float,float);

this command is more useful when we replace the school by something really big, it allows to set the camera clipping to allow to see far objects and objects near from us

example : AdjustClipping(0.3,1000); will render objects that are 0,3 in distance near the camera and 1000 in distance far from the camera, more the far value is big, more the field of view will be bigger, the default biggest far value in yandere simulator is set to 350, it is recommanded to disable the QualityManager gameobject when we modify these values