Page 1 of 2

Abyssea - Altepa

Posted: Mon Aug 19, 2013 12:10 pm
by demolish
Added dialogue to all NPCs in Abyssea - Altepa.

EDIT: Will re-upload once it's working 100%

Re: Abyssea - Altepa

Posted: Mon Aug 19, 2013 6:43 pm
by whasf
Aren't the conflux's supposed to cost points or something to use?

Re: Abyssea - Altepa

Posted: Mon Aug 19, 2013 7:30 pm
by Zerahn
they totally are, unless you're warping to conflux 0, or i think 8 in the zones that have a bastion outpost.

Re: Abyssea - Altepa

Posted: Mon Aug 19, 2013 7:51 pm
by kjLotus
Zerahn wrote:they totally are, unless you're warping to conflux 0, or i think 8 in the zones that have a bastion outpost.
01 is entrance, 00 is outpost

it costs cruor to teleport to entrance from anything other than 00

Re: Abyssea - Altepa

Posted: Tue Aug 20, 2013 6:06 am
by demolish
Yeah just added basic dialog and @pos to their scripts so someone can work on getting it working properly.
EDIT: Veridical Conflux's had a lot of params in their events, im working on them now.

Re: Abyssea - Altepa

Posted: Tue Aug 20, 2013 9:21 pm
by Troak
Here's some initial onTrigger work I got done for one of the confluxes after talking to you on IRC.

Code: Select all

function onTrigger(player,npc)
	
	local mask = player:getVar('ConfluxMask[Altepa]');
	local activated = player:getMaskBit(mask,0);
	local cruor = player:getVar('Cruor');
	local cost = 1
	if(player:hasKeyItem(IVORY_ABYSSITE_OF_CONFLUENCE) then
		cost = cost - 0.2
	end
	if(player:hasKeyItem(CRIMSON_ABYSSITE_OF_CONFLUENCE) then
		cost = cost - 0.2
	end
	if(player:hasKeyItem(INDIGO_ABYSSITE_OF_CONFLUENCE) then
		cost = cost - 0.2
	end
	if(activated) then
		player:startEvent(0x0854, (600 + 800 * 65536) * cost, (1000 + 1200 * 65536) * cost, (1400 + 1600 * 65536) * cost, (1800 + 2000 * 65536) * cost, mask, 9, 1, cruor);
	else
		player:startEvent(0x0854, 50 * cost, 0, 0, 0, 0, 0, 2, cruor);
	end
	
end; 
Haven't coded any of the onEventFinish stuff. Obviously, depending on the options selected, various things need to happen. If activated, need to add a bit to the mask variable 'ConfluxMask[Altepa]'. If a teleport is taken, then the proper amount of cruor needs to be subtracted from the player's cruor (which for now I just left in the player variable 'Cruor' and the player needs to be teleported to the correct position. The csid and parameters correlate specifically to Veridical Conflux #01 in Abyssea-Altep. Finally, the cruor values to teleport to each conflux are technically wrong since those are supposed to be based on the distance between the confluxes I guess. Accurate values would have to be taken from retail.

Re: Abyssea - Altepa

Posted: Tue Aug 20, 2013 9:22 pm
by Troak
Also I didn't actually test the script itself (only tested with @cs) so there could be typos or bad scripting in there...
Requires keyitems.lua as well.

Re: Abyssea - Altepa

Posted: Wed Aug 21, 2013 7:23 am
by demolish
Seems like client and server interpreting "(600 + 800 * 65536) * cost" differently.
Client is seeing it as 600 where server is seeing it as 52429400 so it wont allow you to teleport

Re: Abyssea - Altepa

Posted: Wed Aug 21, 2013 8:34 am
by Troak
Do you mean when you are trying to pass on the cruor cost in onEventFinish()?
If that's what you mean, you'll probably have to redefine the costs for each conflux within onEventFinish().

Re: Abyssea - Altepa

Posted: Wed Aug 21, 2013 8:45 am
by demolish
Change the first param after the csid to 600 or something and set your chars cruor to 1234.
Try to teleport and it'll display the teleport animation but if you use (600 + 800 * 65536) instead of 600 in the event params it seems like the server reads that as 52429400 and expects the player to have 52429400 cruor cause it wont let you teleport/show the animation

EDIT: Well i take that back. Looks like it wont show the tele animation unless the param after csid is set to 1