Browse Search Popular Register Upload Rules User list Login:
Search:
Very Basic Social AI 1.2 - Rest And Heal

Image:
screenshot of the scene

Author: UnityDogGaming04

Group: Default

Filesize: 28.69 kB

Date added: 2022-06-22

Rating: 5

Downloads: 684

Views: 208

Comments: 9

Ratings: 1

Times favored: 0

Made with: Algodoo v2.1.0

Tags:

Scene tag

VBSAI 1.2.2

VBSAI 1.2 (Rest And Heal Update) will now passively heal, meaning two agents fighting will no longer find themselves stuck in a loop after they both reach critical health. Aim speed decreases at lower health.

Controls in scene.
Last edited at 2022/08/17 00:53:32 by UnityDogGaming04
Please log in to rate this scene
edit
Similar scenes
Title: Algicosathlon Day 5B
Rating: 5
Filesize: 284.03 kB
Downloads: 271
Comments: 5
Ratings: 1
Date added: 2015/07/08 05:27:22
Made with: Algodoo v2.1.0
Rating: rated 5
download
Title: Algotriaconathlon Day 16 RESULTS
Rating: 5
Filesize: 169.69 kB
Downloads: 328
Comments: 10
Ratings: 1
Date added: 2015/08/07 01:21:11
Made with: Algodoo v2.1.0
Rating: rated 5
download
Title: Tokens for blueice57
Rating: 5
Filesize: 36.85 kB
Downloads: 125
Comments: 0
Ratings: 1
Date added: 2017/08/02 22:23:24
Made with: Algodoo before v1.8.5
Rating: rated 5
download
Title: Algotriaconathlon Day 6 Results Part 1
Rating: 5
Filesize: 1.16 MB
Downloads: 396
Comments: 9
Ratings: 1
Date added: 2015/07/01 22:42:35
Made with: Algodoo v2.1.0
Rating: rated 5
download
Title: Algicosathlon Day 3 Results
Rating: 5
Filesize: 493.34 kB
Downloads: 590
Comments: 2
Ratings: 1
Date added: 2015/09/22 03:30:24
Made with: Algodoo v2.1.0
Rating: rated 5
download
Title: Hurt and Heal (ALGICOSATHLON DAY 9)
Rating: 5
Filesize: 38.18 kB
Downloads: 132
Comments: 5
Ratings: 1
Date added: 2016/05/19 02:48:03
Made with: Algodoo v2.1.0
Rating: rated 5
download
Occasionally the AI agent gets stuck between one of the text boxes and the ground plane (it oscillates up and down between the two). An easy fix is to remove collision layers from the boxes (the only two in each box I see are "A" and "Water").

Another thing you might consider is to keep the text box that lists the control keys in view at all times by having it follow the camera. You can do that by placing the following script in the box postStep event: pos = scene.camera.pan + [-10.0, 5.0] You can of course adjust the offsets in order to place the box where you want it during scene play. This doesn't compensate for camera zoom, and so you may need to add script that automatically adjusts things based on what the player does with it.
Last edited at 2022/06/22 21:48:39 by Xray
I left the text boxes so that there's some interesting things for the agent to interact with, and in fact there was an easy way to kill the agent if it got stuck up there. I'll see what I can do with the controls window, and I'll add some textless blocks for interesting terrain instead.
I've decided against any code and just threw the controls into the text of selection menu widgets, let me know what you think.
That's a great idea and it works very well! Good job! :tup:
Problem: After playing for a short time period (1 or 2 minutes) I lost all ability to control my player agent. Both it and the AI agent ended up on that pink pyramid and were just bobbing up and down! I don't know why that happened, if it was anything that I did wrong. :huh:

EDIT: The same thing happened again. It was when my player turned gray color I lost all control. Is it supposed to do that? :s
Last edited at 2022/06/23 00:02:15 by Xray
Yes, that is meant to happen. It happens when you press the S key. I should probably change that to a different key to keep that from happening.

Pressing S will set the orange box's _player to false, meaning the NPC behavior takes over, the player turns gray, and the camera stops following it. To regain control, left click on the agent (or any agent, for that matter) and things will go back to normal.
Just curious, where is the AI code located? I can't seem to find it.
The AI code is in the postStep of both the player and NPC agents. The code decides whether to give the AI or the external player control based on the _player variable.
Oh, Okay, now I understand it. For some dumb reason I was looking for neural network code which is quite different. (Duh!) :lol:

Thanks
Last edited at 2022/06/24 06:18:03 by Xray