Page 2 of 3

PostPosted: Fri Mar 28, 2014 09:07
by rubenwardy
It supports infinite teams in theory, however there is only three colors of flags given with the mod.
You could make your own flags.

Re: [Game] Capture the Flag / City VS City combat [0.2][capt

PostPosted: Thu Jul 24, 2014 18:23
by pmpeetamellark
How Do I Shoot?! Guns are not functioning even with ammo in the item selector!

Re: [Game] Capture the Flag / City VS City combat [0.2][capt

PostPosted: Thu Jul 24, 2014 18:30
by Krock
Try to reload the guns

Re: [Game] Capture the Flag / City VS City combat [0.2]

PostPosted: Sun Dec 21, 2014 19:29
by maier.nathan
Hi,
I am trying to add a player to a default team when a new player join. Any ideas how?
there's minetest.register_on_newplayer. This is for a subgame.
Thanks very much,
Bikemare

Re: [Game] Capture the Flag / City VS City combat [0.2]

PostPosted: Fri Dec 26, 2014 21:21
by CreeperLord700
ruben, i cant seem to be on a team, i do /join team singleplayer CR and team fails, i place flag and pops up " you are not part of a team!"

Re: [Game] Capture the Flag / City VS City combat [0.2]

PostPosted: Sat Dec 27, 2014 15:38
by rubenwardy
CreeperLord700 wrote:ruben, i cant seem to be on a team, i do /join team singleplayer CR and team fails, i place flag and pops up " you are not part of a team!"


It is /join team_name. Create a team using /team add team_name.

maier.nathan wrote:Hi,
I am trying to add a player to a default team when a new player join. Any ideas how?
there's minetest.register_on_newplayer. This is for a subgame.
Thanks very much,
Bikemare


Auto allocating teams is a planned feature.

Code: Select all
ctf.join(player_name, "team_name", true)


Only do it on their first join, otherwise they will change team everytime they join.

(^ You need the latest version of the source code, uploaded today 27/12/2014)

Re: [Game] Capture the Flag / City VS City combat [0.2]

PostPosted: Sat Dec 27, 2014 17:37
by rubenwardy
Added automatic allocation of players to teams.

https://github.com/rubenwardy/captureth ... 975c5960a9

Re: [Game] Capture the Flag / City VS City combat [0.3]

PostPosted: Sun Dec 28, 2014 17:59
by rubenwardy

0.3 Released!



New Features
  • Auto allocation to teams
  • Start of HUD

Logistical Changes
  • Now licensed under LGPL 2.1 or later for code, CC BY-SA 3.0 or later for textures.
  • Use vector helpers from the lua_api, rather than v3 from commonlib.
  • Change namespace from cf to ctf
  • Rename main mod to ctf and move into modpack. Also turret -> ctf_turret and protect -> ctf_protect
  • Move code around to be cleaner. Init.lua now only contains dofiles()
  • ctf.register_on_load and ctf.register_on_save for adding things to ctf.txt
  • Removed firearms
  • Cleaned lots of code styles

Bug Fixes
  • /ctf crash
  • Fix assignment to unassigned global
  • Many smaller changes

To Do
  • Fix settings data types. (all settings are strings if from minetest.conf, so are always true)
  • Skins for players
  • More colours
  • Get flag taking working better:
    • player can be seen holding the flag
    • safer flag taking (bulletproof)
    • Timers (only certain amount of time to return it.
    • How the player is stopped - add tag, drop on death and return on death options
    • Allow flags to be passed between players
  • Items:
    • Deco flags
  • Flag finder / some way for a player to locate a flag
  • Awards
  • Add more settings etc
  • Opening and closing teams to new members
  • Use privileges for team_owners

Re: [Game] Capture the Flag / City v City [0.3] - Team Alloc

PostPosted: Mon Dec 29, 2014 00:53
by sirken
Looking forward to trying this!

How do you place flags?

I'm guessing it's under the Flags button in the /team GUI, but I couldn't get it to work. I added teams (red/blue), then had players choose teams. Team owners were chosen. I opened menu with /team, and clicked the Flags button and server crashed:
Code: Select all
16:09:09: ERROR[main]: ServerError: ...ames/capturetheflag/mods/capturetheflag/ctf/core.lua:269: attempt to compare number with string
16:09:09: ERROR[main]: stack traceback:
16:09:09: ERROR[main]:    ...ames/capturetheflag/mods/capturetheflag/ctf/core.lua:269: in function '?'
16:09:09: ERROR[main]:    .../builtin/game/register.lua:348: in function <.../builtin/game/register.lua:336>


Using Minetest 0.4.10-71-g9e4e707

Thanks.

Re: [Game] Capture the Flag / City v City [0.3] - Team Alloc

PostPosted: Mon Dec 29, 2014 11:02
by rubenwardy
You place the ctf:flag node. I'll look into that bug, ot is probably a settings data type thing.

Re: [Game] Capture the Flag / City v City [0.3] - Team Alloc

PostPosted: Mon Dec 29, 2014 19:59
by rubenwardy
Fixed that bug, and possibly many others. It was a settings data type thing.

30633 (Fix setting data type issues)

Re: [Game] City v City / Capture the Flag [0.3] - Team Alloc

PostPosted: Wed Jan 14, 2015 06:34
by sirken
rubenwardy wrote:Fixed that bug, and possibly many others. It was a settings data type thing.

30633 (Fix setting data type issues)


It is working for me now, thanks for the fix.

Re: [Game] City v City / Capture the Flag [0.3] - Team Alloc

PostPosted: Wed Jan 14, 2015 21:19
by Gerald
I found a little bug. If TNT explodes near a flag, the flag does not disappear but if a mine explodes the flag disappears being still spawnpoint and in the list of flags.

Re: [Game] City v City / Capture the Flag [0.3] - Team Alloc

PostPosted: Wed Jan 14, 2015 22:05
by rubenwardy
I didn't anticipate that. I will update the traps mod to use the TNT code.

Re: [Game] City v City / Capture the Flag [0.3] - Team Alloc

PostPosted: Thu Jan 15, 2015 14:28
by Gerald
Maybe i just not found the right commands:
Is it possible to leave a team or to change team or to delete a team? If i try join another team there is the message 'joining <> to team <>' but nothing happens.

Re: [Game] City v City / Capture the Flag [0.3] - Team Alloc

PostPosted: Thu Jan 15, 2015 15:24
by rubenwardy
Try /join team-name

I haven't tested /team join playername teamname in a while.

Deleting is planned, I noticed that you couldn't do that recently. You currently can't just leave a team and not be on a team.

Re: [Game] City v City / Capture the Flag [0.3] - Team Alloc

PostPosted: Thu Jan 15, 2015 16:21
by Gerald
Thanks for the fast answer.

I wanted to construct short events like 3 vs 3 capture the flag or something like bedwars on a map, which resets after the event and the players are teleported back to spawn able to start a new event dividing different into two new teams.

Re: [Modpack] CTF PvP Engine [1.0] [ctf_pvp_engine]

PostPosted: Fri Jul 22, 2016 21:17
by ABJ
How about duels between two separate challenging team members?

Re: [Modpack] CTF PvP Engine [1.0] [ctf_pvp_engine]

PostPosted: Fri Nov 11, 2016 13:04
by Xudo
I'm trying to setup my local server for this game and getting a problem.
Teams and its members doesn't persist if I restart server.
I have made 5 players: admin, RedKing, RedSlave, BlueKing, BlueSlave and then:
admin: /team add blue
admin: /team add red
RedKing: /join red
BlueKing: /join blue
admin: /shutdown

If I run server after this and use "/t hi all" from RedKing, I would get message "You're not in a team, so you have no team to talk to".

Are they supposed to persist at all?

Re: [Modpack] CTF PvP Engine [1.0] [ctf_pvp_engine]

PostPosted: Sat Nov 12, 2016 12:38
by Xudo
I have found source of the problem. When players join to team, ctf state is not being marked as "need save". Thats why it wasn't saved.

I assume this might be an option for games with short sessions. I have added config parameter to persist team membership.
I have failed to push it to your repository and to attach a patch, though.
Code: Select all
---
 ctf/core.lua  | 1 +
 ctf/teams.lua | 3 +++
 2 files changed, 4 insertions(+)

diff --git a/ctf/core.lua b/ctf/core.lua
index fe69334..29452b1 100644
--- a/ctf/core.lua
+++ b/ctf/core.lua
@@ -146,6 +146,7 @@ function ctf.init()
    ctf._set("hud",                        true)
    ctf._set("autoalloc_on_joinplayer",    true)
    ctf._set("friendly_fire",              true)
+   ctf._set("persist_team_membership",    true)
 
 
    for i = 1, #ctf.registered_on_init do
diff --git a/ctf/teams.lua b/ctf/teams.lua
index 57ff274..bb3756c 100644
--- a/ctf/teams.lua
+++ b/ctf/teams.lua
@@ -200,6 +200,9 @@ function ctf.join(name, team, force, by)
    for i = 1, #ctf.registered_on_join_team do
       ctf.registered_on_join_team[i](name, team)
    end
+   if ctf.setting("persist_team_membership") then
+      ctf.needs_save = true
+   end
    return true
 end
 

Re: [Modpack] CTF PvP Engine [1.0] [ctf_pvp_engine]

PostPosted: Sat Nov 12, 2016 15:38
by rubenwardy
there's no need for an option, I just forgot to add it there

https://github.com/rubenwardy/ctf_pvp_e ... 58f0799d50

Re: [Modpack] CTF PvP Engine [1.0] [ctf_pvp_engine]

PostPosted: Sun Nov 13, 2016 13:08
by Xudo
I have implemented few things in your mod.
What should I do to merge them to master?
What are your requrements for testing?

Things are:
  • "/apply <team>" console command. Players can ask to join. Team managers can decide whether they should be in team or not.
  • "Petitions" tab in team interface. You can see there a list of players wanted to join and accept or reject their applications.

Re: [Modpack] CTF PvP Engine [1.0] [ctf_pvp_engine]

PostPosted: Sun Nov 13, 2016 14:29
by rubenwardy
Preferably, you should fork my repo, create a new branch there and commit your changes, then click "create pull request"

Re: [Modpack] CTF PvP Engine [1.0] [ctf_pvp_engine]

PostPosted: Mon Nov 14, 2016 17:07
by Xudo
Looks like I have figured out how to do this.

I feel really uncomfortable with changing this mod without any tests. Thats why I'm going to increase production quality of this mod.
Do you have any familiar unit-testing framework?
If not, I'll use lunatest.

Re: [Modpack] CTF PvP Engine [1.0] [ctf_pvp_engine]

PostPosted: Mon Nov 14, 2016 17:32
by rubenwardy
Yeah, tests are definitely needed

I'd buy you a coffee if you could add tests to this modpack :D