-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13 from cech12/develop
- add a new mod where you can change the dropping chance of resources…
- Loading branch information
Showing
4 changed files
with
51 additions
and
1 deletion.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
45 changes: 45 additions & 0 deletions
45
Mods/DroppingResources/Data/Scripts/classes/zwerg/change_z_dignwalk.tcl
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
$if:CIV_DROPS | ||
|
||
$start | ||
$replace | ||
if {[im_in_campaign]} { | ||
set zone 0 | ||
set UMK 0;set UTP 0; set UUM 0 | ||
catch {set UMK [sm_get_event Uebergang_Met_Kris]} | ||
if {$UMK} { | ||
set zone 3 | ||
} else { | ||
catch {set UTP [sm_get_event Titanic_Pumpe_aktiviert]} | ||
if {$UTP} { | ||
set zone 2 | ||
} else { | ||
catch {set UUM [sm_get_event Uebergang_Urw_Met]} | ||
if {$UUM} { | ||
set zone 1 | ||
} | ||
} | ||
} | ||
} else { | ||
global civ_state | ||
set zone [hmax 0 [hmin [expr {int($civ_state*10.0)}] 3]] | ||
} | ||
$with | ||
global civ_state | ||
set zone [hmax 0 [hmin [expr {int($civ_state*10.0)}] 3]] | ||
$end | ||
|
||
$ifend | ||
|
||
|
||
$start | ||
$replace | ||
if {[im_in_campaign]} { | ||
set rndval 0.01 | ||
} else { | ||
set rndval 0.04 | ||
} | ||
$with | ||
set rndval [expr {$print:DROP_CHANCE / 100.0}] | ||
$end | ||
|
||
|
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
name:DroppingResources | ||
tooltip:Change dropping chance and let resources drop in dependence to your civilization level | ||
author:cech12 (idea from iGilga) |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
Var:CIV_DROPS;Type:bool;GameValue:false;StdValue:true;Description:Drop better items with a better civilization level while digging | ||
Var:DROP_CHANCE;Type:int;GameValue:4;StdValue:4;MinValue:1;MaxValue:100;Description:Drop chance while digging (percent) |