Hey Dennis,
First off, are you aware that you are inputting the game object and not a float value into the .SetRTPCValue() function?
You probably want it to look something like this:
AkSoundEngine.SetRTPCValue("EngineRTPC", 23f);
where 23 is the value you set the RTPC to, and f means that it is a float value (the type of property that the function needs).
Here's a suggestion to how you can get started, where you can change a slider to easier test your implementation.
Start by making a float property, like...
[Range(0f,100f)] // This just displays a nice slider in Unity's inspector, that you can interact with.
public float speedValueOfCar = 50; // Insert this outside any functions, but inside your script class.
And then inside the update function could look like this:
void Update() {
if (Input.GetKeyDown(KeyCode.Space)) {
AkSoundEngine.PostEvent(StartEngine, gameObject);
}
AkSoundEngine.SetRTPCValue("EngineRTPC", speedValueOfCar);
}
Now save, and then return to Unity, click Play, start the sound and try out the slider.
Tip: Do you know about Wwise-Types? They can be a bit simpler to call, compared to AkSoundEngine functions. To start with your example, you could do this instead:
[Range(0f,100f)]
public float speedValueOfCar = 50;
public AK.Wwise.RTPC CarSoundRTPC;
void Update()
{
CarSoundRTPC.SetGlobalValue(speedValueOfCar);
}
And then you'd get a nice button in the inspector, where you can select an Event and not have to check for typos.
Does this make it clearer?