This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void CheckIdles(object sender, fCraft.Events.PlayerMovingEventArgs e) | |
{ | |
if (e.Player.IdleTime.ToSeconds() % 5 == 0 && e.Player.IdleTime.ToSeconds() == 5 && !e.Player.isSolidBlock) | |
{ | |
//Temp debug message | |
Server.Message("{0} is idle!", e.Player.ClassyName); | |
e.Player.Info.IsHidden = true; | |
e.Player.isSolidBlock = true; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static void PlayerMovedSolid(object var, fCraft.Events.PlayerMovingEventArgs e) | |
{ | |
if (e.Player.Info.isSolidBlock == false) | |
{ | |
TimeSpan idle = e.Player.IdleTime; | |
if (idle.TotalSeconds > 5) | |
{ | |
e.Player.Info.IsHidden = true; | |
e.Player.Info.isSolidBlock = true; | |
//Somehow place a block at the players current pos. block number is e.Player.Model (string) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Collections.Generic; | |
using System.Linq; | |
using System.Text; | |
namespace fCraft | |
{ | |
class PropHunt | |
{ | |
private string[] blockId = {"1", "2", "4", "5", "7", "12", "13", "17", "19", "64", "65"}; |
NewerOlder