Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- string lettre = get_property("pvplettre");
- string[slot] bestinslot;
- foreach i in $slots[]{
- int lettreosity = 0;
- foreach j in $items[]{
- if(j.to_slot()==i & contains_text(j.name.entity_encode().to_lower_case(),lettre) & j.weapon_hands() < 2){
- int d = 0;
- string[int] whatever = split_string(j.name.entity_encode(),"");
- foreach k,m in whatever{
- if(m.to_lower_case() == lettre){
- d++;
- }
- }
- if(d > lettreosity){
- bestinslot[i] = "";
- lettreosity = d;
- }
- if(d == lettreosity){
- bestinslot[i] += j.name.entity_encode()+", ";
- }
- }
- }
- if(lettreosity > 0){
- print_html("the most "+lettre+" "+i+"s: "+bestinslot[i]+"with "+lettreosity+" "+lettre+"s");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment