Please login or register.

Login with username, password and session length
Advanced search  

News:

Planet Explorers Released!

Author Topic: How to Customize A Scenario - A Case Step by Step  (Read 3052 times)

Katherine

  • Administrator
  • Enlistee
  • *****
  • Karma: 1
  • Posts: 10
    • View Profile
How to Customize A Scenario - A Case Step by Step
« on: April 08, 2016, 08:04:09 AM »

In our last tutorial guide How to create a custom game we only had a quick introduction on the story editor. Now since the story editor is officially published, then let's walk through a real case step by step together on how to customize a story.

First you need to know a custom game/scenario ALWAYS contains at least ONE MAP. Click here to know how to create a map. 

In today's case, NPC Gerdy will ask the player to fetch water. So the steps should be:

1.   Open an existing map by click File -> Open Project in world editor.


2.   Add NPC Gerdy into the map. You will need to write down three numbers in this step.
a.   Identity ID: Select Gerdy and click Windows -> Property View. Write down Identity ID 104.


b.   Coordinate for Gerdy: Move your cursor onto NPC Gerdy. Take a note of Gerdy’s coordinate in Minimap for our further reference (304, 27, 146). Or you can click Windows -> Transform to get a more accurate coordinate.


c.   Coordinate for Players: The start location for each player are also necessary. In this case, let's set the start location nearby NPC Gerdy, for instance (307, 26, 142).
 
3.   Open Story Editor by clicking Tool -> Custom Game. Create a new scenario in an empty folder (for instance: Scenario Sample).


After the scenario project successfully created, you will see the Worlds project page with other two tabs – Scenario Sample and Forces and Players.



4.   In Worlds project page, add at least one map into this scenario (one scenario can contain multiple maps). Make sure your map is Published. See how to publish your map in How to create a custom game. In this case, just click Add Current Map.


5.   In Forces and Players page, fill in the start position of NPC and the player. The number before the coordinate represent the world number. Controller represents races and stand of objects in this game. Click Add New Player to add more players.


PS: Now you can publish and run your scenario already, if you just want to test the map.
 
7.   Scenario Sample page is where we can edit the story. Before we start to write the story, we need to understand two concepts in story editing - Mission and Trigger. Trigger triggers mission; missions constitute story/scenario.

Right after we created the scenario successfully, a Core Mission will be auto-generated. It is used to activate the first mission.


In today’s case, we will only need one mission – talk to Gerdy and fetch some water. So click the plus sign on the top right corner to create a new mission – Mission Name: Mission 1, Mission ID: 1001.


8.   Click Core Mission and then a panel will show up on the right side of this page.
You can edit the name, description and the type of this mission. Type determines the mission is main story, side quest or hidden mission. In this game, the hidden mission will not be shown in the UI.


9.   Double click Core Mission to open the editing page. Click the plus sign on the top right corner to create a new trigger.


Edit Event, Condition and Action.
Event: add in Interaction Template. Click Object to type in Gerdy’s Identity ID 104.



Condition: Always.


Action: Run Mission. Choose run Mission 1 for Current player.



PS: Repeat in the right panel of the page, represents how many times the trigger needs to be run. The trigger will be invalid after Repeat decreased to 0. If this trigger needs to be activated all the time, the number of Repeat should be -1.


10.   Now let's back to the Scenario Sample page and edit Mission 1. There are four steps in Mission 1:
a.   The player communicates with Gerdy and Gerdy requires the player to fetch 20 bottles of water;
b.   Gerdy gives a water pitcher to the player;
c.   The player fetched 20 bottles of water/the player didn't fetch 20 bottles of water;
d.   Play a conversation once after the goal was achieved.
 
Double click Mission 1. To fulfill all actions above, we need two triggers. The one is to trigger the conversation and deliver the water pitcher to the player, the other one will be triggered when the player reached the goal.
 
In new trigger 1, let's name it Talk to Gerdy, the conversation happens after right click Gerdy.
a.   So in Event, it still should be On interaction (mouse right-click) with 104 Gerdy Hooke.
b.   Condition is Always.
c.   In Action page, template Play Speech is to add a conversation between Gerdy and the player. You can also set a timer for the player. Just edit the number of the time. 0 means no time limitation.



Template Modify Package is to deliver a water pitcher to the player.



Template Set Item Goal is to set a goal for the player to fetch a number of water.


In new trigger 2, let's name it Mission completed, it will verify whether goal 1 is achieved.
a.   So in Event tab, add Goal Achieve.


b.   Condition: Goal 1 of Mission 1 achieved is true.


c.   Action: add template Play Speech. So after the program has verified that goal 1 is achieved indeed, Gerdy will have another conversation with the player.

 
11.   A custom game is almost ready. Now export your story into an EMPTY folder by clicking File -> Publish Scenario. The default path for this scenario is in Publish folder under your project folder.




Copy paste the scenario folder into folder CustomGames under games directory. Then just run and enjoy your story!



Don't be shy and share your excellent story ideas. ;)

If you have any questions on this Story Editor, please don’t hesitate to leave comments below~ :-*
« Last Edit: April 08, 2016, 11:04:57 AM by Katherine »
Logged