Resource icon

Approved HomeSystem 2.6.5

No permission to download

Assassin

Plugin Developer
Plugin Developer
Apr 9, 2017
190
196
43
26
Iran
Reporting an Important Bug:


Python:
elif cmd == "delfriendh":
            if len(args) == 0:
                Player.MessageFrom(self.homesystemname, "Usage: /delfriendh playername")
                return
            name = str(args[0])
            ini = self.Wl()
            players = ini.EnumSection(id)
            if len(players) == 0:
                Player.MessageFrom(self.homesystemname, "You have never added anyone...")
                return
            name = name.lower()
            for playerid in players:
                nameof = ini.GetSetting(id, playerid)
                lowered = nameof.lower()
                if lowered == name:
                    ini.DeleteSetting(id, playerid)
                    ini.Save()
                    Player.MessageFrom(self.homesystemname, "Player Removed from Whitelist")
                    return
Player.MessageFrom(self.homesystemname, "Couldn't find that player!")
this part of resource has problem & problem is if you /addfriendh Assassin
my name will save in ini file as Assassin
but if i change my name to BlaBla... you can't delfriendh me!!!
@DreTaX plz tell me what i must do to fix it if you don't have enough time for it
 

Jakkee

Retired Staff
Retired Staff
Plugin Developer
Jul 28, 2014
1,465
932
113
Australia
Reporting an Important Bug:


Python:
elif cmd == "delfriendh":
            if len(args) == 0:
                Player.MessageFrom(self.homesystemname, "Usage: /delfriendh playername")
                return
            name = str(args[0])
            ini = self.Wl()
            players = ini.EnumSection(id)
            if len(players) == 0:
                Player.MessageFrom(self.homesystemname, "You have never added anyone...")
                return
            name = name.lower()
            for playerid in players:
                nameof = ini.GetSetting(id, playerid)
                lowered = nameof.lower()
                if lowered == name:
                    ini.DeleteSetting(id, playerid)
                    ini.Save()
                    Player.MessageFrom(self.homesystemname, "Player Removed from Whitelist")
                    return
Player.MessageFrom(self.homesystemname, "Couldn't find that player!")
this part of resource has problem & problem is if you /addfriendh Assassin
my name will save in ini file as Assassin
but if i change my name to BlaBla... you can't delfriendh me!!!
@DreTaX plz tell me what i must do to fix it if you don't have enough time for it
/delfriendh Assassin?
Shouldn’t matter if they changed their name
 
  • Agree
Reactions: DreTaX

ice cold

Active Member
Trusted Member
Member
Oct 24, 2016
606
876
43
Canada
i know all these shits, please test it one time in your server and you will see the bug i said,

maybe you need a video ?
it doesnt matter if someone changes his name becaus it gets the steamid of the selected user and checks if the id is in the ini or not
 

Assassin

Plugin Developer
Plugin Developer
Apr 9, 2017
190
196
43
26
Iran
it doesnt matter if someone changes his name becaus it gets the steamid of the selected user and checks if the id is in the ini or not
well, the point is here

i think you can believe it so i will upload a simple video of it