I am a scripter, I have been scripting for 4 months now. I want to give my pet system away for others to learn. I wanted to give this away cause I have transitioned from AGF to knit and using Roblox-TS now.
What is a pet system?
A pet system is usually for the simulator genre. It consist of egg opening, equipping pets (etc.).
very good source thank you, but I have a problem setting it up
error ServerScriptService.TrelloAPI:701: Roblox API not found!
how do I set up this on Trello website?
–// Trello Vairables
local PetBoardID = TrelloAPI:GetBoardID(“Roblox API”)
local PetListID = TrelloAPI:GetListID(“Pets”, PetBoardID)
I did setup the API and the token but I do not really understand how to set up the Board for the pet
I created a more user friendly system for generating the pet data for the egg hatching process. It automatically generates the correct percentage for the module, and outputs it with the correct value.
Example code:
local PetModuleBuilder = require(script.Parent:WaitForChild("PetModuleBuilder"))
local common = PetModuleBuilder:create()
common:addPet("Spirit God", 1)
common:addPet("Dog", 3)
common:addPet("Poop", 3)
local rare = PetModuleBuilder:create()
rare:addPet("Dog", 3)
rare:addPet("Poop", 3)
An example of integrating it into EggModule:
-- Egg Module
-- Username
-- January 6, 2021
local PetModuleBuilder = require(script.Parent:WaitForChild("PetModuleBuilder"))
local common = PetModuleBuilder:create()
common:addPet("Spirit God", 1)
common:addPet("Dog", 3)
common:addPet("Poop", 3)
local rare = PetModuleBuilder:create()
rare:addPet("Dog", 3)
rare:addPet("Poop", 3)
--// EVERYTHING SORTS BY COST IN INDEX.
local EggModule = {
["Common Egg"] = {
Cost = 250,
Image = 6289909588,
Rarities = common:ToEggModule()
};
["Rare Egg"] = {
Cost = 570,
Image = 6284976641,
Rarities = rare:ToEggModule()
};
}
return EggModule
I keep getting the error “Players.gk983.PlayerScripts.Aero.Controllers.PetAniController:22: attempt to index nil with ‘BodyPosition’” for some reasaon when I have a pet equipped. I checked and the primarypart indeed has the child BodyPosition. I have no idea how to fix this