Jump to content

Metin2Place

Banned
  • Posts

    141
  • Joined

  • Last visited

  • Feedback

    0%

Posts posted by Metin2Place

  1. After some teleportations I always get a client crash.

    I tried with debug mode and once stopped in void spherepack.h line 186: assert( radius <= GetRadius()+0.0001f ); https://metin2.download/picture/FQ6IWrnUlW70K4nbr7rWB1gj0Qd3zanv/.jpg

    Other time I got only this https://metin2.download/picture/Dh10T4v9FneOSjb62RQOTUsy7NwDDP5H/.jpg

     

    Any ideas?

    • Good 1
  2. On 1/29/2020 at 12:16 AM, Clyde said:

      

     

    If someone got this error:
    Change:

    
    static constexpr auto DiscordClientID = "667352913621942276"; //Change

    To:
     

    
    static const auto DiscordClientID = "667352913621942276"; //Change

    (use your DiscordClientID of course)

    Use these libs:

    This is the hidden content, please


    These are the only libs that worked for me

    I have your errors too. From where do you have those libs?

    • Metin2 Dev 1
    • Think 2
  3. I implemented this offline shop 

    This is the hidden content, please
    .

    At first If i hide them and clicked on a position where they are, the shop will open.

    I made this change in PythonPlayerInput.cpp void CPythonPlayer::__OnClickActor(CInstanceBase& rkInstMain, DWORD dwPickedActorID, bool isAuto):

    if (rkInstVictim.IsNPC())
    {
    #ifdef ENABLE_HIDE_SHOPS
    if ((rkInstVictim.GetRace() == 30000 || rkInstVictim.GetRace() == 30001) && CPythonSystem::Instance().IsHideShops())
    return;
    #endif
    __SendClickActorPacket(rkInstVictim);
    }

    Now only if I click it quickly near me and they are shops, they will open. So it partially fix the problem. Anyone know how to fully fix it?

    • Metin2 Dev 7
  4. In PythonPlayerInput.cpp void CPythonPlayer::__OnClickActor(CInstanceBase& rkInstMain, DWORD dwPickedActorID, bool isAuto) you must replace

    	if (rkInstVictim.IsNPC())
    	{
    		__SendClickActorPacket(rkInstVictim);
    	}

    with

     

    	if (rkInstVictim.IsNPC())
    	{
    #ifdef ENABLE_HIDE_SHOPS
    		if (rkInstVictim.GetRace() == 30000 && CPythonSystem::Instance().IsHideShops())
    			return;
    #endif
    		__SendClickActorPacket(rkInstVictim);
    	}

     

  5. 5 minutes ago, Syreldar said:

    ?

     

    Well it depends wether or not the pc_mount_bonus function allows the player to have multiple AFFECT_MOUNT_BONUS.

    Assuming it does, turn the bonus arg from a simple int into a table, then iterate through the same table and assign a mount bonus for each one, very easy.

     


    I don't think it does.

     

    int pc_mount_bonus(lua_State* L)
    	{
    		BYTE applyOn = static_cast<BYTE>(lua_tonumber(L, 1));
    		long value = static_cast<long>(lua_tonumber(L, 2));
    		long duration = static_cast<long>(lua_tonumber(L, 3));
    
    		LPCHARACTER ch = CQuestManager::instance().GetCurrentCharacterPtr();
    
    		if( NULL != ch )
    		{
    			ch->RemoveAffect(AFFECT_MOUNT_BONUS);
    			ch->AddAffect(AFFECT_MOUNT_BONUS, aApplyInfo[applyOn].bPointType, value, AFF_NONE, duration, 0, false);
    		}
    
    		return 0;
    	}

     

  6. Hello, I am looking for a quest for the mounts with multiple bonuses.

    Atm I have this quest for the mounts with 1 bonus.

    -------------------------------
    -- SERVERFILE BY HOPE v2 
    -------------------------------
    quest ride begin
    	state start begin
    		function Ride( vnum, remain_time )
    			ride_info = {
    				[71114] = { 20110,	5*60,					apply.DEF_GRADE_BONUS,	75,		75,	true	},
    				[71115] = { 20110,	item.get_socket(2)*60,	apply.DEF_GRADE_BONUS,	100,	75,	false	},
    				[71116] = { 20111,	5*60,					apply.DEF_GRADE_BONUS,	100,	80,	true	},
    				[71117] = { 20111,	item.get_socket(2)*60,	apply.DEF_GRADE_BONUS,	150,	80,	false	},
    				[71118] = { 20112,	5*60,					apply.DEF_GRADE_BONUS,	125,	85,	true	},
    				[71119] = { 20112,	item.get_socket(2)*60,	apply.DEF_GRADE_BONUS,	200,	85,	false	},
    				[71120] = { 20113,	5*60,					apply.ATT_GRADE_BONUS,	200,	85,	true	},
    				[71121] = { 20113,	item.get_socket(2)*60,	apply.ATT_GRADE_BONUS,	300,	85,	false	},
    			
    				[71124] = { 20114,	item.get_socket(2)*60,	apply.EXP_DOUBLE_BONUS,	20,	1,	false	},
    				[71125] = { 20115,	item.get_socket(2)*60,	apply.ATTBONUS_MONSTER,	20,		20,	false	},
    				[71126] = { 20116,	item.get_socket(2)*60,	apply.DEF_GRADE_BONUS, 200,	85,	false	},
    				[71127] = { 20117,	item.get_socket(2)*60,	apply.CRITICAL_PCT,	10,	20,	false	},
    				[71128] = { 20118,	item.get_socket(2)*60,	apply.MALL_DEFBONUS,	10,	20,	false	},
    
    				[71131] = { 20119,  item.get_socket(2)*60,	apply.MOV_SPEED, 60,	1,	false	},
    				[71132] = { 20119,  item.get_socket(2)*60,	apply.MOV_SPEED, 60,	1,	false	},
    				[71133] = { 20119,  item.get_socket(2)*60,	apply.MOV_SPEED, 60,	1,	false	},
    				[71134] = { 20119,  item.get_socket(2)*60,	apply.MOV_SPEED, 60,	1,	false	},
    				[20233] = { 20432,  item.get_socket(2)*60,	apply.MOV_SPEED, 60,	1,	false	},
    				
    				[71161] = { 20219,	item.get_socket(2)*60,	apply.MOV_SPEED,	60,		1,	false,	false,	false},
    				[71164] = { 20220,	item.get_socket(2)*60,	apply.MOV_SPEED,	60,		1,	false,	false,	false},
    				[71165] = { 20221,	item.get_socket(2)*60,	apply.MOV_SPEED,	60,		1,	false,	false,	false},
    				[71166] = { 20222,	item.get_socket(2)*60,	apply.MOV_SPEED,	60,		1,	false,	false,	false},
    			
    				[71171] = { 20227,	item.get_socket(2)*60,	apply.MOV_SPEED,	60,		1,	false,	false,	false},
    				[71172] = { 20226,	item.get_socket(2)*60,	apply.MOV_SPEED,	60,		1,	false,	false,	false},
    				[71176] = { 20231,	item.get_socket(2)*60,	apply.MOV_SPEED,	60,		1,	false,	false,	false},
    				[71177] = { 20232,	item.get_socket(2)*60,	apply.MOV_SPEED,	60,		1,	false,	false,	false},
    			}
    
    			if pc.level < ride_info[vnum][5] then
    				syschat("Nivelul tau este prea mic.")
    			else
    				if 112 == pc.get_map_index() then
    					return
    				end
    				if ride_info[vnum][2] == 0 and remain_time != 0 then
    					pc.mount( ride_info[vnum][1], remain_time*60 )
    					pc.mount_bonus( ride_info[vnum][3], ride_info[vnum][4], remain_time*60 )
    				else
    					pc.mount( ride_info[vnum][1], ride_info[vnum][2] )
    					pc.mount_bonus( ride_info[vnum][3], ride_info[vnum][4], ride_info[vnum][2] )
    				end
    
    				if true == ride_info[vnum][6] then
    					pc.remove_item(vnum, 1)
    				end	
    			end	
    		end
    
    		when login begin
    			local vnum, remain_time = pc.get_special_ride_vnum()
    			if vnum <=  71113 or vnum >71121 then
    				return
    			end
    			if 0 != vnum then
    				ride.Ride(vnum, remain_time)
    			end
    		end
    
    		when 71114.use or 71115.use or 71116.use or 71117.use or 71118.use or 71119.use or 71120.use or 71121.use 
    				or 71171.use or 71172.use or 71161.use or 71164.use or 71165.use or 71166.use or 71131.use or 71132.use or 71133.use or 71134.use or 71124.use or 71125.use or 71126.use or 71127.use or 71128.use or 20233.use or 71176.use or 71177.use  begin
    			if pc.is_polymorphed()==true then
    				syschat("Nu poti calari cât timp esti transformat.")
    				pc.remove_polymorph()
    				return
    			elseif pc.get_map_index()== 113 or pc.get_map_index()== 114 or pc.get_map_index()== 1100000 then
    				syschat("Nu poti calari in aceasta harta.")
    				return
    			elseif false == pc.is_riding() then
    			 	if true == horse.is_summon() then
    					horse.unsummon()
    				end
    				ride.Ride(item.vnum, 0)
    			else
    				syschat("Deja calaresti un animal.")
    			end
    		end
    		
    		when login with pc.get_map_index()== 1100000 begin
    			if true == pc.is_riding() then
    				horse.unride()
    				horse.unsummon()
    			end
    		end
    		
    	end
    end

     

×
×
  • 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.