DrNova Posted September 30, 2008 Author Share Posted September 30, 2008 I'm going to take a whack at making npc's shoot, since none of the real coders seem to want to touch it (not a dis, simply stating none of the real coders want to take the time to do and post it)Anyone have any tips on where to begin?I've found the various section in client and server, the "arrow hit", "check arror"(not sure this ones purpose), the npc attack AI, ect. but as I really know little to nothing about VB besides whats visually comprehendable, I'm clueless where to start.It looks to me like some copying of various part of other subs, as well as a few data additions would be needed, but I have no idea where to start.Any tips?(Keep in mind I dont want to make any sort of AI for it at the moment, simply they just start shooting as they move towards you in the normal fashion they hunt down a player) Link to comment Share on other sites More sharing options...
Robin Posted October 1, 2008 Share Posted October 1, 2008 I'm doing this for Kreator and Japez's Zelda game.I'll basically just be doing an area check of the player's position vs. the npc's position + it's range variable. I'll then position it in a place where it can 'shoot' the player.Of course, you'd need a classic Zelda-style maze where you _need_ to go down a straight line to fight them, otherwise they'll be as dangerous as a small piece of cellotape. Link to comment Share on other sites More sharing options...
DrNova Posted October 3, 2008 Author Share Posted October 3, 2008 I want something a little more cheesy.Basically, I want them to just continue firing arrows while they are moving as normal towards the player.I dont need checks for location, because as soon as the "attack" stuff is initiated, it should just start shooting. This will make it a little wild, but I think make for some interesting firefights.Not fancy, I know, but I cant do fancy(much less crappy)But this also makes the ease of dodging a straight shopt harder, as if they are turning here and there as they come towards you they are still firing, makes more to dodge.If someone cant tell me how, I'd pay to have this added Link to comment Share on other sites More sharing options...
Sylexus44 Posted October 4, 2008 Share Posted October 4, 2008 Id' love to know this and how to make them use skills and spells. Someone should make a tut on how to do it. Link to comment Share on other sites More sharing options...
DrNova Posted October 5, 2008 Author Share Posted October 5, 2008 I've seem a topic somewherw showing how to make them do spells, check the codes snippets section maybe Link to comment Share on other sites More sharing options...
Sylexus44 Posted October 5, 2008 Share Posted October 5, 2008 k thx for the advice Link to comment Share on other sites More sharing options...
Robin Posted October 6, 2008 Share Posted October 6, 2008 @robinsafaggot:> Robin - lol your a 15 year old fag, who looks like a really fugly version of a veronica sister… yeah thats you... black emo hair, lol you look like a chick and sound like one on my forum.Awww. I never knew you cared <3 Link to comment Share on other sites More sharing options...
DrNova Posted October 6, 2008 Author Share Posted October 6, 2008 Go away DFA. Muted(I hate little kids) Link to comment Share on other sites More sharing options...
Kusy Posted October 6, 2008 Share Posted October 6, 2008 What the Duck? He returned? Nvm.Your idea is nice nova… That would make NPCs more dangerous... even if they target only one player they can still acidentialy hit others.[Whoops… I forgot I left - just lurking.] Link to comment Share on other sites More sharing options...
Fred Posted October 6, 2008 Share Posted October 6, 2008 In Aphelion Online i have NPC that shooting spells, but i dunno if this idea you like. I use something like Robin says, and it work good for me (when you add spellanim its looks good).Just make script when NPCX = GetPlayerX - n (n will be example from 1 to 5) and NPCY, then damage player and use spellanim in that n locations so this will be looking like ship fire to other. That can be looking very nice :) Link to comment Share on other sites More sharing options...
DrNova Posted October 7, 2008 Author Share Posted October 7, 2008 If I cant get arrows, that what I'll end up doing Link to comment Share on other sites More sharing options...
Khachaturian Posted October 7, 2008 Share Posted October 7, 2008 stupid little script you could use :when the npc sees the player,make a line of animations going to the player as if it was shooting the player,might work for diagonal shooting( lol i didnt script it… ) Link to comment Share on other sites More sharing options...
DrNova Posted October 7, 2008 Author Share Posted October 7, 2008 to cheesy and annoying to script.Plus probably laggy in the end Link to comment Share on other sites More sharing options...
Khachaturian Posted October 8, 2008 Share Posted October 8, 2008 yea probablyi just felt i had to be part of this thread… Link to comment Share on other sites More sharing options...
DrNova Posted October 8, 2008 Author Share Posted October 8, 2008 This thread has been useless.No one has helped the actual question Link to comment Share on other sites More sharing options...
dg1423 Posted October 8, 2008 Share Posted October 8, 2008 Well, if I find time, I can add it in for you. Basically you just need to add a sub to the npc move routine and a new bltarrow for npc usage. Not hard, really. Link to comment Share on other sites More sharing options...
DrNova Posted October 8, 2008 Author Share Posted October 8, 2008 That would be cool Link to comment Share on other sites More sharing options...
Zananok Posted October 10, 2008 Share Posted October 10, 2008 @dg1423:> Well, if I find time, I can add it in for you. Basically you just need to add a sub to the npc move routine and a new bltarrow for npc usage. Not hard, really.Not recommended if you can't ajust the delay time, if DrNova's game is similar to my game related to time. But very good for games that doesn't require precis timer :)Here is a tip (mine uses just sadscript and is similar to this):@Fred:> Just make script when NPCX = GetPlayerX - n (n will be example from 1 to 5) and NPCY, then damage player and use spellanim in that n locations-Each single NPC has it's own mana (ammo)-Each single NPC has it's own 'regen' time (timed/no regen/infinite)-Each NPC number has it's own shooting delay-Each NPC number has it's own 'max distance'-Each single NPC: (kill gets: + mana) |or| (kill gets: + max_mana) |or| nothingEdit:Oh and for the anim, just use a 'do while' to send an anim per tile until it reaches the target.Hope this helps,From: Zananok Link to comment Share on other sites More sharing options...
DrNova Posted October 10, 2008 Author Share Posted October 10, 2008 I think splashing animations around would be a resource drain wouldnt it Link to comment Share on other sites More sharing options...
dg1423 Posted October 10, 2008 Share Posted October 10, 2008 the way nova wants it is very simple Zananok, I know how complicated it can be to develop an actual system for this (I've done it before) but Nova pretty much just wants see and shoot thing. It's extremely easy to add firing rates and arrow types and power gen. The server stuff takes maybe 10 minutes to complete. The harder part is adjusting the clients blting system to show the arrow when it fires, which is still extremely easy. The whole system might take 20-30 minutes to implement or up to 45 for more complex systems. But all in all, it's very simple to do. Hell if I wanted I could throw in an NPC battle scripting system like the one in RPG Maker. (I'll have to take note of that as it's a good idea) Link to comment Share on other sites More sharing options...
Zananok Posted October 10, 2008 Share Posted October 10, 2008 @DrNova:> I think splashing animations around would be a resource drain wouldnt itMaybe, but for me it works fine ;)@dg1423:> the way nova wants it is very simple ZananokOh,sorry :S@dg1423:> Hell if I wanted I could throw in an NPC battle scripting system like the one in RPG Maker. (I'll have to take note of that as it's a good idea)Nice idea!Comments,From: Zananok Link to comment Share on other sites More sharing options...
Fred Posted October 10, 2008 Share Posted October 10, 2008 @Zananok:> -Each single NPC has it's own 'regen' time (timed/no regen/infinite)> -Each NPC number has it's own shooting delay> -Each NPC number has it's own 'max distance'> -Each single NPC: (kill gets: + mana) |or| (kill gets: + max_mana) |or| nothingSure, by scripting you can do even more statistics like evasion or random firepower. But if this must be arrow… let it be. Link to comment Share on other sites More sharing options...
DrNova Posted October 10, 2008 Author Share Posted October 10, 2008 Problem with scripted nc's, they dont activate unless you make them via interaction. They cant just automatically run the script.I'm still going to see if he will implement the arrows for me though, would be much more efficient and more along my desires Link to comment Share on other sites More sharing options...
Fred Posted October 10, 2008 Share Posted October 10, 2008 @DrNova:> Problem with scripted nc's, they dont activate unless you make them via interaction. They cant just automaticallyNo… you dont understood. Its not scripted npc.You can script if there is normal npc in your range then he can fire. Just you must use timers. Link to comment Share on other sites More sharing options...
DrNova Posted October 11, 2008 Author Share Posted October 11, 2008 bleh, to messy.Check if its an NPC that would attack, check for range, check for line of fire, run multiple animations along a direction, check for position and damage if your there….To messy, I'd rather either get arrows into npc's via source, or if that fails use the source snippet of spell casting npc's Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now