Lunksnark Report post Posted January 26, 2007 Oops, I just updated my post while you were replying to my original one.. Looks like we got out of sync a little there. LOL laugh.gif Same here, my day of work was not very productive... whistle.gif No comment Share this post Link to post Share on other sites
Entropy Report post Posted January 27, 2007 Anyway, there is no point in wasting our time arguing about how it will be done. Since me and Schmurk are the ones actually implementing it (he is doing the hard work, btw), this is how it will be done. I would rather sacrifice some memory and CPU speed in order to get the best possible outcome, rather than go with 2d units ina 3d world and have all kind of weird situations with arrows going through the wrong palces or not going through the right places. Share this post Link to post Share on other sites
Cycloonx Report post Posted January 27, 2007 I've just been thinking about the thing that a person can hold a shield or not. Person who cary a shield could hide behind, person who not have a shield can't. So those should always be hitted, people with a shield should be hitted less imo. Share this post Link to post Share on other sites
nathanstenzel Report post Posted January 27, 2007 (edited) game squares: 50x50cm 20cm tall I will not refer to game squares as 3d from here on, but I will refer to the 2d game squares that contain stacks of 3d game squares. If going real life pro archer length 90 meter (9000cm) max shoot length 9000/50=180 if straight north/south/east/west (not a mixed angle) c=9000cm a*a+b*b=c*c a=b c*c/2=a*a a=b=6364cm 6364 north-south and 6364 east west covered 127*2=254 max squares to check assuming all squares are checked if arrows only go as far as 9 meters (900cm).... 900/50=18 squars if going straight N/S/E/W 900*900/2=405000=a*a a=b=637cm 637/50 13*2=26 max squares checked if going NE/SE/NW/SW If we want to get rid of any arch, try this recipe... 10(?) quartz crystal, 1 matter essence, 1 energy essence What do you get? One gravity defying lit up arrow that makes a simple colored line when shot. And since, as entropy pointed out that it would be instantly from shooter to target, drawing a line might be optional. It could be just invisible. This whole alternative arrow recipe goes along the idea that these characters are stranded from space ships crashing on the planet. As for collision detection, if you use straight lines, you could render perhaps a 100x100 pixel mono color picture (90 degree viewing range) of the target from the shooter's point of view. If it is visible for a dot, it would be white. If not there or blocked, black. Difficulty would be adjusted due to the length of the target by the fact that it would take up less space in the picture. The type of bow, attack skill of shooter, armor of defender and defense skill of defender (if applied) would adjust the chances. Figure 100 pixels total would be 100% chance (neglecting skills and bow). More pixels is more chance. Less pixels is less chance. Adding attacker's adjustments to the pixel count and subtracting the defender adjustments could give the chance to hit. Subtracting a random number (0-100) would get a number that if greater than 0, you hit. If greater than 50, could be a critical hit....something like that. Good luck with the work, Schmurk. Edited January 27, 2007 by nathanstenzel Share this post Link to post Share on other sites
Schmurk Report post Posted January 27, 2007 [...] As for collision detection, if you use straight lines, you could render perhaps a 100x100 pixel mono color picture (90 degree viewing range) of the target from the shooter's point of view. If it is visible for a dot, it would be white. If not there or blocked, black. Difficulty would be adjusted due to the length of the target by the fact that it would take up less space in the picture. The type of bow, attack skill of shooter, armor of defender and defense skill of defender (if applied) would adjust the chances. Figure 100 pixels total would be 100% chance (neglecting skills and bow). More pixels is more chance. Less pixels is less chance. Adding attacker's adjustments to the pixel count and subtracting the defender adjustments could give the chance to hit. Subtracting a random number (0-100) would get a number that if greater than 0, you hit. If greater than 50, could be a critical hit....something like that. Good luck with the work, Schmurk. Thank you very much I will not argue on what you proposed because I'm just doing the collision detection between 2 points and it's up to Entropy to decide how it will work. But one thing is sure, firing 100 rays per shoot is way too much. As Entropy said it should not be more than 2 or 3 rays. Share this post Link to post Share on other sites
nathanstenzel Report post Posted January 27, 2007 [...] As for collision detection, if you use straight lines, you could render perhaps a 100x100 pixel mono color picture (90 degree viewing range) of the target from the shooter's point of view. If it is visible for a dot, it would be white. If not there or blocked, black. Difficulty would be adjusted due to the length of the target by the fact that it would take up less space in the picture. The type of bow, attack skill of shooter, armor of defender and defense skill of defender (if applied) would adjust the chances. Figure 100 pixels total would be 100% chance (neglecting skills and bow). More pixels is more chance. Less pixels is less chance. Adding attacker's adjustments to the pixel count and subtracting the defender adjustments could give the chance to hit. Subtracting a random number (0-100) would get a number that if greater than 0, you hit. If greater than 50, could be a critical hit....something like that. Good luck with the work, Schmurk. Thank you very much I will not argue on what you proposed because I'm just doing the collision detection between 2 points and it's up to Entropy to decide how it will work. But one thing is sure, firing 100 rays per shoot is way too much. As Entropy said it should not be more than 2 or 3 rays. LOL Well, here is hoping you can figure it out. I figured my little cheater arrow method was cute though. LOL (crossing my fingers and hoping Schmurf can get everything done nicely for the next client update) Share this post Link to post Share on other sites
Learner Report post Posted January 27, 2007 [...] As for collision detection, if you use straight lines, you could render perhaps a 100x100 pixel mono color picture (90 degree viewing range) of the target from the shooter's point of view. If it is visible for a dot, it would be white. If not there or blocked, black. Difficulty would be adjusted due to the length of the target by the fact that it would take up less space in the picture. The type of bow, attack skill of shooter, armor of defender and defense skill of defender (if applied) would adjust the chances. Figure 100 pixels total would be 100% chance (neglecting skills and bow). More pixels is more chance. Less pixels is less chance. Adding attacker's adjustments to the pixel count and subtracting the defender adjustments could give the chance to hit. Subtracting a random number (0-100) would get a number that if greater than 0, you hit. If greater than 50, could be a critical hit....something like that. Good luck with the work, Schmurk. Thank you very much I will not argue on what you proposed because I'm just doing the collision detection between 2 points and it's up to Entropy to decide how it will work. But one thing is sure, firing 100 rays per shoot is way too much. As Entropy said it should not be more than 2 or 3 rays. LOL Well, here is hoping you can figure it out. I figured my little cheater arrow method was cute though. LOL (crossing my fingers and hoping Schmurf can get everything done nicely for the next client update) Most of the code being talked about here with collision detection & chance to hit is all server coding anyways, no rendering is done at all. How to handle in the client is a different discussion. Share this post Link to post Share on other sites