[Scummvm-cvs-logs] SF.net SVN: scummvm: [26463] scummvm/trunk/engines/lure

dreammaster at users.sourceforge.net dreammaster at users.sourceforge.net
Sat Apr 14 05:46:31 CEST 2007


Revision: 26463
          http://scummvm.svn.sourceforge.net/scummvm/?rev=26463&view=rev
Author:   dreammaster
Date:     2007-04-13 20:46:30 -0700 (Fri, 13 Apr 2007)

Log Message:
-----------
Added script method for barmen serving player

Modified Paths:
--------------
    scummvm/trunk/engines/lure/scripts.cpp
    scummvm/trunk/engines/lure/scripts.h

Modified: scummvm/trunk/engines/lure/scripts.cpp
===================================================================
--- scummvm/trunk/engines/lure/scripts.cpp	2007-04-14 03:44:52 UTC (rev 26462)
+++ scummvm/trunk/engines/lure/scripts.cpp	2007-04-14 03:46:30 UTC (rev 26463)
@@ -439,6 +439,21 @@
 	hotspot->tickProcOffset = 0x7efa;
 }
 
+// Barman serving the player
+
+void Script::barmanServe(uint16 v1, uint16 v2, uint16 v3) {
+	Resources &res = Resources::getReference();
+	Hotspot *player = res.getActiveHotspot(PLAYER_ID);
+	BarEntry &barEntry = res.barmanLists().getDetails(player->roomNumber());
+	
+	for (int index = 0; index < NUM_SERVE_CUSTOMERS; ++index) {
+		if (barEntry.customers[index].hotspotId == PLAYER_ID) {
+			barEntry.customers[index].serveFlags |= 5;
+			break;
+		}
+	}
+}
+
 // Stores the current number of groats in the general field
 
 void Script::getNumGroats(uint16 v1, uint16 v2, uint16 v3) {
@@ -534,6 +549,7 @@
 	{50, Script::givePlayerItem},
 	{51, Script::decreaseNumGroats},
 	{54, Script::setVillageSkorlTickProc},
+	{56, Script::barmanServe},
 	{57, Script::getNumGroats},
 	{62, Script::animationLoad},
 	{63, Script::addActions},

Modified: scummvm/trunk/engines/lure/scripts.h
===================================================================
--- scummvm/trunk/engines/lure/scripts.h	2007-04-14 03:44:52 UTC (rev 26462)
+++ scummvm/trunk/engines/lure/scripts.h	2007-04-14 03:46:30 UTC (rev 26463)
@@ -116,6 +116,7 @@
 	static void givePlayerItem(uint16 hotspotId, uint16 v2, uint16 v3);
 	static void decreaseNumGroats(uint16 characterId, uint16 numGroats, uint16 v3);
 	static void setVillageSkorlTickProc(uint16 v1, uint16 v2, uint16 v3);
+	static void barmanServe(uint16 v1, uint16 v2, uint16 v3);
 	static void getNumGroats(uint16 v1, uint16 v2, uint16 v3);
 	static void animationLoad(uint16 hotspotId, uint16 v2, uint16 v3);
 	static void addActions(uint16 hotspotId, uint16 actions, uint16 v3);


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list