• Npc ai
    336 replies, posted
Hm. Ok, thanks. Here's to hoping they'll work in conjunction.
I dont really understand why you would use both if your on a map with nodes theres really no point in using this addon if your on one with them. Theres not really any functions for the npc to use with out a node so its very tricky to make them do things. There not even supposed to move long distances with the way I make them do it but I use it a hacky kinda way. Plus I'm not really sure how the noded AI your talking about works cause gmod.org is being weird but nodes do must of the thinking. Not really that hard to tell a npc to go pick up a gun when it does all the walking for you. whoa I say "really" alot.
I could imagine a Metal Gear sort of gamemode...
[QUOTE=-TB-;14779101]I dont really understand why you would use both if your on a map with nodes theres really no point in using this addon if your on one with them. Theres not really any functions for the npc to use with out a node so its very tricky to make them do things. There not even supposed to move long distances with the way I make them do it but I use it a hacky kinda way. Plus I'm not really sure how the noded AI your talking about works cause gmod.org is being weird but nodes do must of the thinking. Not really that hard to tell a npc to go pick up a gun when it does all the walking for you. whoa I say "really" alot.[/QUOTE] I don't always use AI noded maps, and I phrased it wrong, I meant like one will turnoff on a noded map and the other'll turn on. But I tested it and they do work, like the manhack option(metro police), nice touch.
I do believe the link is broken. Looks like a kick ass addon, Just wish i could DL it.
Ideas for options: Allow NPC use [ ] This enables the npc to press gmod buttons and normal buttons. So you can make a trap switch which splatters the AI unfortunate enough to press it. Npc will ragdoll [ ] NPCs cannot see behind them, so if they run backwards, one day they're gonna trip over, right? Well this option enables that. If the npc runs backwards towards an edge, they will fall off and likely die. This would also allow you to make a trap door that npcs can fall into and be injured. If you throw a grenade, but the NPC does not die from it, it will ragdoll (unconcious), then get up again (who needs animations anyway?). NPC is affected by lightmaps [ ] This means that non-combine/zombie npcs find it hard to see in the dark. They won't attack unless you get too close, and they are generally blind. Other NPCs will also utilize this to their advantage, like hiding in the dark until they strike, or sneaking past enemies. NPC Relation to other NPCs [ ] This allows NPCs to love/hate eachother. NPCs, when spawned, start off as nuetral relation to everyone (Except combine, which is explained later.). If NPCs love eachother, they will become squadmates. If NPCs hate eachother, they will kill eachother. This system runs off RPOINTS (Relation points). HATE is -100 RPOINTS. LOVE is 100 RPOINTS. FEAR is -50 RPOINTS. NUETRAL is 0 - 50 RPOINTS. Logic: IF NUETRAL/LOVE then TALK else IGNORE. IF FEAR then MOVE AWAY/SNEAK else ATTACK. IF HATE then ATTACK else SNEAK. RPOINTS are gained and lost through events. If an NPC shoots another NPC for whatever reason, their relation will go IMMEDIATELY to hate. If an NPC helps another NPC by say, helping an NPC kill another NPC, they will gain 15 relation. However, there are some NPCs that will immediately be hated/loved by certain other NPCs. The key is: C = Combine- Combine will relate to this unit based off ***C H = Human- Humans will relate to this unit based off ***H O = Other- Zombies and stuff will relate to this unit based off ***O Combine metropolice/scanner = 25C, -50H, -100O Combine manhack = 100C, -100H, -100O Combine soldier = 85C, -100H, -100O Any rebel unit = 10C, 10H, -100O Alyx = -100C, 100H, -100O Barney = -100C, 100H, -100O Zombies, Antlions etc. = -100C, -100H, 0O This option has a sub-option called "NPCs start with 0 relation to ALL". Which is self explanatory. That NPC is a spy [ ] Press this while facing an NPC, and it will cloak, disguise, and go around backstabbing. If the NPC relations toggle is enabled, everyone hates this NPC unless it's disguised as another already killed NPC. This allows it to sabotage, by walking up to anything mechanical (Buttons, thrusters, PCmod computers, etc.) and promptly screw it up. EG: Hoverballs fall off and stop working, thrusters go reverse, buttons start sparking and eventually explode, and if you have PCmod, it wipes everything on it. NPC hates watermelons [ ] Npcs will shoot all watermelons in sight. NPCs have random destinations [ ] (Only works if "Allow NPC use" is checked.) The game will at random, choose an object for the NPC to immediately go to/use/destroy. EG: Place a rebel in the corner of the map, and make a button on the other side that makes a rocket launch, eventually, the game will tell the NPC to go press it, and either avoid or attack any other enemies on the way. Be careful with this option though, that hard work you made on that airplane may be destroyed if the NPC happens to get inside and press the big red button. Pick up sticks (Or anything else) [ ] This means the NPC, if it is unarmed and sees a useful object, will walk over and pick it up for later use. What will happen is the npc walks over to the object, does an animation (any will do), and the item will disappear. Later the NPC might use this item. If the item is a watermelon, it might eat it and regain health. If the item is a useless piece of crap, it might just toss it at an enemy and run. Same applies for weapons, an NPC can hold up to 4 weapons, then either: A: Change weapons (Drops first weapon, like the original AI.) B: Change weapons (Switches weapon, storing the first in the inventory.) C: Give it to someone else (Another NPC, If the NPC is unarmed, they will be the first one they give it to.) D: Give it to you (Self explanatory.) F: Throw it at something. There are certain objects that regenerate an NPCs health. These are the objects: Watermelon models Beer models CSS Fruits (Bananas, oranges, etc.) There are objects that hurt NPCs too. They are: Bleach Car Tyres Paint cans (Randomly either throws or eats) Sawblades (See paint cans) Then there are enhancers which are: HEV Power batteries Medkits Snow man hat (Increases attack range, makes NPC wear it.) Snow man head (Decreases attack range, increases health, makes NPC wear it.) NPCs hate everything [ ] Means the NPC will shoot EVERYTHING. Entities, physics props, other NPCs, ANYTHING. They're just my silly ideas. I might have more soon.
Good idea -> medic citizens can give medkits to player, Alyx can go inside jalopy (like ep2)
Dire, those ideas are pretty immense, but you do realize they would probably be a pain in the ass to code? Especially things like NPCs picking up weapons, as even in HL2 iteslf, they cannot do this. (Well I've never seen one do it)
[QUOTE=punkyheX;14798073]Dire, those ideas are pretty immense, but you do realize they would probably be a pain in the ass to code? Especially things like NPCs picking up weapons, as even in HL2 iteslf, they cannot do this. (Well I've never seen one do it)[/QUOTE] They pick up weapons alright, but only if the weapon is better than the one they are holding.
[QUOTE=DireAvenger;14795619]Wall of AWESOME.[/QUOTE] I love you. Oh, and can they pick up sweps in your idea? And use Stargates?
[QUOTE=Preowned;14794522]I do believe the link is broken. Looks like a kick ass addon, Just wish i could DL it.[/QUOTE] The gmod.org servers are having some sort of network issues I think there just to overwhelmed sometimes it works and sometimes it says to busy for your request so you just have to keep seeing if there working yet. @Dire most of those ideas like sneaking around and stuff go go behind a player or not being able to see other enemys as well in the dark arnt really that possible or easy to do because the npcs are hard coded to start attacking as soon as they get in a certain range. I dunno most of those ideas are really hard to do based on the limited functions for a npc without nodes and lua. I will work on them picking up weapons though.
Any way that you can edit the accuracy rates of the combine and the rebels? Rebels seem to have an unfair advantage over the combine. I absolutely love Dire's idea which the NPC can give you their weapon, though. I wish you could make an NPC stop following you on the USE key, just like in HL1.
[QUOTE=-TB-;14803653]The gmod.org servers are having some sort of network issues I think there just to overwhelmed sometimes it works and sometimes it says to busy for your request so you just have to keep seeing if there working yet. [/QUOTE] ya, you right, the gmod site was down... or something alone those lines. DL with no problems now.
[QUOTE=Pwn-o-Matic;14803726]Any way that you can edit the accuracy rates of the combine and the rebels? Rebels seem to have an unfair advantage over the combine. I absolutely love Dire's idea which the NPC can give you their weapon, though. I wish you could make an NPC stop following you on the USE key, just like in HL1.[/QUOTE] No, I believe their bullet spread is hard coded. The use key idea sounds pretty good I'll see what I can do.
Or an NPC can use TWO weapons but one at a time. Like if a rebel wanted a shotgun but had a SMG, they could pick up the shotgun but put the shotgun on their back for later use. Then later they saw a AR2, they could not have two weapons on their back so they would have to switch either the shotgun or the SMG.So they can hold two weapons, one on their back and the one their holding but can switch at any time. Do the NPCs flank? Probaly not huh? I bet that would be a pain in the ass to code. The NPCs should run around and not stand in one place while battling, maybe go behind cover or duck behind low props. And do NPCs with the SMG use the SMG grenade?
[QUOTE=Jakiebob;14806541]Or an NPC can use TWO weapons but one at a time. Like if a rebel wanted a shotgun but had a SMG, they could pick up the shotgun but put the shotgun on their back for later use. Then later they saw a AR2, they could not have two weapons on their back so they would have to switch either the shotgun or the SMG.So they can hold two weapons, one on their back and the one their holding but can switch at any time. Do the NPCs flank? Probaly not huh? I bet that would be a pain in the ass to code. The NPCs should run around and not stand in one place while battling, maybe go behind cover or duck behind low props. And do NPCs with the SMG use the SMG grenade?[/QUOTE] Not sure NPCs can hold a weapon on their back, because the weapons would need attachment points to go onto the NPC's back. I doubt HL2 weapons have any of those. It might work, though, if the weapon disappears or something when they pick it up, going back to one of Dire's suggestions.
[QUOTE=kevkev;14800583]They pick up weapons alright, but only if the weapon is better than the one they are holding.[/QUOTE] I concur. I've seen npcs switching their pistols with shotguns all the time.
[QUOTE=zeldar;14806800]I concur. I've seen npcs switching their pistols with shotguns all the time.[/QUOTE] It's annoying though. Because they'll always go "Oooh a pistol!" *Pickup* "Oooh a shotgun!" *Pickup* "Oooh a pistol!" *Pickup* "Oooh a shotgun!" *Pickup* "Oooh a pistol!" *Pickup* "Oooh a shotgun!" *Pickup*
Yea ill give them like a secondary small weapon and a primary weapon slot and code which guns are better. like from least to greatest: Crowbar->stunstick->pistol and primary: shotgun->smg->ar2 somewhere along those lines. And of course there will be a button to turn this feature off. Edit* on the other hand I dont see much point in them having a secondary small weapon cause then I'd have to make them decide when to use it and there wouldn't be much point in switching to the pistol if they ahve a AR2.
[QUOTE=DireAvenger;14811271]It's annoying though. Because they'll always go "Oooh a pistol!" *Pickup* "Oooh a shotgun!" *Pickup* "Oooh a pistol!" *Pickup* "Oooh a shotgun!" *Pickup* "Oooh a pistol!" *Pickup* "Oooh a shotgun!" *Pickup*[/QUOTE] They never got a chance to for this with me as I whored all the ammo before they got near it :smile: Then wondered why they died a little later :downs:
[QUOTE=-TB-;14811397]Yea ill give them like a secondary small weapon and a primary weapon slot and code which guns are better. like from least to greatest: Crowbar->stunstick->pistol and primary: shotgun->smg->ar2 somewhere along those lines. And of course there will be a button to turn this feature off. Edit* on the other hand I dont see much point in them having a secondary small weapon cause then I'd have to make them decide when to use it and there wouldn't be much point in switching to the pistol if they ahve a AR2.[/QUOTE] Then add an ammo count for NPCs?
I remember my army of Rebel NPCs all running to pick up guns after a lengthy firefight, then tripping over the ragdolls and dying :/ .
[QUOTE=-TB-;14811397]Yea ill give them like a secondary small weapon and a primary weapon slot and code which guns are better. like from least to greatest: Crowbar->stunstick->pistol and primary: shotgun->smg->ar2 somewhere along those lines. And of course there will be a button to turn this feature off. Edit* on the other hand I dont see much point in them having a secondary small weapon cause then I'd have to make them decide when to use it and there wouldn't be much point in switching to the pistol if they ahve a AR2.[/QUOTE] -snip- should've read the next post.
Where's the download link?
Rebels still follow me even if I have Ignore Players checked.
[QUOTE=Gmod_Fan77;14820798]Where's the download link?[/QUOTE] It's on the front page :rolleyes: Ammo counts for NPCs would be cool, it'd be so lulz to watch them run around like wimps when they're out of ammo.
I love this addon...its great for maps that the mappers could never node like Evocity.
I had another idea. Option: NPC Always sees player [ ] This means the NPC always knows where the player is, and will follow/attack it, even if the player is through 85 concrete walls. EG: Place an NPC on one side of Evocity2, then go to the other side of Evocity2, you can expect the NPC to come running after a while.
Could you give NPC's an RPG like skill system?
[QUOTE=DieHardDeus;14825165]Could you give NPC's an RPG like skill system?[/QUOTE] Preferably as an option, I don't want to get raped by LV205782 headcrabs.
Sorry, you need to Log In to post a reply to this thread.