Hello guys, i been working on this npc voice system long time already, and since i am not going to use it coz dont have allot voice actors and no time, so here is what i was using Feel free to share use or w.e
The code is simple coding, feel free to re build it coz i know its not coded the best way and it can be much better.
credit to (Nocturnal) who helped me make it, long time ago.
credit to (Fang) who fixed a small bug in my voice system.
The code is simple coding, feel free to re build it coz i know its not coded the best way and it can be much better.
Code:
_String _string = new _String(true); _string.UID = client.Entity.UID; _string.TextsCount = 2; _string.Type = _String.Sound; _string.Texts.Add("voice/get_out.wav"); _string.Texts.Add("1"); client.Send(_string);
Code:
public byte[] ToArray() { ushort entirelength = 19; foreach (string list in Texts) entirelength += (ushort)(list.Length + 1); byte[] buffer = new byte[entirelength]; WriteUInt16((ushort)(entirelength - 8), 0, buffer); WriteUInt16(1015, 2, buffer); WriteUInt32(UID, 4, buffer); buffer[8] = Type; Buffer = buffer; WriteStringList(Texts, 9, Buffer); return Buffer; }
credit to (Fang) who fixed a small bug in my voice system.