Jump to content

avertuss

Inactive Member
  • Posts

    480
  • Joined

  • Last visited

  • Feedback

    0%

Everything posted by avertuss

  1. I know, i have that function in source but i can't compile quest XD When i just use pc.make_guild0(testguild) it work's but after relog.
  2. Hi. How to use that function in quest? I tried but i always have error in quest compile function pc.make_guild(guild_name, required_money, required_level) --[[to clean non alphanumeric characters]] local guild_name = string.gsub(guild_name, "[^A-Za-z0-9]", "") local guild_len_name = string.len(guild_name) --[[to check wrong sized names]] if not ((2 < guild_len_name) and (guild_len_name < 12)) then say_reward("The name should not have special characters and its length should be between 3-11 characters!") return end --[[to check required level]] if not (pc.get_level() >= required_level) then say_reward(string.format("Level too low. Needed: %d", required_level)) return false end --[[to check required money]] if not (pc.get_gold() >= required_money) then say_reward(string.format("Not enough money. Needed: %d", required_money)) return false end --[[to check already guilded people]] if (pc.hasguild() or pc.isguildmaster()) then say_reward("You're already inside a guild.") return end --[[to add a user-validation check]] say(string.format("Are you sure you wanna create such guild?[ENTER]%s", guild_name)) if select("Yes", "No")==2 then return false end --[[create the guild and process the return value]] local ret = pc.make_guild0(guild_name) if ret==-2 then say_reward("[NO] guild name is invalid (strlen <2 or >11!)") elseif ret==-1 then say_reward("[NO] guild name is invalid (special chars found!)") elseif ret==0 then say_reward("[NO] guild not created (guild name already present or already member of a guild)") elseif ret==1 then pc.change_gold(-required_money) say_reward("[YES] guild created") return true elseif ret==2 then say_reward("[NO] player already part of a guild") elseif ret==3 then say_reward("[NO] player already guild master") end return false end
  3. I see that it works only for character name, not for pet/mount name.
  4. char_battle.cpp: In member function 'bool CHARACTER::Damage(CHARACTER*, int, EDamageType)': char_battle.cpp:1971: error: ISO C++ forbids comparison between pointer and integer
  5. Hmm, it's msm of the mob ScriptType RaceDataScript BaseModelFileName "D:\ymir work\monster\forest_boss\forest_Boss.GR2" Group ShapeData { PathName "" ShapeDataCount 0 } Group AttachingData { AttachingDataCount 1 Group AttachingData00 { AttachingDataType 1 isAttaching 1 AttachingModelIndex 0 AttachingBoneName "Dummy02" CollisionType 3 SphereDataCount 2 Group SphereData00 { Radius 137.000000 Position 0.000000 0.000000 0.000000 } Group SphereData01 { Radius 183.000000 Position 0.000000 0.000000 150.000000 } } } Which value is height?
  6. Nice, but i have one question. How can i make that after relog character will still sit on mount?
  7. Hi. I'm using mob_scale and i have little problem with that. Mob is scaled but the name is still on the top ;/ Any ideas?
  8. Idk why but my client getting crash after login without errors in syserr when i have added python side.
  9. LPITEM pItem = pkAttacker->GetWear(WEAR_WRIST); if (pItem && pItem->GetVnum() == 16209 && pItem->IsEquipped() && pkVictim->IsNPC()) return 0; in int battle_hit(LPCHARACTER pkAttacker, LPCHARACTER pkVictim, int & iRetDam) and it doesn't work.
  10. Where should i add it? Will it work with WEAR_WRIST etc?
  11. I don't need block deal damage when item is in inventory, i want block deal damage when item is equpped.
  12. Hi. I don't see quest on the left side after relog but i have them in character window(missions). Any ideas? Ctrl + q doesn't work. Syserr client/server clean.
  13. Hi. How to block deal damage to mobs if player has weared item with vnum 12345? Something like this in battle.cpp? if (pAttacker->GetVnum() == 12345 && pkVictim->IsNPC()) { iAtk = iAtk*0.1; }
×
×
  • 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.