Weapon Shop & Quest NPC
Prerequisite
You should have finished the following tutorials before continuing:
Preparation
game.Workspace (NPCs):
Create two R15 rigs as follow
game.ReplicatedFirst:
game.ReplicatedStorage:
game.ServerScriptService:
game.ServerStorage:
Two folders
game.ServerStorage.Objects:
game.ServerStorage.Weapons (We will learn more about how to create different swords later):
game.ServerStorage.ScriptStorage:
game.StarterGui:
game.StarterPlayer.StarterCharacterScripts:
1. Weapon Shop
We will now edit our ShopNPC (in previous tutorial, we created it as “ShopNPC”). Make sure the ShopNPC has the following proximity prompt added:
We also needed to edit our Weapon shop GUI, which we have already created it as “ShopNPCGui” earlier:
2. Quest NPC
Here is our Quest NPC model:
And our Quest Gui:
3. Scripts
game.ReplicatedFirst.Objects.quest.QuestBtnController
game.ServerScriptService.CoinController
game.ServerScriptService.ProxPromptController
game.ServerScriptService.RewardController
game.ServerScriptService.ScriptsController
game.ServerScriptService.WeaponController
game.ServerStorage.ScriptStorage.SpawnMonster
game.ServerStorage.ScriptStorage.GuiButtonController
game.ServerStorage.ScriptStorage.QuestController
game.ServerStorage.ScriptStorage.SwordController
game.StarterPlayer.SarterCharacterScripts.GuiController
game.StarterPlayer.SarterCharacterScripts.UpdateMoneyGUI