<< Back to Programming Forum   Search

Posts 1 - 13 of 13   
Question: 2/4/2020 16:01:59


Huitzilopochtli 
Level 57
Report
Would it be possible to program a mod that allows for players to set cities in scenarios? like the cities in commerce games.
Question: 2/4/2020 16:14:38


TBest 
Level 60
Report
Yes, that is possible.

https://www.warzone.com/wiki/Mod_API_Reference:TerritoryModification
SetStructuresOpt Table<StructureType (enum),integer>: Sets the number of structures, such as cities, on this territory. Nil to simply make no changes.


This sounds like a good mod. What kind of exact behavior did you have in mind?
(Host sets some territories to start with cities? Different ways to get a city during a game? Cities can be removed by bomb card? Cities can grow?)

I think there is a lot of potential here, but let me know what you think would be cool and I might make such a mod.
Question: 2/4/2020 16:40:44


JK_3 
Level 63
Report
This sounds like a very interesting concept :)
Question: 2/7/2020 01:34:13


Huitzilopochtli 
Level 57
Report
All of those are great ideas. Especially a mod in which bomb cards destroy one city on the territory as opposed to any armies. it would also be interesting if cities that reach a certain size grant a bonus card of some sort. This way, there's more incentive to grow ''tall'' rather than ''wide'', as most players do.
Question: 2/19/2020 11:24:34


TBest 
Level 60
Report
Here is a template link to SP with the mod: https://www.warzone.com/SinglePlayer?TemplateID=1284005

It's not completed yet (and as such not set to public), as I want to add more things. However, feel free to play in SP (I don't recommend MP before I have had time to test it)

Currently cities grow. And they can be bombed. I plan on adding a def% bonus to cities based on their size. If there are other suggestions feel free to say them here!

Edited 2/19/2020 11:24:47
Question: 2/21/2020 03:17:36


Huitzilopochtli 
Level 57
Report
Yo, that's awesome! Love the idea of cities granting an increasingly larger defence bonus, while bomb cards can be used to counter-act this. This would sort of simulate city sieges. Very cool.

Edited 2/21/2020 03:36:18
Question: 2/21/2020 03:23:18


Huitzilopochtli 
Level 57
Report
I tested the mod and it gave an error message when I used a bomb card.

Also, this would be an unrelated mod, but it would be cool if different slots in a scenario could be given different starting cards. This would probably be pretty complicated to make though.

Edited 2/21/2020 03:45:08
Question: 2/21/2020 09:47:59


TBest 
Level 60
Report
Also, this would be an unrelated mod, but it would be cool if different slots in a scenario could be given different starting cards. This would probably be pretty complicated to make though.


You would need to be able to tell the slots apart*. But yeah that is not to hard. The UI would be the most annoying thing, at least if you end up with 40 * each settings.

A practical implementation would just be : if Player owned territory and armies = 1, give 1 reinforcement card. etc.)
*One easy way, is by the number of armies on a territory. Which is what I do now for capitals now.


I tested the mod and it gave an error message when I used a bomb card.

Let me know if that still happens. I tweaked how the bomb card worked around the time you might have tested it, so you might have gotten unlucky on the timings. (There was a bug where destroying a city didn't work : aka bombing to less then 1 city. That bug has been fixed)

Edited 2/21/2020 09:51:17
Question: 2/21/2020 21:25:56


Huitzilopochtli 
Level 57
Report
Still got an error message after using the bomb card on an enemy territory.
Question: 2/21/2020 21:48:31


TBest 
Level 60
Report
Hm, I am not able to produce any errors and have not had any in games with other players either. Can you tell me what the error says and what you are doing?

(If it gives a mod error, it should give a line of code and some more stuff. Example : If it's a WZ error, try to just sceenshot the top of it or something)

[string "Server_AdvanceTurn.lua"]:69: MoonSharp.Interpreter.ScriptRuntimeException: Found Dictionary, expected integer
Create (External Function)
(Unknown Function) (Server_AdvanceTurn.lua:69)

GameID=20875338
Hook=Server_AdvanceTurn_Order


If it is that ^ error then it's fixed and you are somehow using an old version. Not sure how caching works for mods in SP, but that could be what is happening. I think you can refresh it, by deselecting the mod from settings. leaving the mod settings, then go back and re-select it. (You want to be able to see a 'Downloading Mods' circle. It's a fast loading thing)

PS. Feel free to invite me to a game

Edited 2/21/2020 21:53:08
Question: 2/21/2020 22:12:07


Huitzilopochtli 
Level 57
Report


Edited 2/22/2020 01:21:44
Question: 2/22/2020 01:07:07


DanWL 
Level 63
Report
^That's not an image
Question: 2/23/2020 04:43:58


Huitzilopochtli 
Level 57
Report
All I do is load up a game and play a bomb card on an enemy territory turn one. It gives me a generic warzone error and doesn't mention the mod at all.
Posts 1 - 13 of 13