示例#1
0
$QuestResult03->set_val("20");
$QuestResult04 = new QuestResult();
$QuestResult04->set_key("doku");
$QuestResult04->set_val("100");
$Activity02 = new Activity();
$Activity02->set_id(2);
$Activity02->set_activityName("Mencari Makanan Favorit Para Pendekar");
//$Activity02->set_requirement(null);
$Activity02->set_result(0, $QuestResult03);
$Activity02->set_result(1, $QuestResult04);
$Activity02->set_nextActivity(0);
$Activity02->set_dialog($dialogTree02);
$Activity02->set_objectiveType(1);
$Activity02->set_action(1);
$Quest01 = new Quest();
$Quest01->set_id(1);
$Quest01->set_name("Petualangan Sang Pendekar");
//$Quest01->set_requirementQuest(null);
$Quest01->set_requirementDoku(0);
$Quest01->set_requirementFame(0);
$Quest01->set_description("Petualangan menjelajahi dunia LILO");
$Quest01->set_activities(0, $Activity01);
$Quest01->set_activities(1, $Activity02);
$playerQuest01 = new PlayerQuest();
$playerQuest01->set_id(18);
$playerQuest01->set_quest(1);
$playerQuest01->set_status(ACTIVE);
$playerQuest01->set_currentActivity(1);
$playerQuestList01 = new PlayerQuestList();
$playerQuestList01->set_playerQuests(0, $playerQuest01);
$serialized_string = $playerQuestList01->SerializeToString();