Commit Graph

36 Commits

Author SHA1 Message Date
ebaydayz
8c1caa9c1c Remove some redundant checks
Vanilla commits:

da7061429a

da55eaa53e
2017-01-29 19:36:48 -05:00
oiad
9889c8cd76 Merge z_calcDefaultCurrency and z_calcDefaultCurrencyNoImg (#1824)
* server_updateObject force update for single currency

This modifies server_updateObject to force update/save to the hive if
the item being saved is in the DZE_MoneyStorageClasses array.

Previously if you force saved the object multiple times, the coins would
not get updated until the inventory changed, which if this was for a
bank object it would never update.

(This applies if you are using PVDZ_veh_Save to save the object)

* z_at_calcDefaultCurrencyNoImg prettyfication

This fixes a long standing issue in my brain about how this text was
always displayed, to me it seemed very untidy and just thrown together
(since I borrowed it from the IMG version)

Changes the output from this example: 7 Ruby 1 Amethyst 3 Gold 4 10oz
Silver 5 Silver
To this prettier and more logical example: 7 Ruby, 1 Amethyst, 3 Gold, 4
10oz Silver and 5 Silver

Make texts great again!

* z_at_logtrade fixes

Removes hard coded "Coins" text and replaces it with configVariables
version.

Also removes duplicate code and simplifies it.

* Merge z_calcDefaultCurrency and z_calcDefaultCurrencyNoImg

This merges these two files together since they are largely the same,
this also adds an optional argument to change the font size which is
useful for custom scripts that use this function.

Examples of use:

[_number,true] call z_calcCurrency; // Return a string of text with no
images
[_number,false] call z_calcCurrency; // Return a string of text with
images
[_number,false,0.7] call z_calcCurrency; // Return a string of text with
the currency in it and sets the font size to 0.7
2016-12-22 14:16:38 -05:00
ebaydayz
eedf7dd12c Fix door and plot management display text for mustBeClose
Also removed unneeded uiNamespace vars.
2016-11-08 19:27:05 -05:00
oiad
b1171c5f9b player_wearclothes changes, string changes and maintain area moving (#1783)
* player_wearclothes changes, string changes and maintain area moving

Adds 2 toggles for admins to modify:

DZE_backpackRemove forces the player to drop his/her backpack when they
change gear.
DZE_maintainCurrencyRate modifies the amount of worth each item is worth
to maintain.

Changes the error message in player_wearClothes to tell the player why
they can't change gear yet
Remove some debug lines that spam RPT

* Rework

Rework as per @ebaydayz

* Rework

Rework
2016-10-30 14:11:54 -04:00
ebaydayz
15763f4f2a Consolidate maintain scripts
Thanks to @oiad for making this easy #1735
2016-08-15 16:33:00 -04:00
oiad
c738710b77 Plot management fixes (#1735)
* Plot management fixes

This hopefully adds a few more items to the maintain list (@icomrade)
Uses epoch_returnChange to accurately and tidily return change and
handle money.
Localize maintain_area.sqf for single currency servers

* Plot Management tidyness

Fixing tidy issues

* Plot management changes

Fix maintenance variables as per @ebaydayz

* Plot management

Missed one

* Plot management fixes and default maintain_area fixes.

Convert original maintain_area.sqf to epoch_returnChange, I used the
plot management localization strings since I liked them better, the
epoch ones don't make a lot of sense really. Makes no difference if plot
management is turned off anyway.
Change the single currency version to work a lot better than it did, I
put the cost per item to 100 to be more in line with what I would expect
on a server

Changed _range to use DZE_maintainRange (DZE_plotPole select 0 + 20)
2016-08-15 14:49:56 -04:00
icomrade
657fe60f26 Better maintain
Intensive commands are processed on the client only, as opposed to
twice. an array of objects, their corresponding UID and ID are sent to
the server. Sending the objects as an array, despite the size the array
can reach, should be better than the way this was set up before.

Needs testing on a full server however.
2016-08-03 19:54:06 -04:00
ebaydayz
914b37a413 Pass cursorTarget to maintain_area.sqf
CursorTarget should always be passed from fn_selfActions, not reacquired
in action scripts. This is to ensure the same object is referenced. Plot
Management maintain_area is called from the dialog button, not
fn_selfactions.
2016-05-19 13:10:20 -04:00
ebaydayz
5157228e67 Update all cutText to dayz_rollingMessages 2016-04-16 15:47:49 -04:00
ebaydayz
666ace6d54 Cleanup duplicate and unused strings
Cargo count is shown at the top of the gear menu now
2016-04-04 16:58:59 -04:00
ebaydayz
77e760fe73 Update private tags
From
e69f8d5306

Moved dog files to the \dog\ folder and pzombie files to the \pzombie\
folder. Also removed some legacy files that are no longer used.

The actions\ and compile\ folders are fully up to date now
2016-03-30 14:55:45 -04:00
ebaydayz
e2e6e79394 Minor formatting cleanup 2016-03-21 17:58:23 -04:00
ebaydayz
0111a8f580 Change count back to forEach
You can not nest count loops inside other count loops:
https://community.bistudio.com/wiki/Code_Optimisation#forEach_vs_count
2014-07-31 13:14:10 -04:00
icomrade
ad6530c579 Little thing 2014-06-10 13:03:43 -04:00
icomrade
6b9b176736 More #1288 2014-06-01 03:29:44 -04:00
icomrade
e54b9983dd Replace forEach with Count
Use count where you do not need _forEachIndex variable, it's quicker
than forEach.
2014-05-27 15:37:57 -04:00
Skaronator
9ebd85956c Fix Logic Typo 2014-02-18 13:10:02 +01:00
Skaronator
7cfbbd2f5f More steps for less obj count 2014-02-07 12:46:17 +01:00
Skaronator
5deef8ba5c Price Review on maintain area? 2014-02-05 20:00:11 +01:00
[VB]AWOL
9876b42b0a add DZE_DamageBeforeMaint default now 0.09 instead of 0.1
Also exit with message if no maintainable objects are found
2014-02-03 08:38:39 -06:00
Skaronator
26dcb3a34a Update Changelog 2014-01-26 16:52:57 +01:00
[VB]AWOL
ea43bbd0fc made use of GV and removed retry 2014-01-22 09:33:18 -06:00
Skaronator
03b2408ae3 Update maintain to new CHILD function 2014-01-17 23:05:42 +01:00
Skaronator
678590c7ce Publish new Maintain Area (New HiveDLL is required) 2014-01-17 19:09:37 +01:00
Skaronator
31b0226b94 Push PVS/PVC files (Outcommit currently) 2014-01-11 18:58:49 +01:00
Skaronator
4448546734 Fix Typooo 2014-01-10 13:43:05 +01:00
HARLAN
e65d1cc9d3 localization 2013-12-23 12:17:56 -05:00
Torndeco
423390381a Typo 2013-12-16 20:32:51 +00:00
HARLAN
ad17aa07af #919 modify global var into array 2013-12-16 13:06:32 -05:00
[VB]AWOL
d7682ac187 not really needed as we log each swap object call already. 2013-12-09 23:26:56 -06:00
HARLAN
ffc4675ae2 area maintenance tweaks 2013-12-09 10:40:19 -05:00
[VB]AWOL
0fcf880a1d fixes to swap object code 2013-12-09 08:59:44 -06:00
Zac Surplice
6a58370670 small change 2013-11-27 15:42:38 +11:00
dayz10k
98079d0142 Area Maintenance 2013-11-26 14:02:48 -05:00
dayz10k
de265ec1a4 Area Maintenance 2013-11-26 14:00:33 -05:00
dayz10k
cbc024bc44 Area Maintenance 2013-11-26 13:57:12 -05:00