Anyone tell me why i keep getting a error in game? (a nil value)
function get_module_name()
return "on_player_level_up"
end
function on_player_level_up()
local lv = get_value( "level" )
local current_x = gv("x")
local current_y = gv("y")
local race = get_value( "race" )
local name = get_value("name")
save()
elseif i == 80 then
insert_item(540052, 1, 0, 1, -2147483648 )
elseif i == 100 then
insert_item(540067, 1, 0, 1, -2147483648 )
elseif i == 120 then
insert_item(540011, 1, 0, 1, -2147483648 )
elseif i == 150 then
insert_item(540055, 1, 0, 1, -2147483648 )
cprint("Du hast ein Geschenk erhalten. Bitte sieh in dein Inventar.")
notice("<#DB1B1B>Herzlichen Glückwunsch "..name.." Du hast Level 150 erreicht!")
elseif i == 160 then
cprint("Du hast ein Geschenk erhalten. Bitte sieh in dein Inventar.")
notice("<#DB1B1B>Herzlichen Glueckwunsch "..name.." zu Level 160! Mach weiter so. ^^")
elseif i == 165 then
cprint("Du hast ein Geschenk erhalten. Bitte sieh in dein Inventar.")
notice("<#DB1B1B>Der grosse Suchti "..name.." hat Level 165 erreicht! Gratulation")
elseif i == 170 then
cprint("Du hast ein Geschenk erhalten. Bitte sieh in dein Inventar.")
notice("<#DB1B1B>UNGLAUBLICH! "..name.." hat tatsaechlich Level 170 erreicht!!!")
elseif i == 175 then
cprint("Du hast ein Geschenk erhalten. Bitte sieh in dein Inventar.")
notice("<#DB1B1B>Hammer! "..name.." hat wirklich Level 175 erreicht!!!")
elseif i == 180 then
cprint("Du hast ein Geschenk erhalten. Bitte sieh in dein Inventar.")
notice("<#DB1B1B>LOL! "..name.." hat soeben LVL 180 geschafft,auf gehts die 190 wartet auf dich!!")
1. id like to say it sucks that not one person has answered me in 3-4 days,
Isn't this a help area? Maybe people should stop being snobs and stop thinking of them selves and start helping others
2. also, why offer help for a price if your not going to do it, even after i offered to pay your price, then you just ignore me. wtf makes you that much better then me, is it to hard to at least give a answer. where you ever taught manners?
3. so my server has been running, now all of a sudden one of my players pets show a ?, even when traded to another player you still see a ?, but no other players have had this issue. has anyone else ever had this problem and is there a way to fix it?
Thank you again
Just about eeeeeverything there is to know about LUA's in Rappelz has been covered in this forum. Further more, the best teacher for LUA is, in fact, the LUA's themselves. If you had bothered to search a bit and apply yourself to learning how it functions you might have found your answer. But, like most of what comprises this once great community you, like most others, ask for it to be handed to you and piss and moan when you receive no reply. Everyone here who knows anything about the subject, or anything useful at all in this community, learned by example, trial, and error. Follow suit or f$%k off.
Having said that here's a free lesson:
I'll admit, I didn't really read your lua, however, this is most likely your nil value:
Code:
local lv = get_value( "level" )
I don't know what you're playing at with max level reached, but the best way to buff a player with certain buffs is to check the current level. Make a function of that, then put referances to that function in on player dead, on player level up, and on login.
In the following example we get a players level and, provided he meets the parameters we defined, buff him:
Code:
function BuffDeseBitches()
local lv = get_value("lv")
if lv >= 1 and lv <= 19 then
add_state(state id, state level, state time)
end
end
In this example we do the same, but check his class instead:
Code:
function BuffDeseBitches()
local class = get_value("job")
if class == 320 then
add_state(state id, state level, state time)
end
end
Finally add reference to this function in the above mentioned LUA's:
Code:
BuffDeseBitches()
Do this for every class and or level range you'd like and you're golden.
If you can't do simple lua, please, for the love of god, do not open a server. You are not ready for the complexity of running a live server much less providing fun and unique content. Take the time to learn what you must or get a knowledgeable team together. There plenty enough shit servers out there. Don't add to the rubbish!
They're both right, you know. It's funny, there is now more information on how the server files and client work, more documentation on how to edit them, and more tools, scripts, and guides than there have ever been on this section. So much information it would make my head explode. And still, somehow, there are more new posts asking for handouts every single day. It is simply unbelievable. The more you give people the further they stick their hands out.
Just about eeeeeverything there is to know about LUA's in Rappelz has been covered in this forum. Further more, the best teacher for LUA is, in fact, the LUA's themselves. If you had bothered to search a bit and apply yourself to learning how it functions you might have found your answer. But, like most of what comprises this once great community you, like most others, ask for it to be handed to you and piss and moan when you receive no reply. Everyone here who knows anything about the subject, or anything useful at all in this community, learned by example, trial, and error. Follow suit or f$%k off.
Having said that here's a free lesson:
I'll admit, I didn't really read your lua, however, this is most likely your nil value:
Code:
local lv = get_value( "level" )
I don't know what you're playing at with max level reached, but the best way to buff a player with certain buffs is to check the current level. Make a function of that, then put referances to that function in on player dead, on player level up, and on login.
In the following example we get a players level and, provided he meets the parameters we defined, buff him:
Code:
function BuffDeseBitches()
local lv = get_value("lv")
if lv >= 1 and lv <= 19 then
add_state(state id, state level, state time)
end
end
In this example we do the same, but check his class instead:
Code:
function BuffDeseBitches()
local class = get_value("job")
if class == 320 then
add_state(state id, state level, state time)
end
end
Finally add reference to this function in the above mentioned LUA's:
Code:
BuffDeseBitches()
Do this for every class and or level range you'd like and you're golden.
If you can't do simple lua, please, for the love of god, do not open a server. You are not ready for the complexity of running a live server much less providing fun and unique content. Take the time to learn what you must or get a knowledgeable team together. There plenty enough shit servers out there. Don't add to the rubbish!
They're both right, you know. It's funny, there is now more information on how the server files and client work, more documentation on how to edit them, and more tools, scripts, and guides than there have ever been on this section. So much information it would make my head explode. And still, somehow, there are more new posts asking for handouts every single day. It is simply unbelievable. The more you give people the further they stick their hands out.
Thank you for your repsonce,
Still having issues, Not sure wtf im doing wrong.
So on this note, since everyone is tired of doing free work
Im offering to pay for help, YES PAY!!! for your time.
For someone to help me better myself and my server.
I am creating a "Collection" system which will involve props needing to respawn after their use. (This is the only way to place a cooldown on them when using activate_id: 6901 [Collecting])
However the only way to naturally place a prop on the map (not /run add_field_prop(70000, 0, gv("x"), gv("y"), 0 , 0, 0, 0, 0, 1, 1, 1)) is to edit the qpf. I am just wondering if c1ph3r/glandu or anyone else may be able to hint to the structure of the qpf?
Edit:
I believe I have figured out the QPF structure: (Correct me if I am wrong)
But I remember c1ph3r claiming that qpf/in-game coords (x/y) are different. That you must apply some math to the qpf coords to get in-game coords. (Something like (qpf_coord * map_length)+200=in_game_coord) can anyone clear this up?
I am creating a "Collection" system which will involve props needing to respawn after their use. (This is the only way to place a cooldown on them when using activate_id: 6901 [Collecting])
However the only way to naturally place a prop on the map (not /run add_field_prop(70000, 0, gv("x"), gv("y"), 0 , 0, 0, 0, 0, 1, 1, 1)) is to edit the qpf. I am just wondering if c1ph3r/glandu or anyone else may be able to hint to the structure of the qpf?
Edit:
I believe I have figured out the QPF structure: (Correct me if I am wrong)
But I remember c1ph3r claiming that qpf/in-game coords (x/y) are different. That you must apply some math to the qpf coords to get in-game coords. (Something like (qpf_coord * map_length)+200=in_game_coord) can anyone clear this up?
Hmm perhaps I'm a little bit drunken today...but hey...
Structure is looking fine if i remember correct
1 Mapfile ingame = 16128x16128 rest should be easy since the position of the mapfile is in the name.
Hmm perhaps I'm a little bit drunken today...but hey...
Structure is looking fine if i remember correct
1 Mapfile ingame = 16128x16128 rest should be easy since the position of the mapfile is in the name.
I know I am pushing my luck here, but I am not grasping "1 Mapfile ingame = 16128x16128 rest should be easy since the position of the mapfile is in the name." Mind giving me a little hint to the formula?
I know I am pushing my luck here, but I am not grasping "1 Mapfile ingame = 16128x16128 rest should be easy since the position of the mapfile is in the name." Mind giving me a little hint to the formula?
There is no factor if i remember correct since the qpf coords are "ingame coords" means: for x if qpf 005_001 4x16128+x of qpf
and you should check if the coordinates are mirrored if this isn't working for you.
yes it's likely to have no factor as from what we can see in your screen, all coords are < 16k
I think he wanted to say this formula:
for a file m<rx>_<ry>.qpf
where rx and ry are region x & y
the absolute position is
absoluteX = (rx-1)*16128 + x
absoluteY = (ry-1)*16128 + y
but if it's like this, it's more likely to be that:
absoluteX = rx*16128 + x
absoluteY = ry*16128 + y
as m000_000 exist (so rx-1 would be -1 which is wrong)
where x & y is what you have in your quest prop file
so as your exact math
absoluteX = 7 * 16128 + 533 = 113429 => very close to what you have in game
absoluteY = 7 * 16128 + 7129 = 120025 => WTF ?? I have to use 7 instead of 4. Is this file be m007_007 instead ?
I think I understood where you were coming from, i have no clue why my dumbass was using 7 on both instead of 4 on the y. So I have updated my setup to:
[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""