Extra commands(alpha 0.1)

User avatar
Neon
Member
 
Posts: 119
Joined: Thu Aug 15, 2013 02:03
In-game: Neon

by Neon » Tue Oct 22, 2013 21:02

Zombie Thread...

It looks like you'd have to create the file init.lua in the folder 'mods/extracmds' with the contents from above code snippit
 

User avatar
Menche
Member
 
Posts: 994
Joined: Sat Jul 02, 2011 00:43

by Menche » Tue Oct 22, 2013 21:21

Element wrote:where do i put this code
--snip--


Make a folder in your mods folder, and in there paste the code into a file named "init.lua".
An innocent kitten dies every time you top-post.
I am on the Voxelands Forums more often than here.
Try Voxelands (forked from Minetest 0.3) by darkrose
 

User avatar
Element
Member
 
Posts: 269
Joined: Tue Jun 11, 2013 00:27
IRC: Elementwing4962
In-game: Elementwing4962

by Element » Tue Oct 22, 2013 21:24

which mod folder, the one under minetest game or the other one
Menche wrote:
Element wrote:where do i put this code
--snip--


Make a folder in your mods folder, and in there paste the code into a file named "init.lua".
Join Me And My Team - thornfyregaming-mc.noip.me:25565

My Server Is 1.7.9
 

User avatar
LionsDen
Member
 
Posts: 525
Joined: Thu Jun 06, 2013 03:19

by LionsDen » Wed Oct 23, 2013 01:38

If you want to be able to turn it on or off, the one under the main folder. The one under the game folder will only work when that game is used.
 

User avatar
Element
Member
 
Posts: 269
Joined: Tue Jun 11, 2013 00:27
IRC: Elementwing4962
In-game: Elementwing4962

by Element » Wed Oct 23, 2013 19:41

what do i name the folder
Join Me And My Team - thornfyregaming-mc.noip.me:25565

My Server Is 1.7.9
 

User avatar
Element
Member
 
Posts: 269
Joined: Tue Jun 11, 2013 00:27
IRC: Elementwing4962
In-game: Elementwing4962

by Element » Wed Oct 23, 2013 22:23

hello...any help here
Join Me And My Team - thornfyregaming-mc.noip.me:25565

My Server Is 1.7.9
 

User avatar
Topywo
Member
 
Posts: 1718
Joined: Fri May 18, 2012 20:27

by Topywo » Wed Oct 23, 2013 23:25

Element wrote:what do i name the folder


Whatever you like as long it follows the naming conventions. Try:

extracommands or
xtracommands
 

User avatar
Element
Member
 
Posts: 269
Joined: Tue Jun 11, 2013 00:27
IRC: Elementwing4962
In-game: Elementwing4962

by Element » Wed Oct 23, 2013 23:33

both dont work
Join Me And My Team - thornfyregaming-mc.noip.me:25565

My Server Is 1.7.9
 

User avatar
Topywo
Member
 
Posts: 1718
Joined: Fri May 18, 2012 20:27

by Topywo » Wed Oct 23, 2013 23:47

Element wrote:both dont work


https://dl.dropboxusercontent.com/u/65428713/extracommands.zip

Works like a charm.

Use:
/afk
/spawn
 

User avatar
LuxAtheris
Member
 
Posts: 169
Joined: Fri Oct 25, 2013 00:54

by LuxAtheris » Wed Oct 30, 2013 13:42

Still wanna continue this mod?
Believe you can and you’re halfway there.
 

User avatar
Dan Duncombe
Member
 
Posts: 904
Joined: Thu May 09, 2013 21:11

by Dan Duncombe » Wed Oct 30, 2013 13:46

The guy who made this is banned you know!
Some Mods: Castles Prefab Camouflage
My Games: Nostalgia Realtest Revamped
Servers: See above games.
 

AnFiadhChu
Member
 
Posts: 13
Joined: Thu Dec 19, 2013 18:16
GitHub: AnFiadhChu
IRC: AnFiadhChu
In-game: AnFiadhChu

by AnFiadhChu » Thu Dec 19, 2013 18:20

sfan5 wrote:
Utilisatrice wrote:Script work 100%.

But maybe you should do a command indicating that the player no longer have afk.

Exemple :

/afk => Utilisatrice is now afk.

When i type /afk again => Utilisatrice do not have afk.

Good Idea


Done:

spawn = {x = 50, y = 1, z = 92}

minetest.register_on_chat_message(function(name, message, playername, player)
local cmd = "/spawn"
if message:sub(0, #cmd) == cmd then
if message == '/spawn' then
local player = minetest.env:get_player_by_name(name)
minetest.chat_send_player(player:get_player_name(), "Teleporting to spawn...")
player:setpos(spawn)
return true --deds to sfan5
end
end

local cmd ="/afk"
if message:sub(0, #cmd) == cmd then
if message == '/afk' then
local player = minetest.env:get_player_by_name(name)
minetest.chat_send_all(name.." is AFK! ")
return true --deds to sfan5
end
end

local cmd ="/not afk"
if message:sub(0, #cmd) == cmd then
if message == '/not afk' then
local player = minetest.env:get_player_by_name(name)
minetest.chat_send_all(name.." is NOT AFK! ")
return true --added by AnFiadhChu
end
end
end)

--Deds to Kahrl
minetest.register_on_newplayer(function(player)
player:setpos(spawn)
return true
end)

--Deds to Kahrl
minetest.register_on_respawnplayer(function(player, pos)
player:setpos(spawn)
return true
end)
Last edited by AnFiadhChu on Thu Dec 19, 2013 18:20, edited 1 time in total.
 

Previous

Return to WIP Mods

Who is online

Users browsing this forum: No registered users and 24 guests

cron