Jump to content

for i in xrange all time zero why?


Recommended Posts

    def __RefreshExinvenSlotState(self):
    
        inventory_max = player.GetExtendInvenMax()
                
        for i in xrange(player.INVENTORY_PAGE_SIZE):
        
            slotNumber = self.__InventoryLocalSlotPosToGlobalSlotPos(i)
            
            if slotNumber >= inventory_max:
                self.wndItem.LockSlot(i)
            else:
                self.wndItem.UnlockSlot(i)    


player.INVENTORY_PAGE_SIZE = 45

but all time
i = 0
what is problem?
 

badass hei GIF

Link to comment
Share on other sites

  • Replies 4
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

@WeedHex I know but not working.

normal is ->
for i in xrange(45):
1,2,3,4,5.. 45

but my document is
for i in xrange(45):
0,0,0,0,0...0

 

My files all try

for i in xrange(45):
print(i)

0,0,0,0,0...

and

for i in xrange(45)
print(2*i)

0,2,4,6,8,10...

and

for i in xrange(45)
print(1*i)

0,0,0,0,0,0

and

for i in xrange(45)
print((2*i)/2)

0,0,0,0,0,0

and

for i in xrange(45)
print(i+1)

1,1,1,1,1,1

and

for i in xrange(45)
print(2*i-1)

-1,1,3,5,7

Not Understand Help Please!

badass hei GIF

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

Announcements



×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.