mfausb Posted March 27, 2011 Posted March 27, 2011 not rly isOnline is boolean(only true or false) so u cant check if it is 1 or any other number, and by writing if(onlineplayer.isOnline()) you mean if(onlineplayer.isOnline()==false), so its not the same :) What are you talking about? I just told the guy how its in freya because now its this way. Quote
monaliza Posted March 27, 2011 Posted March 27, 2011 What are you talking about? I just told the guy how its in freya because now its this way. so in freya is just need to change =1 to false? or true? 1=true 0=false? if (onlinePlayer.isOnline() == 1) to if (onlinePlayer.isOnline() == true) or if (onlinePlayer.isOnline() == 1) to if (onlinePlayer.isOnline() == false) Quote
brett16 Posted April 6, 2011 Posted April 6, 2011 How do you edit how many kills you need to play whatever sound file? Quote
brett16 Posted April 6, 2011 Posted April 6, 2011 How do you edit how many kills you need to play whatever sound file? Quote
SlyWhiteSheep Posted April 8, 2011 Posted April 8, 2011 Nice share lol adds an FPS feel to the game. Quote
Chakl22 Posted May 9, 2011 Posted May 9, 2011 Not working in last Freya Rev. I change the imports to correct ones for L2J and if (onlinePlayer.isOnline() == 1) for if (onlinePlayer.isOnline() == true) so no errors when compile in eclipse, and yes put the files sound in the client, but not sounds in game for the killssprees what is wrong? EDIT: Working now, it was couse i have Music muted in l2 settings lol! i forget the sounds come from MUSIC folder not from SOUNDS. Quote
mfausb Posted June 8, 2011 Posted June 8, 2011 Not working in last Freya Rev. I change the imports to correct ones for L2J and if (onlinePlayer.isOnline() == 1) for if (onlinePlayer.isOnline() == true) so no errors when compile in eclipse, and yes put the files sound in the client, but not sounds in game for the killssprees what is wrong? EDIT: Working now, it was couse i have Music muted in l2 settings lol! i forget the sounds come from MUSIC folder not from SOUNDS. If you change it to onlinePlayer.isOnline() it continues only if the value returned by the method is true (meaning if the player is online) - otherwise put !(onlinePlayer.isOnline()) and it continues only if the value returned by the method is false (if the player is offline) so there is no need for an additional boolean check. Just have a closer look at the appropriate method and you will understand what I mean. Quote
monaliza Posted October 12, 2011 Posted October 12, 2011 [javac] Collection<L2PcInstance> pls = L2World.getInstance().getAllPlayers().values(); [javac] ^ [javac] symbol: method values() [javac] location: class L2TIntObjectHashMap<L2PcInstance> [javac] 1 error BUILD FAILED any idea? Quote
N3uTr0n Posted December 31, 2011 Posted December 31, 2011 + PlaySound _snd = new PlaySound(1, "enemydown", 0, 0, 0, 0, 0); + + Collection<L2PcInstance> pls = L2World.getInstance().getAllPlayers().values(); ------ + for (L2PcInstance onlinePlayer : pls) + if (onlinePlayer.isOnline() == 1) + { + if (onlinePlayer.getClan() != null) + { + if (onlinePlayer.getClan() == pk.getClan() && onlinePlayer != pk) + { + onlinePlayer.sendPacket(_snd); + } + } + } + got on values error Quote
SweeTs Posted December 31, 2011 Posted December 31, 2011 Try this + PlaySound _snd = new PlaySound(1, "enemydown", 0, 0, 0, 0, 0); + + Collection<L2PcInstance> pls = L2World.getInstance().getAllPlayers().values(); + for (L2PcInstance onlinePlayer : pls) + if (onlinePlayer.getClan() != null) + { + if (onlinePlayer.getClan() == pk.getClan() && onlinePlayer != pk) + { + onlinePlayer.sendPacket(_snd); + } + } + Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.