MCSmash/Super Smash Craft Beta (Bug fixes! Per-arena item management!)
#2
Cool, another minigameBig Grin

I manged to create an actual double jump some time ago. If I remember correctly the code looked something like this:
-- This goes somewhere where the player would join the arena
Player:SetCanFly(true)



-- The OnPlayerMoving hook
function OnPlayerMoving(a_Player, a_OldPosition, a_NewPosition)
	-- I don\'t know how your plugin checks if the player has joined an arena, so I\'ll do this for now.
	if (not IsInArena(a_Player)) then
		return false
	end
	
	-- Check if the player is flying
	if (not a_Player:IsFlying()) then
		return false
	end
	
	a_Player:SetFlying(false)
	a_Player:SetSpeedY(10) -- Set a proper jump height here
end
Reply
Thanks given by:


Messages In This Thread
RE: MCSmash/Super Smash Craft Beta - by NiLSPACE - 01-19-2015, 04:20 AM
RE: MCSmash/Super Smash Craft Beta - by NiLSPACE - 01-19-2015, 04:35 AM
RE: MCSmash/Super Smash Craft Beta - by NiLSPACE - 01-19-2015, 04:48 AM
RE: MCSmash/Super Smash Craft Beta - by NiLSPACE - 01-19-2015, 04:56 AM
RE: MCSmash/Super Smash Craft Beta - by tonibm19 - 01-19-2015, 05:56 AM
RE: MCSmash/Super Smash Craft Beta - by xoft - 01-19-2015, 07:40 AM



Users browsing this thread: 1 Guest(s)