WCS is a handy framework that provides useful abstraction for your combat systems. It allows you to create any kind of combat system with ease, providing tools and covering basic and tedious stuff, like replication, skill creation, side effects, requests to server.
WCS is made utilizing Typescript and compiled to luau using roblox-ts. It supports both roblox-ts and luau usage,
by prodiving type definitions for both languages.
can you provide a version of the download link that doesn’t use github? some of us (me) are completely unfamiliar with github and don’t know how to use it
Changes:
• Fixed hard moveset replication bug + moveset not being cleared fully.
• Cleanup Unit Tests
• Fixed a bug where janitor won’t cleanup on client
what is the difference between OnStartServer() and OnConstructServer()? because on my sprint test script the OnConstructServer runs as soon as the game starts and OnStartServer didnt
– Services
local ReplicatedStorage = game:GetService(“ReplicatedStorage”)
local Debris = game:GetService(“Debris”)
– WCS Framework
local WCS = require(ReplicatedStorage.Libs.CombatFW[“wcs-framework”])
local SpeedBoost = require(ReplicatedStorage.Combat.StatusEffects.SpeedBoost)
local Sprint = WCS.RegisterHoldableSkill(“Sprint”)
function Sprint:OnConstructServer()
self:SetMaxHoldTime(nil)
end
function Sprint:OnStartServer()
SpeedBoost.new(self.Character):Start()
end
You would create it inside OnConstructServer, set DestroyOnEnd to false and re-use it like this:
– Services
local ReplicatedStorage = game:GetService(“ReplicatedStorage”)
local Debris = game:GetService(“Debris”)
– WCS Framework
local WCS = require(ReplicatedStorage.Libs.CombatFW[“wcs-framework”])
local SpeedBoost = require(ReplicatedStorage.Combat.StatusEffects.SpeedBoost)
local Sprint = WCS.RegisterHoldableSkill(“Sprint”)
function Sprint:OnConstructServer()
self:SetMaxHoldTime(nil)
self.SprintingStatus = SpeedBoost.new(self.Character)
self.SprintingStatus.DestroyOnEnd = false
end
function Sprint:OnStartServer()
self.SprintingStatus:Start()
end
function Sprint:OnEndServer()
self.SprintingStatus:End()
end
return Sprint