Scripts / Basic branching conversation script

Author
Message
Gtox
3D Media Maker
9
Years of Service
User Offline
Joined: 5th Jun 2014
Location: South Africa
Posted: 16th Aug 2015 12:11
Here's a branching conversation script. I haven't included any notations, but it's pretty easy to follow. The reason I chose keys "m" and "n" to make choices was because 1 & 2 are used to switch weapons and "a" is used to strafe left.
I wanted to include sound, but the PlaySound command didn't work as I wanted it to, so I left it out.



Attachments

Login to view attachments
Inertia
8
Years of Service
User Offline
Joined: 12th Jul 2015
Location: SoCal, USA
Posted: 16th Aug 2015 13:24
Very clever scripting, Gtox! I ran it and it works great, very funny lines, and I like the use of "SwitchScript" in there.
Windows 7 (x64) | i5-2500K @ 3.30 GHz | 4GB RAM | GTX580 1.5 GB
PM
Gtox
3D Media Maker
9
Years of Service
User Offline
Joined: 5th Jun 2014
Location: South Africa
Posted: 16th Aug 2015 13:47
Thanks Inertia. It'd be nice to have a friendly AI script, so you talk someone into following you around. Still, I think you could do quite a lot using the script as a template.
AceRimmer
Reviewed GameGuru on Steam
9
Years of Service
User Offline
Joined: 28th Feb 2015
Playing: classic British heavy metal mostly
Posted: 17th Aug 2015 15:53 Edited at: 17th Aug 2015 15:54
great! very handy, and useful. Learned a lot from that. thanks

I found that if you set your character using the script to follow a waypoint, and setting its view distance very low (eg 3) so it doesn't see you, it'll walk off in a huff along the waypoints instead of killing you. Quite handy if you want the character to lead you somewhere maybe. Not ideal and a bit of a bodge, but maybe useful in a "follow me I'll take you to the boss etc" narrative.
Gtox
3D Media Maker
9
Years of Service
User Offline
Joined: 5th Jun 2014
Location: South Africa
Posted: 17th Aug 2015 16:28
Thanks AceRimmer - interesting discovery 'walk off in a huff'
AceRimmer
Reviewed GameGuru on Steam
9
Years of Service
User Offline
Joined: 28th Feb 2015
Playing: classic British heavy metal mostly
Posted: 18th Aug 2015 19:55 Edited at: 18th Aug 2015 19:57
For a friendly AI to follow you could it be as simple as swapping the "ai_cover" included script to use small G's Pet script instead?
Gtox
3D Media Maker
9
Years of Service
User Offline
Joined: 5th Jun 2014
Location: South Africa
Posted: 18th Aug 2015 21:36
Getting a character to follow you isn't all that difficult, in theory. What we really want is friendly AI that attack our enemies.
Pirate Myke
Forum Support
13
Years of Service
User Offline
Joined: 31st May 2010
Location: El Dorado, California
Posted: 19th Aug 2015 02:35
Nicely done Gtox, thank you for the script.
Intel(R) Core(TM)2 Quad CPU Q6600 @ 2.40GHz, 2400 Mhz, 4 Core(s), 4 Logical Processor(s), 8gb RAM, Nvidia gtx660, Windows 7 Pro 64bit

Isagabe
9
Years of Service
User Offline
Joined: 12th Sep 2014
Location:
Posted: 22nd Aug 2015 08:12
Gtox
Nice work. Thank you. And agreed, friendly AI to take part in combat alongside player is much need.

Login to post a reply

Server time is: 2024-04-26 12:01:45
Your offset time is: 2024-04-26 12:01:45