December 20, 20169 yr Ive tried alot of things so I decided to try just walking the path. here is my set up, exactly like how it was posted in the tutorials however. I am getting a erro private Position[] path = { new Position(3183, 3431, 0), new Position(3177, 3429, 0), new Position(3171, 3426, 0), new Position(3172, 3416, 0), new Position(3171, 3404, 0), new Position(3173, 3395, 0), new Position(3177, 3388, 0), new Position(3179, 3381, 0), new Position(3182, 3375, 0) }; Then using getWalking().walkPath(path); But its wanting me to change it to .walk, and then when I change it to walk. it wants me to do other stupid shit. any help?
December 20, 20169 yr It's asking for a list. List<Position> path = Arrays.asList( new Position(3183, 3431, 0), new Position(3177, 3429, 0), new Position(3171, 3426, 0), new Position(3172, 3416, 0), new Position(3171, 3404, 0), new Position(3173, 3395, 0), new Position(3177, 3388, 0), new Position(3179, 3381, 0), new Position(3182, 3375, 0) );
December 20, 20169 yr Ive tried alot of things so I decided to try just walking the path. here is my set up, exactly like how it was posted in the tutorials however. I am getting a erro private Position[] path = { new Position(3183, 3431, 0), new Position(3177, 3429, 0), new Position(3171, 3426, 0), new Position(3172, 3416, 0), new Position(3171, 3404, 0), new Position(3173, 3395, 0), new Position(3177, 3388, 0), new Position(3179, 3381, 0), new Position(3182, 3375, 0) }; Then using getWalking().walkPath(path); But its wanting me to change it to .walk, and then when I change it to walk. it wants me to do other stupid shit. any help? As was mentioned above, you've defined it as an array, which is what the API path walking used to take (hence the outdated tutorials tell you to do it this way). Instead, you need to define it as a list.
December 20, 20169 yr Author yup, I got it . Now onto determining how to calculate players around me... lol anyone help me out with that one. Im in the blind with this af!
December 20, 20169 yr yup, I got it . Now onto determining how to calculate players around me... lol anyone help me out with that one. Im in the blind with this af! for (Player player : getPlayers().getAll()) { if (player.mycondition() == whatIamLookingFor) { //do stuff with player } }
December 20, 20169 yr Author for (Player player : getPlayers().getAll()) { if (player.mycondition() == whatIamLookingFor) { //do stuff with player } } Well, tyvm MR.Abuse!
December 21, 20169 yr Author Well what I am looking to do is calculate that if surrounding players is more then 3, to either hop or move to the next rock... int Tomuch = 3; the thing is, I cant do <=, or >= for (Player player : getPlayers().getAll()) { ///////Calculating players around if(player.equals(Tomuch)){ //hop //walktootherrock } } Could I use this?? for (Player player : getPlayers().getAll()) { ///////Calculating players around if(player.getIndex() <=2){ //do something } }
Create an account or sign in to comment