What is the "state_code" in different .lua files? (Already resolved. Its a country code, that you have in local info maybe, but i dont know where i can see my local code)
For those, who also looking some local codes :
--local tx, ty, current_x, island_number local lv = get_value( "level" ) local max_reached_level = gv( "max_reached_level" ) local state_code = get_local_info()
local i for i = max_reached_level + 1 , lv do --loop body etc end end
I dont understand, how its works : "for i = max_reached_level + 1 , lv do", cause if we take 10 lvl, our max_reached_level and lv === 10, and then for i = 11, 10 do will never work, so HOW?
OR max_reached_level inc only after this function was running?
What is the "state_code" in different .lua files? (Already resolved. Its a country code, that you have in local info maybe, but i dont know where i can see my local code)
For those, who also looking some local codes :
--local tx, ty, current_x, island_number
local lv = get_value( "level" )
local max_reached_level = gv( "max_reached_level" )
local state_code = get_local_info()
local i
for i = max_reached_level + 1 , lv do
--loop body etc
end
end
I dont understand, how its works : "for i = max_reached_level + 1 , lv do", cause if we take 10 lvl, our max_reached_level and lv === 10, and then for i = 11, 10 do will never work, so HOW?
OR max_reached_level inc only after this function was running?
simply from my understanding , the syntax defines the entry "i" as a max level .
so if you put
it means that in this code the maximum level for it is 10 , so if you reach 20 the code will not be activated because in its mind the maximum level for this reward is 10 and only.
and its fine if you put later on i==20 and put on codes of items like above it will not overlap the first define , basically the "i" represent the level given , so whatever number you put will have its own define depending on the number given after the "i"
so if you put i==15 , this will be only for lvl 15 and it will never happen to level 20 etc.
if you put two layers with same number , like this
the character will get both items 2013011&312312212.
this is really hard for me to explain but if you stare to the file 10 minutes you'll get it :P i hope that helped.
Thanks for explain, but my question is whats going on in this script, thet make it work right
Look at that :
PHP Code:
function on_player_level_up()
--local tx, ty, current_x, island_number local lv = get_value( "level" ) --lv now = 10 local max_reached_level = gv( "max_reached_level" ) --max_reached_level clearly also 10 ( or im wrong?) local state_code = get_local_info() -- bla-bla-bla
local i for i = max_reached_level + 1 , lv do -- for i = 10 + 1 , 10 do bla-bla --loop body NEWER done with upper condition, cause 11 > then 10 !!!! but it run and work well in game. WHY? end end
may be i dont understand syntax and "max_reached_level" in this condition "for i = max_reached_level + 1 , lv do" will be increment only AFTER then loop is done and loop begin with "max_reached_level" = 10?
Thanks for explain, but my question is whats going on in this script, thet make it work right
Look at that :
PHP Code:
function on_player_level_up()
--local tx, ty, current_x, island_number
local lv = get_value( "level" ) --lv now = 10
local max_reached_level = gv( "max_reached_level" ) --max_reached_level clearly also 10 ( or im wrong?)
local state_code = get_local_info() -- bla-bla-bla
local i
for i = max_reached_level + 1 , lv do -- for i = 10 + 1 , 10 do bla-bla
--loop body NEWER done with upper
condition, cause 11 > then 10 !!!! but it run and work well in game. WHY?
end
end
may be i dont understand syntax and "max_reached_level" in this condition "for i = max_reached_level + 1 , lv do" will be increment only AFTER then loop is done and loop begin with "max_reached_level" = 10?
well don't mind the syntax , just know this
if you put i==10, no one will get the rewards at lvl 9 or less, or 11 and higher. maybe this will convince you :P i don't know how to explain im new to .lua too but thats how it works.
if you put i==10, no one will get the rewards at lvl 9 or less, or 11 and higher.
It's not about gifts, how about the reason for the why this loop is working
UPDATE
I make little discover :
PHP Code:
--local tx, ty, current_x, island_number local lv = get_value( "level" ) --lv now = 10 local max_reached_level = gv( "max_reached_level" ) --max_reached_level NOW IS 9!!! But i dont know why =) local state_code = get_local_info() -- bla-bla-bla
How i checked that? i just make condition that i will take gifts not when i == 10, but when max_reached_level == 9 and then i lvlup for 9 AND GET NOTHING GOOD DAY SIR! but when i lvlup to 10 i take gift normaly, so that means that when i reached lvl 10, firstly this script get max_reached_level that equals previous lvl, and only then it value become equals to current lvl
May be i partially wrogn, but its works like that =)
It's not about gifts, how about the reason for the why this loop is working
UPDATE
I make little discover :
PHP Code:
--local tx, ty, current_x, island_number
local lv = get_value( "level" ) --lv now = 10
local max_reached_level = gv( "max_reached_level" ) --max_reached_level NOW IS 9!!! But i dont know why =)
local state_code = get_local_info() -- bla-bla-bla
How i checked that? i just make condition that i will take gifts not when i == 10, but when max_reached_level == 9 and then i lvlup for 9 AND GET NOTHING GOOD DAY SIR! but when i lvlup to 10 i take gift normaly, so that means that when i reached lvl 10, firstly this script get max_reached_level that equals previous lvl, and only then it value become equals to current lvl
May be i partially wrogn, but its works like that =)
let me complete the puzzle then.
in gm-tools when you put your lvl 150 , it will be 151 instead. maybe thats why in the lua there's a +1
With the 9.4 release from the revolution team there is a problem with equipment and pet durability. It doesn't allow to be repaired to the maximum, could anyone help with this please.
Have any of you experienced a limitation of movement speed in 9.4 servers / clients?
Im trying to balance some buffs on my server and every time i add any more than one speed buff i am slowed instead of moving faster
With the 9.4 release from the revolution team there is a problem with equipment and pet durability. It doesn't allow to be repaired to the maximum, could anyone help with this please.
Hi elitepvpers, i'm have problem, client crashing when open interface skill, inventory, on random time on 7.2 client arabic or other sframe, in laptop have more time, other players in this server have problems too, i'm not have ideas, you can help me?
I'm try change resolution or other settings, clear inventory and create other character, update DirectX, VC Runtime but this not helped, client have RU locale and Windows-1251 encoding, checked PL EN DE client, no results
Server url: if need for checking
In the picture this is after clicking the "repair all" button. When I try to repair a pet with empty unique soul taming card and soul shifter it fails. (Using enhance window, but also tried repair window)
[Helping Topic] 24/7 Helping Services! 08/27/2008 - EO PServer Hosting - 31 Replies stucked on anything while setuping your server?
post your problem here and you will get answer as fast as possible better than spamming with posts :cool:
first of all try reading Ahmedpotop's Pserver All thing guide.
if your couldn't solve it out post your problem down here
""That includes PHP rankings pages / registrations pages / Status pages""