Jump to content

hogscraper

Member
  • Content Count

    22
  • Joined

  • Last visited

  • Medals

Everything posted by hogscraper

  1. hogscraper

    [Early Preview] 3D Editor

    Great script idea! I was really getting tired of using notepad++ macros and having them break halfway through the files. Thanks for the effort!
  2. hogscraper

    Community Upgrade Project: WIP thread

    http://www.cup-arma3.org/ This was on this video from the ALIAS channel:
  3. hogscraper

    Community Upgrade Project: WIP thread

    Any info on download size or release date? I tried following the links in the video description but the main one seemed to be down at the moment.
  4. When you run a local dedicated box you have two rpt files. The folder you created that is called in profiles= in your bat file for starting your local dedicated server will contain all of the rpt logs generated by the server.
  5. hogscraper

    GUI add Buttons and Text to ListBox

    https://community.bistudio.com/wiki/lbSetPicture
  6. If you want full access to what you want to save and how you want to save it, extdb is another choice. Takes a while to learn from scratch but its working pretty well for me.
  7. Hello, I've been playing around with BIS_fnc_addStackedEventhandler and onPlayerConnected/onPlayerDisconnected in an effort to welcome a player back,(among other things), when they disconnect and comes back. But what I'm running into is that when the player comes back, nothing returns the right values. I'm passing along the right variables,(I have tested both name and uid and they both always report the correct values). _playerName = _this select 0; _uid = _this select 1; diag_log format["_playerName=%1",_playerName]; diag_log format["_uid=%1",_uid]; if (_playerName == '__SERVER__') exitWith {}; _player = objNull; _playerCount = {isPlayer _x} count playableUnits; diag_log format["_playerCount=%1",_playerCount]; while{!isplayer _player}do { { if (getPlayerUID _x == _uid) exitWith { _player = _x; }; } forEach playableUnits; }; _ClientID = owner _player; The first time they connect it counts them correctly and everything I've added after that works perfectly. If they disconnect and come back it doesn't count them and always shows _ClientID==0. Anyone know a what might be causing this? I originally thought maybe it was because I was using deletevehicle to remove their corpse from the battlefield but I got rid of that and ran a barebones mission. Nothing but my onconnect/disconnect. Five players on and it shows _playercount==5. One leaves and comes back and it shows _playercount==4 and I can't send any publicvariableClient to reconnected players as it shows their clientID as zero. Any help or guidance here would be appreciated!
  8. I have it set in my onplayerconnected so that it keeps iterating while{!isplayer _player}do but for reconnecting players only it never shows isplayer _player as true. I put hundreds of while loops like the above in my onplayerconnected, with a bunch of diag_logs inside, and the first time a player connects it passes immediately. On reconnect it just went ten minutes and never found the playable unit with the same PUID as the reconnecting player that was isplayer or alive. I guess what's bugging me is that the first connection is immediately transferred from server to client as owner. Its only after they log out, then back in, that it has trouble. After an extreme test of 10000 lines of while loops its apparent that on first connect it recognizes the playable unit as being alive and isplayer near instantly but on reconnect, the server will not recognize that the player is alive or isplayer until after everything in onplayerconnected has run, which kind of defeats the purpose. This is using the latest dev build. It looks like nothing works between server and client from when onplayerconnected starts and when it finishes ONLY if the player has disconnected then reconnects. Like the server is treating a client differently if they had previously connected but I've never read anything that can confirm that. Maybe I need to just get past that section, THEN find their playerobj, THEN run what I need to. I'll see what happens if I just move players to a debug area from onplayerconnected, and use a trigger to catch when they spawn and from there run everything that was in onplayerconnected.
  9. hogscraper

    Line Break in text

    I went back and while my code works perfectly for hints, I couldn't make it work for copytoclipboard. I remembered a script I used for exporting all of a designated config file to clipboard and was able to modify it. _CRLF = toString [0x0D, 0x0A]; _array1=["hello","nothing","to","see","here"]; _uid=getPlayerUID player; _cursorTarget=cursorTarget; _typeOfCursorTarget = typeOf _cursorTarget; _hint= format["_cursorTarget=%1%2_typeOfCursorTarget=%3%2%4%2%5%2%6%2%7%2%8" ,_cursorTarget,_CRLF,_typeOfCursorTarget,_array1 select 0,_array1 select 1,_array1 select 2,_array1 select 3,_array1 select 4]; copyToClipboard _hint; while looking at an MRAP in game this is the output to clipboard directly from in game: _cursorTarget=460e2b00# 2357184: mrap_01_gmg_f.p3d _typeOfCursorTarget=B_MRAP_01_gmg_F hello nothing to see here So just place _CRLF = toString [0x0D, 0x0A]; in your script and use that in whatever string you are formatting to force a line break in the copytoclipboard
  10. hogscraper

    Line Break in text

    Don't know if you got that to work, but since I had typed that off the top of my head, I forgot that you have to do the parseText format on the client side, just before the hint. So for getting it formatted server side then having it look good client side: serverside _AOstr = "<t align='center' size='2.0'>Mission Status</t><br/> ______________<br/><br/> Good work squad.<br/> The AO has been cleared!<br/> <br/> Stand by for further orders."; GlobalHint = _AOstr; publicVariable "GlobalHint"; client side "GlobalHint" addPublicVariableEventHandler { private ["_GHint"]; _GHint = _this select 1; hint parseText format["%1", _GHint]; }; Hope that helps!
  11. hogscraper

    Line Break in text

    _AOstr = parseText format ["<t align='center' size='2.0'>Mission Status</t><br/> ______________<br/><br/> Good work squad.<br/> The AO has been cleared!<br/> <br/> Stand by for further orders."]; GlobalHint = _AOstr; publicVariable "GlobalHint"; I have used this in the past to let players know when a mission AO had been cleared. Can't remember where I picked that trick up but I loved since the first time I realized I could format a hint any way I wanted. Text size, color, whatever.
  12. upvoted! Thanks for your help.
  13. Hey guys, I searched for a while on this, and maybe I was searching the wrong thing, but I can't find a solution for using addWeaponGlobal then getting addPrimaryWeaponItem to work in an MP environment. I have a pvp setup where players can only get gear by packaging an array and publicvariableserver. The server checks out what they want then assigns the items and weapons. I don't seem to have any trouble at all except with assigning weaponitems. (ran on server) _player addWeaponGlobal _weapon; //works _player addPrimaryWeaponItem _first_weapon_item;//does not work I thought maybe it had to do with this issue: http://feedback.arma3.com/view.php?id=18446 where maybe it can't add an item to a weapon that isn't currently being held but using [[[_weapon],{_primaryWeapon=_this select 0;player selectWeapon _primaryWeapon;}],"BIS_fnc_spawn",_player,false] call BIS_fnc_MP; will select the weapon but it still won't add the weaponitems afterward. As an alternative, if I use BIS_fnc_MP along with addweapon and addprimaryweaponitem, will that kick a player if addprimaryweaponitem or addweapon is in the list to kick? I know if a client tries to run ones of those locally it will kick them, but I wasn't sure if it made allowances for BIS_fnc_MP. Or does anyone know if they have plans to add an addPrimaryWeaponItemGlobal like they did with addWeaponGlobal? Thanks for any help you can give! hogs
  14. I know that I can spawn gear client side. I made the publicvariableserver request to keep the spawning from being able to happen client side and attempting to use BE filters to block players from things they shouldn't have. They've added in addweaponglobal already, so it makes no sense why I cannot add weaponitems from server to client as well. If no one knows how I can just leave the weapon spawning client side and attachments only client side I just didn't want to do that. ---------- Post added at 01:21 ---------- Previous post was at 00:08 ---------- Since I was able to test BIS_fnc_MP and found that BE filters will still kick for addprimaryweaponitem, even if code doesn't exist on client except when delivered from server I added this to Killzone Kid's bug tracker report on incorrect/missing scope of commands. If anything comes from that I will update this thread in case someone else happens along and is having this same issue. http://feedback.arma3.com/view.php?id=15298
  15. using this code works [[[_weaponitem_one],{_primaryWeaponItem=_this select 0;player addPrimaryWeaponItem _primaryWeaponItem;}],"BIS_fnc_spawn",_player,false,true] call BIS_fnc_MP; using this does not _player addPrimaryWeaponItem _weaponitem_one; execution started by player and run locally player addPrimaryWeaponItem _weaponitem_one; is working fine so I know the variable is formatted correctly and the weaponitem is a correct attachment. I just can't figure out how addWeaponGlobal is even useful or relevant if you can't also attach weaponitems in the same manner.
  16. hogscraper

    13€ DLC, hefty price for 2 choppers

    I completely understand their DLC thought process and its ignorant at best. The released DLC as well as the planned heli and marksman dlc's are stupid when compared to their DLC releases for Arma2. Arma2 had complete packages as DLC. There was a little something for everyone and that helped people justify the expense. If you liked vehicles, the DLC might have that. If you liked new weapons, the DLC probably had something you could enjoy. New skins or graphic upgrades? Some of that to go around as well. These new DLC have a stupidly narrow scope in who they might appeal to. I enjoy fighting on the ground and especially CQC. I don't generally enjoy using sniper rifles, couldn't care less about advanced flight mechanics and have never thought that driving a go kart was missing from my Arma3 experience. That's not to say that those are bad things, I just have zero reason to buy them. Out of a dozen or so people in our TS last night only two guys were interested in the marksman stuff and that was it. Why spend time developing content that only appeals to a specialized group of your fan base? I also understand that they are actually being quite generous in the way they are doing their DLC with not forcing people to buy it and allowing people to have some of the experience but that entirely ignores the fact that official content, that most players can completely enjoy, is what keeps games like this alive. It just fails to make any sense from a money stand point or for keeping the vast majority of your fanbase interested. Its obvious that they intend on releasing extremely specialized, premium DLC at a premium price. And for those specialized areas of interest it makes sense. It just doesn't make sense to the rest of us when we know that a year from now, the game will likely still be the same content-wise. If I'm writing a mission, I have zero reason to place a vehicle that I can't pilot. Am I to hope that maybe a client that joins will have it and pilot it for our soldiers? And if they don't I then have a wasted model taking up space in my mission. Should I bother to add certain weapon names to crates in the hopes that maybe a client joining will want them there? For me it will be out of sight, out of mind. Again, that's not necessarily a bad thing, but its definitely not something that is beneficial to the game's long term health. It makes me doubly worried when I hear that such a small team is working on Arma3. That means they are using already strained resources to release content that will be bringing in much less money and appealing to a smaller fanbase section than previous DLC types and that means even less development dollars down the road.
  17. hogscraper

    1.63 Script issues

    Sadly it is obvious that they broke the game on purpose. I honestly cannot find one reason for this change at this point in A2's life cycle. Maybe if they fixed their own code first. Maybe if they implemented this a long ass time ago. Maybe if they gave people a head's up that it was coming AFTER fixing their own code. But they didn't. Instead they wait until now and purposefully break their own code when the changes add nothing beneficial at all. I played A3 quite a bit from the first moment it was on Steam to release but the map is shit, everything looks dead and definitely not a place I would ever want to spend time so I stay with A2. Stand Alone is a waste of time with nothing to do so I stick with Epoch on A2. Maybe they should have waited until the games they are pushing people towards actually have value over their old releases. Shame really because I think it will backfire and drive a lot of people away from their brand altogether.
  18. hogscraper

    Arma2NET

    I have an issue that has been driving me crazy. Has anyone else had any trouble with the return value from your addin depending on where its called from? I added a column to my db named Money and wanted to keep track of how money was spent on my server. To test it I made a .bat file to call arma2oa.exe with arma2net and in single player mode, using _tmp = "Arma2Net.Unmanaged" callExtension format ["Epoch_Money_Get '%1']",_characterID]; hint format ["_tmp=%1", _tmp]; sleep 2; _tmp1=parseNumber(_tmp); _tmp2=_tmp1*2; hint format ["new value = %1", _tmp2]; the exact number I expected is pulled from the database and multiplied by two then is shown as a hint. When I edited my compiles.sqf in order to utilize this code with epoch it doesn't return anything. I can't tell what the problem could be. I added in C# code to my addin that wrote the return value to a text file so I know for a fact that the call to arma2net is working just fine, when its called from compiles.sqf, as the text file is being created every time the call is made. Are there known issues with certain usage of this addon? I just can't get my head around how one call to the dll works in every way intended when called from a single player instance of Arma2OA.exe but the exact same sqf code fails to collect the returned value when used in compiles.sqf. Inside one of the trade_whatever.sqf is a line _total_currency = call epoch_totalCurrency; and I have the code to call arma2net inside the definition of epoch_totalCurrency inside my compiles.sqf. Its almost like doing it this way doesn't allow return values maybe? Below is the code that I am using. Any help or advice on this would be MUCH appreciated! using System; using System.Collections.Generic; using System.Linq; using System.Text; using System.IO; using System.Threading.Tasks; using Arma2Net.AddInProxy; using MySql.Data.MySqlClient; namespace Epoch_Money_Get { [AddIn("Epoch_Money_Get")] public class Epoch_Money_Get : AddIn { public override string Invoke(string args, int maxResultSize) { string _CharacterID = args; string _Character_Money = ""; string _convertCID = _CharacterID.Trim(); char[] _chars = { ',', ' ', '[', ']', '\'', '\"' }; _convertCID = _convertCID.TrimStart(_chars); _convertCID = _convertCID.TrimEnd(_chars); string MyConnectionString = "Server=127.0.0.1;Port=3306;Database=dayz_epoch;Uid=root;password=;"; MySqlConnection _con = new MySqlConnection(MyConnectionString); MySqlCommand _command = _con.CreateCommand(); _command.CommandText = String.Format("select Money from character_data where characterID={0}", _convertCID); try { _con.Open(); } catch (Exception ex) { return "0"; //Console.WriteLine(ex.Message); } MySqlDataReader _reader = _command.ExecuteReader(); while (_reader.Read()) { _Character_Money = _reader["money"].ToString(); } _con.Close(); TextWriter tw = new StreamWriter("stuff.txt"); //String writerfile = String.Format("{0}", _Character_Money); tw.WriteLine("{0}", _Character_Money); tw.Close(); return _Character_Money; } }
  19. hogscraper

    Arma2NET

    So this is in response to a post from 2012 but I too have found, that returned variables have extra quotes for some reason. I had a heap of trouble trying to pull an int from the db to use in my SQF so I gutted the method and just had the below code. SQF: _tmp = "Arma2Net.Unmanaged" callExtension format ["Epoch_Stats [set,'%1','%2']",_characterID,_stats]; hint format ["%1", _tmp]; then in my C# code: string _tmpVariable = "12345"; return _tmpVariable; On screen it outputs "12345" instead of 12345 I spent around three hours trying to figure out why I couldn't parsenumber(_tmp) but it turned out it was because everything the method was sending back had extra quotes. I ended up toarray(_tmp) seeing what numeric code equals quotation marks then writing a short block to remove them, turn them back into a string then into an int so my SQF could use them.
  20. hogscraper

    [MP] Chopper Dogfight TDM By: Dogheadfish

    link is broken
  21. hogscraper

    Escalation - Squad-based PvP with respawns

    Looks like both download links on the Armaholic site are broken. Mediafire works, though. Can't wait to try this out.
×