Raised This Month: $51 Target: $400
 12% 

bot how to use random numbers IP


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
sb123
Senior Member
Join Date: Jan 2007
Old 01-26-2024 , 05:40   bot how to use random numbers IP
Reply With Quote #1

How to make BOT use random numbers IP, Instead of 127.0.0.1
This way it looks better
__________________
sb123 is offline
Send a message via ICQ to sb123 Send a message via MSN to sb123 Send a message via Yahoo to sb123
mlibre
Veteran Member
Join Date: Nov 2015
Location: return PLUGIN_CONTINUE
Old 01-26-2024 , 08:01   Re: bot how to use random numbers IP
Reply With Quote #2

it's not possible
__________________
mlibre is offline
sb123
Senior Member
Join Date: Jan 2007
Old 01-26-2024 , 12:00   Re: bot how to use random numbers IP
Reply With Quote #3

I think it should be possible to modify the IP address of the BOT to more than 127.0.0.1
Attached Thumbnails
Click image for larger version

Name:	city.jpg
Views:	47
Size:	88.1 KB
ID:	202983  
Attached Files
File Type: sma Get Plugin or Get Source (Look_Ip_and_City.sma - 14 views - 1.3 KB)
__________________
sb123 is offline
Send a message via ICQ to sb123 Send a message via MSN to sb123 Send a message via Yahoo to sb123
mlibre
Veteran Member
Join Date: Nov 2015
Location: return PLUGIN_CONTINUE
Old 01-26-2024 , 12:32   Re: bot how to use random numbers IP
Reply With Quote #4

they take the local IP of the server... unless you want "non-real" addresses to appear in the motd. In this case, it could be replaced by another fictitious one
__________________
mlibre is offline
sb123
Senior Member
Join Date: Jan 2007
Old 01-26-2024 , 12:54   Re: bot how to use random numbers IP
Reply With Quote #5

Quote:
Originally Posted by mlibre View Post
they take the local IP of the server... unless you want "non-real" addresses to appear in the motd. In this case, it could be replaced by another fictitious one
I hope the IP address of the BOT is random, rather than being obtained from an array, which is very cumbersome and requires manual writing of the IP address

Can you solve this problem
__________________
sb123 is offline
Send a message via ICQ to sb123 Send a message via MSN to sb123 Send a message via Yahoo to sb123
Old 01-27-2024, 00:00
fysiks
This message has been deleted by fysiks. Reason: mis-read the request
mlibre
Veteran Member
Join Date: Nov 2015
Location: return PLUGIN_CONTINUE
Old 01-27-2024 , 07:59   Re: bot how to use random numbers IP
Reply With Quote #6

maybe something like that, you can adapt it in the loop...

PHP Code:
public client_connect(id)
{
    new 
ip[16]
    
    if(
is_user_bot(id))
    {
        
ip generate_address()
    }
    else
    {
        
get_user_ip(idipcharsmax(ip), 1)
    }
    
    
server_print("** ip = %s"ip)
}

stock generate_address()
{
    new 
ip[16]
    
    
formatex(ipcharsmax(ip), "%d.%d.%d.%d"random_num(1,223), random_num(0,255), random_num(0,255), random_num(0,255))
    
    return 
ip

__________________
mlibre is offline
sb123
Senior Member
Join Date: Jan 2007
Old 01-28-2024 , 04:37   Re: bot how to use random numbers IP
Reply With Quote #7

Quote:
Originally Posted by mlibre View Post
maybe something like that, you can adapt it in the loop...

PHP Code:
public client_connect(id)
{
    new 
ip[16]
    
    if(
is_user_bot(id))
    {
        
ip generate_address()
    }
    else
    {
        
get_user_ip(idipcharsmax(ip), 1)
    }
    
    
server_print("** ip = %s"ip)
}

stock generate_address()
{
    new 
ip[16]
    
    
formatex(ipcharsmax(ip), "%d.%d.%d.%d"random_num(1,223), random_num(0,255), random_num(0,255), random_num(0,255))
    
    return 
ip

Thank you very much for your help. After testing, the random address of the BOT is normal
__________________
sb123 is offline
Send a message via ICQ to sb123 Send a message via MSN to sb123 Send a message via Yahoo to sb123
mlibre
Veteran Member
Join Date: Nov 2015
Location: return PLUGIN_CONTINUE
Old 01-28-2024 , 13:21   Re: bot how to use random numbers IP
Reply With Quote #8

Quote:
Originally Posted by sb123 View Post
Thank you very much for your help. After testing, the random address of the BOT is normal
clear, it just makes it look like they have real IP addresses when they show it in the motd
__________________
mlibre is offline
sb123
Senior Member
Join Date: Jan 2007
Old 01-28-2024 , 22:50   Re: bot how to use random numbers IP
Reply With Quote #9

Quote:
Originally Posted by mlibre View Post
clear, it just makes it look like they have real IP addresses when they show it in the motd
Yes, because this game has very few people to play, so usually no one can only play with the BOT
__________________
sb123 is offline
Send a message via ICQ to sb123 Send a message via MSN to sb123 Send a message via Yahoo to sb123
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 05:01.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode