DyWalk 0 Posted July 15, 2018 Share Posted July 15, 2018 Merhaba! for i in range(o-400000,o+400000): I am using such a loop, but this is causing the frost. I tried to use thread but the room does not work on metin2servers, how can we fix it? thanks for a lot Link to comment Share on other sites More sharing options...
Forum Moderator Raylee 658 Posted July 15, 2018 Forum Moderator Share Posted July 15, 2018 #moved Best regards Raylee Link to comment Share on other sites More sharing options...
Bot Metin2 Dev 4929 Posted July 15, 2018 Bot Share Posted July 15, 2018 At first: Idk. what the variable "o" stands for, but if you have to do a for-loop in range(-400000, 400000) you're probably messing something logically up. On the other hand, if you REALLY need such a big range, use clusters to split you're long list into short ones and then iterate with threads through these lists, use a while-loop, that only executes for the neccesary fields, which you have to check somehow or use a generator, which won't save the list, but which can theoratically generate infinite values for you, which you could use. I hope I could help a bit or give you some ideas. King Regards Cyber Link to comment Share on other sites More sharing options...
Premium North 1184 Posted July 15, 2018 Premium Share Posted July 15, 2018 lmao Link to comment Share on other sites More sharing options...
DyWalk 0 Posted July 16, 2018 Author Share Posted July 16, 2018 13 hours ago, Cyber36 said: At first: Idk. what the variable "o" stands for, but if you have to do a for-loop in range(-400000, 400000) you're probably messing something logically up. On the other hand, if you REALLY need such a big range, use clusters to split you're long list into short ones and then iterate with threads through these lists, use a while-loop, that only executes for the neccesary fields, which you have to check somehow or use a generator, which won't save the list, but which can theoratically generate infinite values for you, which you could use. I hope I could help a bit or give you some ideas. King Regards Cyber o=player.GetMainCharacterIndex I am scanning the distance of the character, It has to be 40k otherwise the scan may fail. I looked at the thread thread, but metin2 does not work I looked at the thread thread, but it does not work on metin2, how can we find a solution,Do you have a way of thinking? Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now