Register for your free account! | Forgot your password?
Rust Cheats

Go Back   elitepvpers > Popular Games > Metin2 > Metin2 Private Server > Metin2 PServer Guides & Strategies
You last visited: Today at 19:47

  • Please register to post and access all features, it's quick, easy and FREE!

Advertisement



[RELEASE] [C++] pet.is_mine-Questfunction

Discussion on [RELEASE] [C++] pet.is_mine-Questfunction within the Metin2 PServer Guides & Strategies forum part of the Metin2 Private Server category.

Reply
 
Old   #1

 
Mr. 'Avenue™'s Avatar
 
elite*gold: 222
The Black Market: 101/0/0
Join Date: Oct 2012
Posts: 2,369
Received Thanks: 3,390
[RELEASE] [C++] pet.is_mine-Questfunction

Funktion:
Gibt zurück, ob du der Besitzer des Pets bist.

Benutzungs-Beispiel:
Code:
when 34001.click with pet.is_mine() begin
Code: (questlua_pet.cpp)
Code:
	int pet_is_mine(lua_State* L)
	{
		CQuestManager& q = CQuestManager::instance();
		LPCHARACTER mch = q.GetCurrentCharacterPtr();
		LPCHARACTER tch = q.GetCurrentNPCCharacterPtr();
		CPetSystem* petSystem = mch->GetPetSystem();
		CPetActor* petActor = petSystem->GetByVID(tch->GetVID());

		lua_pushboolean(L, tch && tch->IsPet() && petActor && petActor->GetOwner() == mch);
		return 1;
	}
Mr. 'Avenue™ is offline  
Thanks
6 Users
Old 11/07/2015, 11:23   #2

 
Jinbei's Avatar
 
elite*gold: 101
Join Date: Mar 2013
Posts: 13,366
Received Thanks: 2,748
Arrow Metin2 PServer Designs, Websites & Scripts -> Metin2 PServer Gu…

#moved…
Jinbei is offline  
Thanks
1 User
Old 11/07/2015, 12:32   #3
 
elite*gold: 260
Join Date: Jan 2013
Posts: 178
Received Thanks: 104
thanks for that.

I think that you forgot to add this line.

Code:
CPetSystem* petSystem = mch->GetPetSystem();
Metin2 Team is offline  
Old 11/07/2015, 12:34   #4

 
Mr. 'Avenue™'s Avatar
 
elite*gold: 222
The Black Market: 101/0/0
Join Date: Oct 2012
Posts: 2,369
Received Thanks: 3,390
Quote:
Originally Posted by Metin2 Team View Post
thanks for that.

I think that you forgot to add this line.

Code:
CPetSystem* petSystem = mch->GetPetSystem();
ofc Added, thank you
Mr. 'Avenue™ is offline  
Old 11/07/2015, 12:39   #5
 
Mi4uric3's Avatar
 
elite*gold: 405
Join Date: Dec 2007
Posts: 6,615
Received Thanks: 6,358
Quote:
Originally Posted by Mr. 'Avenue™ View Post
Code:
	int pet_is_mine(lua_State* L)
	{
		CQuestManager& q = CQuestManager::instance();
		LPCHARACTER mch = q.GetCurrentCharacterPtr();
		LPCHARACTER tch = q.GetCurrentNPCCharacterPtr();
		CPetSystem* petSystem = mch->GetPetSystem();
		CPetActor* petActor = petSystem->GetByVID(tch->GetVID());

		lua_pushboolean(L, tch && tch->IsPet() && petActor && petActor->GetOwner() == mch);
		return 1;
	}
ofc Added, thank you
If you don't use the variable afterwards, what's the point of adding it?
Mi4uric3 is offline  
Old 11/07/2015, 13:28   #6

 
Mr. 'Avenue™'s Avatar
 
elite*gold: 222
The Black Market: 101/0/0
Join Date: Oct 2012
Posts: 2,369
Received Thanks: 3,390
Quote:
Originally Posted by Mi4uric3 View Post
If you don't use the variable afterwards, what's the point of adding it?
Es wird doch alles benutzt?
Mr. 'Avenue™ is offline  
Old 11/07/2015, 14:03   #7
 
Mi4uric3's Avatar
 
elite*gold: 405
Join Date: Dec 2007
Posts: 6,615
Received Thanks: 6,358
Quote:
Originally Posted by Mr. 'Avenue™ View Post
Es wird doch alles benutzt?
Ich bin blind. Strg+F hätte vielleicht geholfen
Mi4uric3 is offline  
Thanks
2 Users
Old 11/07/2015, 14:18   #8


 
elite*gold: 1860
Join Date: Jan 2012
Posts: 2,209
Received Thanks: 1,630
Nice hätte ich früher gebraucht, aber jetzt ist es zu spät
MaxChri is offline  
Reply

Tags
mine, pet, quest funktion, questfunction


Similar Threads Similar Threads
[R] Questfunction Collection / Extension
02/24/2014 - Metin2 PServer Guides & Strategies - 3 Replies
#closerequest
Questfunction
12/20/2013 - Metin2 Private Server - 7 Replies
Hey ich suche gerade ein How to, ich weiß nicht mehr von wem, auf jedenfall ging es darum das er neue Quest functionen hatte, mit denen man auslesen konnte, ob man z.B, eine Waffe, Helm, Kette, usw... an hat. Suche schon den ganzen morgen, hat vieleicht einer grad den Link?
Erweiterte Questfunction
12/15/2013 - Metin2 Private Server - 4 Replies
Moin Gibt es eine function, mit der man den job(also die Rasse) ändern kann z.B. von Krieger auf Ninja???
Questfunction
07/26/2012 - Metin2 Private Server - 6 Replies
Hi community, I hope that someone can help me... I'd like to use quest_function 'game.drop_item_with_ownership', but i haven't one part for this function and that's for questlib.lua.. Have someone this part? Thanks for every help and every advice.. Skurto
Wie funktioniert die questfunction?
10/23/2011 - Metin2 Private Server - 0 Replies
Heyho an alle, Ich habe da ne frage zu einem quest befehl,wo ich es nicht schafe,sie richtig auszuführen.Ich habe schon einiges probiert,getestet aber ohne erfolg. Meine frage ist nun wie führe ich den quest befehl ordnungsgemäß aus? __give_char_priv So wie ich ich gelesen hab,soll dieser befehl einem character etwas geben z.b wie exp,yang usw usw.



All times are GMT +1. The time now is 19:49.


Powered by vBulletin®
Copyright ©2000 - 2026, Jelsoft Enterprises Ltd.
SEO by vBSEO ©2011, Crawlability, Inc.

Support | Contact Us | FAQ | Advertising | Privacy Policy | Terms of Service | Abuse
Copyright ©2026 elitepvpers All Rights Reserved.