Update Adding a new NPC authored by Noah MacMinn's avatar Noah MacMinn
### As of Spring 2022: ### As of Spring 2022:
1. In PlayersForTest.java create the NPC in the enum such as: <br>
1. In [PlayersForTest.java](https://gitlab.engr.ship.edu/merlin/freshmanrpgsuite/-/tree/main/FreshmanRPG/GameShared/src/main/java/datatypes/PlayersForTest.java) create the NPC in the enum such as: <br>
`PlayersForTest(int id, String playerName, String type, int row, int col, String password, String mapName, int pin, String changedOn, int doubloons, int experiencePoints,Crew crew, Major major, int section, int buffPool, boolean online, ArrayList<String> mapsVisited)` `PlayersForTest(int id, String playerName, String type, int row, int col, String password, String mapName, int pin, String changedOn, int doubloons, int experiencePoints,Crew crew, Major major, int section, int buffPool, boolean online, ArrayList<String> mapsVisited)`
2. In NPCForTest.java add the NPC <br> 2. In [NPCForTest.java](https://gitlab.engr.ship.edu/merlin/freshmanrpgsuite/-/tree/main/FreshmanRPG/GameServer/src/main/java/datatypes/NPCsForTest.java) add the NPC <br>
`NPCsForTest(int playerID, String behaviorClass)` **OR** `NPCsForTest(int playerID, String behaviorClass)` **OR**
`NPCsForTest(int playerID, String behaviorClass, String filePath)` if the NPC has a walking path or dialog `NPCsForTest(int playerID, String behaviorClass, String filePath)` if the NPC has a walking path or dialog
...@@ -11,10 +12,6 @@ _In an NPCs behavior class, there are several options that apply for some types ...@@ -11,10 +12,6 @@ _In an NPCs behavior class, there are several options that apply for some types
4. Make a RDS and gateway if needed 4. Make a RDS and gateway if needed
#### Useful File Paths
- `/FreshmanRPG/GameShared/src/main/java/datatypes/PlayersForTest.java`
- `/FreshmanRPG/GameServer/src/main/java/datatypes/NPCsForTest.java`
### OLD: ### OLD:
There is a table in the database that keeps a list of all of the NPCs. Creating a new NPC requires filling that table. When a server starts, it will query that table for what NPCs it should have and starts them up. There is a table in the database that keeps a list of all of the NPCs. Creating a new NPC requires filling that table. When a server starts, it will query that table for what NPCs it should have and starts them up.
... ...
......