Jump to content

Prodavec

Member
  • Content Count

    107
  • Joined

  • Last visited

  • Medals

  • Medals

Everything posted by Prodavec

  1. I don't use sleep because: 1. It is not realiable. It may help, but because of scheduler architecture sometimes you have to increase delay time, sometime decrease. And there's no indication of process completion like _waitUntil {_copyingCompleted}; 2. It is not possible to use sleep or waitUntil in non-scheduled environment by design. Function should be universal: may be called in non-scheduled and in scheduled environments. Well, code should be realiable in all possible situations. 0.5-5 FPS is like stress-test and it's not passed. Hmm... you mean in SQF _someArray is just a pointer like in C/C++? What about wiki: It looks like the array is just variable, not a pointer. And I did simple test _array1 = [1, 2, 3]; _array2 = _array1; _array1 = [1, 1, 1]; hint str _array2; and I see [1,2,3] not [1,1,1]. If it was the pointer then I should see changed _array1: [1,1,1]. _someBigArray = [item1, item2, item3, ..., itemN]; // A bunch of elements _someOtherBigArray = []; _someOtherBigArray resize (count _someBigArray); //Pre-allocate the array _n = 0; for "_i" from 0 to ((count _someBigArray)-1) step 1 do { if (alive (_someBigArray select _i)) then { _someOtherBigArray set [_n, _someBigArray select _i]; _n = _n + 1; }; }; _someOtherBigArray resize _n; //Remove unused elements at the end Why are you using RESIZE if you are using SET command? SET automaticaly resizes array if needed. Maybe because it resizes every iteration you have used RESIZE at the begining outside of the loop? Well. This method works and I'm using it. But in this case you have to pass thru _someBigArray to copy all elements to another one. And this is not good when you've possible alternative variants like _someOtherBigArray = _someBigArray; or something else executed inside of engine, not a script layer. I will try to use Binary Addition to compare two methods, with FOR + SET and =+.
  2. I need good perfomance. I don't need good graphics. "Good perfomance" means 60-100 FPS in heavy scenes with 200 players online. Just let me set my video settings as low as it possible, disabling new DX10(11) effects (especialy blur/bloom etc). Just give me choice between "Call of Duty" high perfomance mode with outdated graphics and "BI-style"-low perfomance modern graphics (sorry) and I WILL BUY your game. Game should be responsible enough to react on different video settings, not like a2 when you set setViewDistance 200 and run some desert island with sand and few stones on very low settings and getting much-much lower FPS than CoD with much more complex BSP-map and bigger view distances with very high settings.
  3. As I understand any of DayZ admin may compose false report with false detail information in scripts.log? What mechanisms of protection are used to prevent influence of a human factor?
  4. Prodavec

    Arma2NET

    Lol... someone is using serial ports in 2012:eek:
  5. The game is being made by the players, not admins. So the players should be protected against negative factors (including admins' abusive behaviour). There is a lot of players, administrators - singles. The players make money for BI, not an admins. The players are ready to spend their FREE time to the game and their money for the playing on some server, not SINGLE admin.
  6. What about protection against admins that regulary abuse their power and/or their friends? I don't want to spot my position and reveal my (and my squad) unique tactics for some douchebags that just have BE rcon password. Me and my mates a few times were "tested" by shitty admins on leggit actions with scripted observer. In most cases it was ruined game even all is ok. So if it will be implemented by BI using some Editor Module (for example) the list of possible negative factors will grow: 1. Abusive admins which use BE for ban players because of they are just admins and may break their own rules. 2. Abusive admins which use addons with private keys/signatures to add admin power (legit hacks) and may hack on their own server. 3. Abusive admins which add some scripts in the mission with UID filter to add admin hacking power (for example +$1000000 if it's Life or spawn TWS stuff for "debug purposes" if it's some of kind TvT/PvP mission) 4. Hackers 5. And admin spectator, with some module can be used by ANY admin/admin friend, even he's a full douchbag. By my experience admins make much more damage than hackers. The hacker can ruine single mission, admin can ruin the whole game for few players. No protection for single player and/or squads?
  7. If you got scripts_old.txt, your scripts.txt is incorrect. //new 1 "some string" ["some string 2"] ["some \"string 3\""] [!"some string 4"] and use CP-1251 For example //new 1 "setDamage 1" 1 "createVehicle" !"\"M1A1\" createVehicle"
  8. persistent=0; change to persistent=1;
  9. Clients MUST not execute any scripts. It was big mistake to trust clients in MP. All scripts must be executed on server only.
  10. It doesn't support UTF-8 for some reason. scripts.txt gets renamed to scritps_old.txt if it was in UTF-8
  11. Just use SET command when working with arrays if it is possible. It's the fastest (most speed-optimized) way to work with. Code Optimisation
  12. _value = player getVariable "my_var"; // [1, 2, 3] _value set [2, 9]; player setVariable ["my_var", _value, true]; // [1, 2, 9] player setVariable ["my_var", (player getVariable "my_var") set [2, 9], true]; // ERROR!
  13. The first (findDisplay 46) displayAddEventHandler ["keyDown", "if (((_this select 1) == 28) && visibleMap) then {hint 'ENTER pressed'; true}"]; doesn't work if you Double Click on the map and quckly (very quickly) hit ENTER. You'll see "ENTER pressed" hint but ENTER will work like it wasn't disabled. Why? (_this select 0) tells me that event has been recieved from display #46, not #54 (map marker) for some reasons. If I press ENTER key after double clicking on the map, I shouldn't see any messages, because no EH attached to display #54 but I can see. For example (findDisplay 46) displayAddEventHandler ["keyDown", "if (((_this select 1) == 53) && visibleMap) then {hint 'SLASH pressed'; true}"]; works fine. It disables the "/" key on the Map Screen. The second strange thing, keyDown event is fired earlier than mouseButtonDblClick event. Simple code below demonstrates that behaviour: (findDisplay 46) displayAddEventHandler ["keyDown", "player sideChat 'Key pressed!'"]; ((findDisplay 12) displayCtrl 51) ctrlSetEventHandler ["mouseButtonDown", "player sideChat 'Double Click on the map!'"]; If you VERY quickly hit Double LBM and then ENTER you'll get Why? It should be I need to completly disable ENTER key on the Map Screen and I need script-based solution, with no addons (for some reasons I cant use addons in my situation).
  14. Thank you for helping me guys. PvPscene Thank you, I think you're right, I should completly rebuild map marker (and create new one, scripted version), it's more reliable and protect against programms like AutoHotkey. Topic may be closed, credits will be given in my script file / mission header.
  15. Nope, I'm not getting errors. I can't disable ENTER key on the map screen because of some strange behaviour of the keyDown Event Handler, it's only related to the ENTER key. PvPscene I'm working on the script which adds nickname to the created map marker. For example you want to place marker with text: "This is our location" and after pressing ENTER marker becames "Prodavec: This is our location". And that script must work with no downloadable addons. I found next algorythm to approach my goal (I used it to disable "Respawn" key, and Valhalla by WINSE used it too): 1. Add event handler mouseButtonDblClick to the map control on mission init. 2. When user double click on the map, mouseButtonDblClick EH begins to search marker display (it's Display #54). Searching loop works until Display #54 will be found, also it has timeout, just for case, 2 seconds for search, if not found => exit. Loop is under SPAWN command, so it's in scheduled script environment and may be delayed if mission has a lot of other running script in parallel (see below). 3. After searching Display #54, loop using exitWith adds keyUp EH to the Display #54. That event handler can process user keys when he types in the text field of the map marker. 4. When user presses ENTER, keyUp EH gets Control #101 of the Display #54 and changes control's text to the Text = <player name> + Text It works fine and doesn't require addon to change RscDisplayInsertMarker class. But there's a problem related to SPAWN command: if you hit ENTER very quickly after Double Click, the searching loop will not find Displat #54 (the marker). I fully understand mechanics why it happens and my solution is to disable ENTER key after Double Clicking on the map for few milliseconds. mouseButtonDblClick EH disables ENTER key, searching loop enables ENTER when Display #54 will be found and KeyUp EH installed, or by timeout (just for case). I found that if you presses ENTER very-very quickly the "keyDown" event is recieved from Display #46 (not Display #54), so I just added new EH to the Display #46 with simple code: if (key == ENTER && disableEnterKey) {... Ignore ENTER ...} else {... process ENTER normally...} But ENTER still works. Maybe Display #54 and Display #46 firing "keyDown" event at the same time, is it possible? The second thing: keyDown EH is being fired BEFORE mouseButtonDblClick fired. I don't understand why? So even you will set disableEnterKey = true via mouseButtonDblClick (non-scheduled part) the keyDown event under else {...process ENTER normally...} scope will be processed anyway. How do I disable ENTER key or may be you have better solution? Thank you.
  16. Prodavec

    Scripting Help

    Invalid parameters should be Crate addWeaponCargo ["M107_DZ", 1]; Crate addWeaponCargo ["m24", 1]; etc it seems like you're potential hacker, sorry for that if you're not :)
  17. Thank you very much for satisfying my request. I thought it'll be implemented in A3 but you did it in A2 :) Cool! The way to reduce network traffic. Xeno, don't forget about Tushino :))) It uses ACE mod in 100vs100 players battles and that new commands will be very-very usefull :) Thank you.
  18. Xeno Can I repost your message to the Tushino forum? It sounds great.
  19. nomad_man I understand, ping is very important in PvP/TvT-based games. I mean generally as Xeno has said ACE is popular on closed servers / communities. I believe there're a few communities in North America like Tushino Serious Games: ShacTac, 15th MEU, etc... One of the problem that makes ACE isn't so popular on public servers as I/we wish - automatic addon syncing (redirecting to http/ftp server(s) like in CoD/CS to download latest version of addons). Other issues are not related directly to the game architecture: difficulty level, more complex controls, game mode: classic TDM/AAS/CTF are less popular in ACE community than dedicated missions, but that missions cant be played for "JIP" (not for technicaly jip-clients) players, because closed community is closed for public. :)
  20. I play there, it is russian server :P Tushino Serious Gaming with ACE mod and radio :) Most of players are from ex-USSR countries and a few from Europe. Every weekend it has online 120-170 players and 5-30 player in other days (playing small PvP maps)
  21. I tried to invite a lot of my friends in ArmA community. Someone was bored because of gameplay (most of servers are against bots), someone because of controls and animation, someone because of high hardware requirements. Also ArmA community has a feature: many admins try to ban people when community is a very-very small (to comparison with other FPS projects). We have 300-1200 peoples online in A2:OA. For example Shitty Life RPG2 server with their admins ban everyone for everything and as result they have low online and high player flow. They have a donation shop but no reason to donate if someone will get banned because of bad mood of Armatec which doesn't follow his own rules. Disrespecting people like "why spam 141 dick"©ArMaTeC is depricated by all mature players. I have no idea why people are so unfriendly in arma multiplayer, maybe it is related to the age of players or because a much more "geeks" with small dicks play arma?
  22. I see a lot of admins use that new tool to detect hackers but they lack scripting skills and realy don't know how does it work or functionality of the scripts. Few days ago I visited some of "Life" server (server which runs very badly scripted and non-optimized life mission, ported from A1) and saw a lot of people got banned for "Hacking". I've left the server and tried another one, I was interested what's going on at other server with. Same. I guess it's new wave of bans in arma community... It is so ArmA-like :): to ban all for everything suspicious, ha-ha.
×