Hey there.
I'm making an ORPG and use various complicated JASS systems in it.
I usually never make the systems for the ORPG because RaiN is making them for me and he's doing it really great however... He's pretty busy with alot of spells, abilities and more more more so I didn't want to bug him with this request again.
You see. I'm making the quests for the ORPG. So far I made them GUI with alot of leaks and waits just to try it out. Now at this time I think the concept is "done" so I started trying to make a system to make it leakless in JASS.
On that last part I probably failed because my head can't take it anymore. My JASS knowledge isn't good enough to finish this so I'd like to ask people here if this is actually possible and if so, could you finish it for me?
This is what I want:
I want to be able to add multiple camera objects to a certain 'camera queue' so if one of them is done it automatically jumps to the other camera. This while at the SAME TIME unit transmissions are being queued in the same trigger and display while the camera's are panning.
This is how it looks like (with leaks): http://www.youtube.com/watch?v=fT-T2mQg_C0
This is the camera part of the "system" I came up with. I used some variables but those are supposed to become globals after I figure out how to make globals.
The thing I want is that if I write this...
call QueueCamera(...)
call QueueCamera(...)
call QueueTransmission(...)
call QueueTransmission(...)
...the first queued camera and first queued transmission start at the same time. So far from what I made it works like this: The first camera starts moving then after its time is up the 2nd one moves. When the 2nd one's time is up the 1st transmission begins... I want it to start at the same time!!
But how???
[Thanks for reading this wall of text...]
P.S. Don't look at my weird way of looping and using udg_ stuff... I only wanted to make a basic version so my ORPG's coder only would have to change those weird things afterwards.
I'm making an ORPG and use various complicated JASS systems in it.
I usually never make the systems for the ORPG because RaiN is making them for me and he's doing it really great however... He's pretty busy with alot of spells, abilities and more more more so I didn't want to bug him with this request again.
You see. I'm making the quests for the ORPG. So far I made them GUI with alot of leaks and waits just to try it out. Now at this time I think the concept is "done" so I started trying to make a system to make it leakless in JASS.
On that last part I probably failed because my head can't take it anymore. My JASS knowledge isn't good enough to finish this so I'd like to ask people here if this is actually possible and if so, could you finish it for me?
This is what I want:
I want to be able to add multiple camera objects to a certain 'camera queue' so if one of them is done it automatically jumps to the other camera. This while at the SAME TIME unit transmissions are being queued in the same trigger and display while the camera's are panning.
This is how it looks like (with leaks): http://www.youtube.com/watch?v=fT-T2mQg_C0
This is the camera part of the "system" I came up with. I used some variables but those are supposed to become globals after I figure out how to make globals.
JASS:
library CameraPanning
function QueueCamera takes integer order, player p, camerasetup camera, real moveduration, real totalduration, boolean last returns nothing
local integer id = GetPlayerId(p)
local boolean keeponlooping = true
local boolean keeponlooping2 = true
local boolean keeponlooping3 = true
local integer i
if udg_CameraNumber[id] == 0 then
set udg_CameraNumber[id] = 1
endif
loop
exitwhen keeponlooping3 == false
if udg_CameraNumber[id] == order then
set keeponlooping3 = false
loop
exitwhen keeponlooping == false
if udg_CameraWait[id] == 0.00 then
set udg_CameraNumber[id] = udg_CameraNumber[id] + 1
set keeponlooping = false
set udg_CameraWait[id] = totalduration
set udg_Cinematic[id] = true
call CameraSetupApplyForPlayer(true, camera, p, moveduration)
if last == true then
loop
exitwhen keeponlooping2 == false
if udg_CameraWait[id] > 0.00 then
call TriggerSleepAction(0.5)
set udg_CameraWait[id] = ( udg_CameraWait[id] - 0.5)
else
set keeponlooping2 = false
set udg_Cinematic[id] = false
endif
endloop
endif
else
call TriggerSleepAction(0.5)
set udg_CameraWait[id] = ( udg_CameraWait[id] - 0.5)
endif
endloop
else
call TriggerSleepAction(0.5)
endif
endloop
endfunction
endlibrary
-
Camtest
-
Events
-
Player - Player 1 (Red) types a chat message containing testcamera as An exact match
-
-
Conditions
-
Actions
-
Custom script: local player p = GetTriggerPlayer()
-
Custom script: call UnlockCamera(p)
-
Cinematic - Turn on letterbox mode (hide interface) for (All players matching ((Triggering player) Equal to (==) (Matching player))): fade out over 9.00 seconds
-
Cinematic - Turn cinematic mode On for (All players matching (Player 1 (Red) Equal to (==) (Matching player))) over 0.20 seconds
-
Custom script: call QueueCamera(1, p, gg_cam_Camera1, 2., 3., false)
-
Custom script: call QueueCamera(2, p, gg_cam_Camera2, 2., 3., false)
-
Custom script: call QueueCamera(3, p, gg_cam_Camera3, 2., 3., true)
-
Custom script: call LockCameraUnit(p,PlayerHero[GetPlayerId(p)])
-
Cinematic - Turn cinematic mode Off for (All players matching (Player 1 (Red) Equal to (==) (Matching player))) over 0.20 seconds
-
Custom script: set p = null
-
-
The thing I want is that if I write this...
call QueueCamera(...)
call QueueCamera(...)
call QueueTransmission(...)
call QueueTransmission(...)
...the first queued camera and first queued transmission start at the same time. So far from what I made it works like this: The first camera starts moving then after its time is up the 2nd one moves. When the 2nd one's time is up the 1st transmission begins... I want it to start at the same time!!
But how???
[Thanks for reading this wall of text...]
P.S. Don't look at my weird way of looping and using udg_ stuff... I only wanted to make a basic version so my ORPG's coder only would have to change those weird things afterwards.