PlaceholderGames / DinoPark-2017

repo for Dino Park 2017, the testbed for CS3S667
2 stars 0 forks source link

Fighting between Dinos #53

Open 14065258 opened 6 years ago

14065258 commented 6 years ago

Feels weird to ask for this, but seeing as nobody has really come forward to make a method for dealing damage between dinos thought i should suggest one.

So can we make a global function in myAnky/myRapty that looks like below so that when the other dino is in range, it can call this function to do damage. The destoryObject(GameObject) will distroy the object its currently attached to image

So for my raptor. To get it to deal damage, it will deal damage when its in range of 20. it will get the dino its currently aiming at, GetComponent and then call that function. image

ghost commented 6 years ago

I decided not to implement combat AI as there was no current combat system standard mentioned or implemented, so ive made a attacking behaviour, but the dinos currently do nothing when in that state.

I think this is the sorta stuff mike was asking about when asking for help with the testbeds initial development.

LiamVallance commented 6 years ago

I feel that within a range of 20 is a pretty wide radius, something more like 5 would mean that the two would have to be actually next to each other to attack, i currently have my anky flee any raptor that gets within 40 but will instead turn and fight if it gets within 5.

I feel this is a more fair system as it requires the raptors to sneak up on or surround the anky in order to get close enough, more input from more people would be good though

14065258 commented 6 years ago

Yeah alright xD i'll change the distance down, Its more because i wasnt too bothered in testing for the raptor to get up close. but thats not a problem. The bottom pic was meant as only a guide anyway

DoctorMikeReddy commented 6 years ago

Ok, I have addressed this (in part) in a recent BlackBoard announcement that has gone out. There are a number of ways combat can be done, and this approach isn't incompatible (or wrong) with what I had envisaged (and discussed in the lecture). For the record, I am going to use Box Colliders for taking hits, and similar colliders for doling out damage, which is how games such as Street Fighter, etc, work. Head and Tail box colliders will do damage if the dino is in Attack Mode. The current box colliders on the models will be vulnerable points, especially if hit from the side or rear. All I am looking for is the Attack State being enabled, and an impact being detected on the box colliders, as this wasn't fully implemented. However, you can proceed with what you are doing, rather than following what I have described, if you wish to, as this wasn't in place, or officially defined (like vision was) when you started.