MantisBT - Zandronum
View Issue Details
0004472Zandronum[All Projects] Suggestionpublic2025-03-23 14:182025-04-11 16:52
auratoostronk 
 
lowfeatureN/A
newopen 
 
 
0004472: Add ACS Clientside functions in addition to clientside scripts
Requesting a feature that allows doing the following (if possible and if practical)

function void myClientsideFunction(str text, int i, int j) CLIENTSIDE
{
     HUDMessage(s:text; HUDMSG_PLAIN, 0, CR_RED, i, j, 3.0, 0.075);
}
No tags attached.
Issue History
2025-03-23 14:18auratoostronkNew Issue
2025-03-24 00:54DrinkyBirdProduct Version4.0-beta =>
2025-03-24 03:30Ru5tK1ngNote Added: 0024305
2025-03-31 19:17IlyStrNote Added: 0024375
2025-03-31 19:22IlyStrNote Added: 0024376
2025-04-05 10:11auratoostronkNote Added: 0024383
2025-04-11 16:52DrinkyBirdNote Added: 0024427

Notes
(0024305)
Ru5tK1ng   
2025-03-24 03:30   
If you call the function from within a clientside script, the scope of the function should also be clientside. Is there a specific use case where this isn't possible or doesn't work? Example wad?
(0024375)
IlyStr   
2025-03-31 19:17   
Ru5tK1ng I think that he wanted to make certain functions can be called by the server and executed in client's side and return a value to the server, but then it's necessary to implement something like interfaces from C# where the first argument is the client.
(0024376)
IlyStr   
2025-03-31 19:22   
Actually makes sense, maybe it will be more optimized than a chain of scripts that pass values to each other, but also it's necessary to add a timeout argument in ticks or milliseconds
(0024383)
auratoostronk   
2025-04-05 10:11   
I'd like to be able to call functions from the server and execute them on the client, for situations like HUDMessages. A script version of the function above wouldn't work because ACS scripts do not allow strings as arguments.
(0024427)
DrinkyBird   
2025-04-11 16:52   
You can use'https://wiki.zandronum.com/SendNetworkString [^]' for that.

Or just the HudMessage function, which sends down the message only to the activating client.