Jump to content

wok

Member
  • Content Count

    183
  • Joined

  • Last visited

  • Medals

Community Reputation

1 Neutral

3 Followers

About wok

  • Rank
    Sergeant
  1. I haven't received any pm so I am replying here, here's another related thread with some snippets that try to solve some issues: http://forums.bistudio.com/showthread.php?168525-Calculating-point-in-circle-circunference-gives-always-same-result I don't have my gaming pc running so I can't search for my test missions, I will try to connect that hdd later and dig them out. If I don't remember try sending me a pm.
  2. Took me a while to figure out I had to place the waypoint exactly where the heli name was appearing when mouse overing it, otherwise it would act as a MOVE type and just walk near it. It still does a huge unnecesary turn around the chopper but it works. Thanks a lot guys.
  3. I am trying to make an AI unit walk next to a heli on the pilot side and get in. I know I can make him get in with unit action ["getInPilot", targetVehicle] Now, the problem I am having is moving the unit to the correct position next to the heli on the pilot side, I tried MOVE waypoints (wanted to try the GET IN type but don't know how to set it to get in the pilot position) and doMove, also tried placing a helper to mark the position instead of moving it to the heli position. But the AI always stops a few meters away from the chopper. I wouldn't care if this was in the middle of the mission, but it's for a cutscene so I want it to look as good as possible. So how could I make the AI move to an exact position? Like the position he takes right before getting in the chopper when executing the "getInPilot" action.
  4. player switchMove "Acts_welcomeOnHUB01_PlayerWalk_3"; Works for me, but I would still also like to know other method of moving the player for interactive cutscenes, like doMove for AI, they doesn't seem to work for player.
  5. I am working on a mission that starts with a cutscene, the player starts sitting in a chair (attachTo it). I want the player to be able to free-look around. The only way I found is to detach it, and since the player is locked on the sitting animation set by switchMove, this works well as long as the player only uses free-look, if he moves the mouse without free-look his position changes and he will snap out the chair and be sitting in the air. The problem is that the game starts without free-look activated by default and I can't find a way to activate it via scripts. Does anyone knows a way to trigger free-look via a script?
  6. I am actually doing that, I just separated the attachTo on the sample code to show that the rotation was working without it. This is my test code: _table = "Land_CampingTable_F" createVehicle position player; _helmet = "groundWeaponHolder" createVehicle position _table; _helmet addWeaponCargo ["H_PilotHelmetHeli_B", 1]; _helmet attachTo [_table, [0,-0.5,1.15]]; _helmet setVectorDirAndUp [[1,0,0],[0,-1,0]]; I tried different numbers on setVectorDirAndUp, but the rotation of the helmet never changes once attached. EDIT: The problem must be the table, I found a workaround, I placed a pointer (helper) and attached it to the table, then spawned the helmet on the pointer position and rotated it. That keeps the helmet rotation, now just need to figure out the right position where to attach the pointer so the helmet looks like its resting on the table. EDIT2: The pointer method didn't work because I wasn't able to set the right Z position, so I just used enableSimulation false + setPos, I don't know why I didn't use that from the beginning, I've used it before.
  7. I am trying to attach a helmet onto a table, but I dont like that the visor part points down when I do this, so I was trying to use setVectorDirAndUp to rotate the helmet. For example: _table = "Land_CampingTable_F" createVehicle position player; _helmet = "groundWeaponHolder" createVehicle position _table; _helmet addWeaponCargo ["H_PilotHelmetHeli_B", 1]; _helmet setVectorDirAndUp [[1,0,0],[0,-1,0]]; That works for rotating the helmet, but when I add this: _helmet attachTo [_table, [0,-0.5,1.15]]; The helmets has always the same position with the visor pointing down. Am I doing something wrong? Or is there a limitation with certain objects, because if I attach it to the player then the helmet keeps the rotation I set with setVectorDirAndUp.
  8. I am working on a mission and the player will start sitting on a chair. I am using this to make him sit: [player, "SIT_AT_TABLE", "ASIS", chair1] calls BIS_fnc_ambientAnim; It works fine, but I have a few questions: 1) Is it possible to let the player still move his head (like while holding alt) when using the ambientAnim? 2) How do I give the player the control back? because ambientAnim kinda disableUserInput, (esc, map, compass etc still works). 3) Is there any built-in animation to stand up from the sit anim?
  9. You can check that here, that script is called on init.sqf with execVM.
  10. Thanks a lot! I wasn't expecting to get a reply on this thread. I guess I should also thank thetrooper for bumping it and mattar_tharkari for the points list.
  11. I have managed to use kiory's tutorial to get his sample animation from 3ds max into the game. Now I am trying to do my own stuff, I have a 750 frames animation in 3dsmax that I am trying to get into the game. The problem is that in the game, the animation plays extremely fast, like 1 or 2 seconds, and I want it to be around 10-15 seconds. I can control the speed in buldozer with the [ ] keys, but no idea how I set the speed for the in-game animation. I tried both autotime and autotime 1.0 in Oxygen2, both give the same super fast animation result in-game, and if I dont use autotime the animation wont work, the player just stays for a second in the T-pose and then goes back to normal. I tried playing around with the "time range" option but I don't know what it does or how to use it, it didn't do much. I would post the files but I have other problems with the animation like the mesh getting messed up or the pelvis not moving at all (which doesn't happen on 3dsmax), but I want to solve this issue first before moving into that. How do I set the speed/time range of the animation that will be played in the game? ---------- Post added at 01:41 ---------- Previous post was at 01:27 ---------- Oh f@#k me!, I spent like one hour trying to set this on Oxygen2, didn't think about looking at the config file. Let's blame tunnel vision so I don't feel so dumb. Sorry for this thread, if a mod wants to remove it, go ahead.
  12. Hey thanks a lot for the info, with the help of kiory I was able to use his tutorial and get an animation in game, I still find it quite difficult to make a good animation but thats probably because I don't know how to use 3dMax, the only knowledge I have comes from an autocad course I did 10 years ago.
  13. Are you running this code in a .sqf or a .sqs file? Also always check your .rpt log file for errors, in Win 7 its in :/Users/youruser/AppData/Local/Arma 3/
  14. Have tried a few different things like using createDialog in the rsctitles onLoad to open a separated dialog, but that also stops the inventory from opening until you close the dialog. Also tried using execVM instead of using createDialog directly on the rsctitles onload, so I could use sleep and make sure the inventory was already open, but then the inventory closes when the dialog opens. I will keep trying for a few days but I guess I will end up using addAction for the items options. Thanks a lot for the help anyway iceman. KevsnoTrev, thanks for the suggestion but I am trying to use scripts only, no addons. With addons it shouldn't be too hard, I think dayz does something like that too. A "solution" I was thinking about is adding a mouse click event handler to the main display like: (findDisplay 46) displayAddEventHandler["onMouseButtonClick", "hint str _this;"]; And then calculate if the coordinates where the click happened are the same position than the fake slots, that does fires when clicking even with the inventory open, but the coordinates always return 0.5, 0.5. And I think it would be a pain in the ass to make it work across all resolutions/aspect ratios anyway.
  15. Thanks a lot, the problem I am having now is that, if I use createDialog to open the dialog, then the inventory wont open until I close the dialog (with esc), and I need both the inventory and my dialog to open at the same time since I am not handling the entire inventory, just a few fake slots. The inventory opens fine if I use RscTitles and cutRsc instead, but that gives me a different problem. I want to open some sort of contextual menu when clicking on the fake slot, and display some options on a listbox. When using createDialog, the mouse event handlers (im trying to use onMouseButtonClick) work well, but when using cutRsc the click event doesnt fire anything. Will see if I can create a sample later, my current code is too messy right now.
×