How should i start a fighting game with Movesets?

Hello everyone,I am making a fighting game but i wanted the player to have new options in the game like custom movesets.

  • First how should the animations be played in ServerSide or Client

  • Second How can the player choose them?

  • Third Should i make a module script for each combat move like punching?


Thanks in advance for any help .

2 Likes

Probably best to play animations on the client, first ensuring they are preloaded so there isn’t delay when they are played. This way you can synchronise them with any visual effects (which should also be handled client-side).

The module approach makes sense, especially if you’re going to be mixing and matching different moves.

With this approach, you can store a pointer to each of the players moves in a table on the server.

For example, let’s say I’m allowed four moves and move modules are stored in replicated storage - my table would look like this:

local movesets = {}
local moves = game.ReplicatedStorage.Moves
movesets[game.Players.goldenguy9] = {
	[1] = moves["Strong Left"],
	[2] = moves["Rapid Punches"],
	[3] = moves["Grand Javelin"],
	[4] = moves["Rising Thunder"]
}

Then, if a player sends a request to change a move, I could first validate it and then change it in their table.

movesets[game.Players.goldenguy9][2] = moves["Sightless Beam"]
4 Likes

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.