Previous 199869 Revisions Next

r33663 Wednesday 3rd December, 2014 at 23:55:39 UTC by hap
(MESS)Game promoted to working
------------------
Code Name: Sector [hap, seanriddle]
[src/mess/drivers]cnsector.c comp4.c ticalc1x.c
[src/mess/layout]cnsector.lay

trunk/src/mess/drivers/cnsector.c
r242174r242175
44
55  Parker Brothers Code Name: Sector
66  * MP0905BNL ZA0379 (die labeled 0970F-05B)
7 
8  This is a tabletop submarine pursuit game. A grid board and small toy
9  boats are used to remember your locations (a Paint app should be ok too).
10  Refer to the official manual for more information, it is not a simple game.
711
812
913***************************************************************************/
r242174r242175
149153
150154static INPUT_PORTS_START( cnsector )
151155   PORT_START("IN.0") // O0
152   PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_Q) // ?  next
153   PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_W) // ?  left
154   PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_E) // nc?
155   PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_R) // ?  range
156   PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_Q) PORT_NAME("Next Ship")
157   PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_A) PORT_NAME("Left")
158   PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNUSED )
159   PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_Z) PORT_NAME("Range")
156160
157161   PORT_START("IN.1") // O1
158   PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_T) // ?  aim
159   PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_Y) // ?  right
160   PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_U) // nc?
161   PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_I) // ?nc
162   PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_X) PORT_NAME("Aim")
163   PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_S) PORT_NAME("Right")
164   PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNUSED )
165   PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNUSED )
162166
163167   PORT_START("IN.2") // O2
164   PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_O) // ?  fire
165   PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_A) // ?  evasive
166   PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_S) // nc?
167   PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_D) // ?  recall
168   PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_C) PORT_NAME("Fire")
169   PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_J) PORT_NAME("Evasive Sub") // expert button
170   PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNUSED )
171   PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_E) PORT_NAME("Recall")
168172
169173   PORT_START("IN.3") // O3
170   PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_F) // ?  finder
171   PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_G) // ?  slow
172   PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_H) // nc?
173   PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_J) // ?nc
174   PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_M) PORT_NAME("Sub Finder") // expert button
175   PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_F) PORT_NAME("Slower")
176   PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNUSED )
177   PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_UNUSED )
174178
175179   PORT_START("IN.4") // O4
176   PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_K) // ?  teach
177   PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_L) // ?  fast
178   PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_Z) // nc?
179   PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_X) // ?  move
180   PORT_BIT( 0x01, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_B) PORT_NAME("Teach Mode")
181   PORT_BIT( 0x02, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_G) PORT_NAME("Faster")
182   PORT_BIT( 0x04, IP_ACTIVE_HIGH, IPT_UNUSED )
183   PORT_BIT( 0x08, IP_ACTIVE_HIGH, IPT_KEYBOARD ) PORT_CODE(KEYCODE_T) PORT_NAME("Move Ship")
180184INPUT_PORTS_END
181185
182186
r242174r242175
194198   memset(m_leds_decay, 0, sizeof(m_leds_decay));
195199   m_o = 0;
196200   
201   save_item(NAME(m_leds_state));
202   save_item(NAME(m_leds_cache));
203   save_item(NAME(m_leds_decay));
197204   save_item(NAME(m_o));
198205}
199206
r242174r242175
238245ROM_END
239246
240247
241CONS( 1977, cnsector, 0, 0, cnsector, cnsector, driver_device, 0, "Parker Brothers", "Code Name: Sector", GAME_NOT_WORKING | GAME_SUPPORTS_SAVE | GAME_NO_SOUND_HW )
248CONS( 1977, cnsector, 0, 0, cnsector, cnsector, driver_device, 0, "Parker Brothers", "Code Name: Sector", GAME_SUPPORTS_SAVE | GAME_NO_SOUND_HW )
trunk/src/mess/drivers/comp4.c
r242174r242175
3737   required_device<cpu_device> m_maincpu;
3838   required_ioport_array<3> m_button_matrix;
3939
40   UINT16 m_o;
41
4042   UINT16 m_leds_state;
4143   UINT8 m_leds_decay[0x10];
42   UINT16 m_r;
43   UINT16 m_o;
4444
4545   DECLARE_READ8_MEMBER(read_k);
4646   DECLARE_WRITE16_MEMBER(write_o);
r242174r242175
116116   // R2    R7
117117   // R1    R6
118118   // R0    R5
119   m_r = data;
120   
121   m_leds_state = m_r;
119   m_leds_state = data;
122120   leds_update();
123121}
124122
r242174r242175
170168{
171169   m_leds_state = 0;
172170   memset(m_leds_decay, 0, sizeof(m_leds_decay));
173   m_r = 0;
174171   m_o = 0;
175172   
176   save_item(NAME(m_r));
173   save_item(NAME(m_leds_state));
174   save_item(NAME(m_leds_decay));
177175   save_item(NAME(m_o));
178176}
179177
trunk/src/mess/drivers/ticalc1x.c
r242174r242175
632632   m_r = 0;
633633   m_o = 0;
634634
635   save_item(NAME(m_leds_state));
636   save_item(NAME(m_leds_cache));
637   save_item(NAME(m_leds_decay));
635638   save_item(NAME(m_r));
636639   save_item(NAME(m_o));
637640}
trunk/src/mess/layout/cnsector.lay
r242174r242175
33
44<!-- define elements -->
55
6   <element name="static_black"><rect><color red="0.0" green="0.0" blue="0.0" /></rect></element>
7   <element name="static_white"><rect><color red="0.95" green="0.95" blue="0.95" /></rect></element>
8   <element name="static_gray"><rect><color red="0.60" green="0.75" blue="0.63" /></rect></element>
9   <element name="static_red"><rect><color red="0.35" green="0.02" blue="0.04" /></rect></element>
10
611   <element name="digit" defstate="0">
712      <led7seg><color red="1.0" green="0.25" blue="0.20" /></led7seg>
813   </element>
r242174r242175
1217      <disk state="0"><color red="0.2" green="0.0" blue="0.0" /></disk>
1318   </element>
1419
20   <element name="text_ship">
21      <text string="SHIP"><color red="0.95" green="0.95" blue="0.95" /></text>
22   </element>
23   <element name="text_speed">
24      <text string="SPEED"><color red="0.95" green="0.95" blue="0.95" /></text>
25   </element>
1526
27   <element name="text_north">
28      <text string="NORTH" align="2"><color red="0.95" green="0.95" blue="0.95" /></text>
29   </element>
30   <element name="text_east">
31      <text string="EAST" align="1"><color red="0.95" green="0.95" blue="0.95" /></text>
32   </element>
33
34   <element name="text_depth">
35      <text string="DEPTH"><color red="0.95" green="0.95" blue="0.95" /></text>
36   </element>
37   <element name="text_range">
38      <text string="RANGE"><color red="0.95" green="0.95" blue="0.95" /></text>
39   </element>
40
41   <element name="text_n">
42      <rect><color red="0.35" green="0.02" blue="0.04" /></rect>
43      <text string="N"><color red="0.88" green="0.85" blue="0.85" /></text>
44   </element>
45   <element name="text_s">
46      <rect><color red="0.35" green="0.02" blue="0.04" /></rect>
47      <text string="S"><color red="0.88" green="0.85" blue="0.85" /></text>
48   </element>
49   <element name="text_e">
50      <rect><color red="0.35" green="0.02" blue="0.04" /></rect>
51      <text string="E"><color red="0.88" green="0.85" blue="0.85" /></text>
52   </element>
53   <element name="text_w">
54      <rect><color red="0.35" green="0.02" blue="0.04" /></rect>
55      <text string="W"><color red="0.88" green="0.85" blue="0.85" /></text>
56   </element>
57
58
59
1660<!-- build screen -->
1761
1862   <view name="Internal Layout">
19      <bounds left="0" right="200" top="0" bottom="200" />
63      <bounds left="0" right="92" top="0" bottom="146" />
64      <bezel element="static_black">
65         <bounds left="0" right="92" top="0" bottom="146" />
66      </bezel>
2067
68   <!-- digits -->
69
70      <bezel element="static_white"><bounds x="0" y="4" width="100" height="1" /></bezel>
71      <bezel element="static_white"><bounds x="0" y="12" width="100" height="1" /></bezel>
72
73      <bezel element="static_white"><bounds x="20" y="4.5" width="1" height="40" /></bezel>
74      <bezel element="static_white"><bounds x="41" y="4.5" width="1" height="40" /></bezel>
75
76      <bezel element="static_white"><bounds x="67" y="4.5" width="1" height="8" /></bezel>
77
78      <bezel element="static_white"><bounds x="20.5" y="36" width="80" height="1" /></bezel>
79      <bezel element="static_white"><bounds x="0" y="44" width="100" height="1" /></bezel>
80
81      <bezel element="text_ship"><bounds x="0" y="5" width="20" height="7" /></bezel>
82      <bezel element="text_speed"><bounds x="21" y="5" width="20" height="7" /></bezel>
83
84      <bezel element="text_north"><bounds x="47" y="5" width="19" height="7" /></bezel>
85      <bezel element="text_east"><bounds x="69" y="5" width="19" height="7" /></bezel>
86
87      <bezel element="text_depth"><bounds x="21" y="37" width="20" height="7" /></bezel>
88      <bezel element="text_range"><bounds x="57" y="37" width="20" height="7" /></bezel>
89
90
2191      <bezel name="digit5" element="digit">
22         <bounds x="0" y="0" width="10" height="15" />
92         <bounds x="5" y="17" width="10" height="15" />
2393      </bezel>
94
2495      <bezel name="digit4" element="digit">
25         <bounds x="20" y="0" width="10" height="15" />
96         <bounds x="26" y="17" width="10" height="15" />
2697      </bezel>
98
2799      <bezel name="digit3" element="digit">
28         <bounds x="40" y="0" width="10" height="15" />
100         <bounds x="47" y="17" width="10" height="15" />
29101      </bezel>
30102      <bezel name="digit2" element="digit">
31         <bounds x="50" y="0" width="10" height="15" />
103         <bounds x="57" y="17" width="10" height="15" />
32104      </bezel>
33105      <bezel name="digit1" element="digit">
34         <bounds x="60" y="0" width="10" height="15" />
106         <bounds x="67" y="17" width="10" height="15" />
35107      </bezel>
36108      <bezel name="digit0" element="digit">
37         <bounds x="70" y="0" width="10" height="15" />
109         <bounds x="77" y="17" width="10" height="15" />
38110      </bezel>
39111
112
113   <!-- compass -->
114
115      <bezel element="static_gray"><bounds x="0" y="50" width="100" height="100" /></bezel>
116      <bezel element="static_red"><bounds x="0" y="55" width="100" height="86" /></bezel>
117
40118      <bezel name="lamp0" element="lamp">
41         <bounds x="20" y="20" width="5" height="5" />
119         <bounds x="42" y="62" width="8" height="8" />
42120      </bezel>
43121      <bezel name="lamp1" element="lamp">
44         <bounds x="20" y="30" width="5" height="5" />
122         <bounds x="42" y="126" width="8" height="8" />
45123      </bezel>
46124      <bezel name="lamp2" element="lamp">
47         <bounds x="30" y="25" width="5" height="5" />
125         <bounds x="74" y="94" width="8" height="8" />
48126      </bezel>
49127      <bezel name="lamp3" element="lamp">
50         <bounds x="10" y="25" width="5" height="5" />
128         <bounds x="10" y="94" width="8" height="8" />
51129      </bezel>
52130
131      <bezel element="text_n"><bounds x="41" y="72" width="10" height="10" /></bezel>
132      <bezel element="text_s"><bounds x="41" y="114" width="10" height="10" /></bezel>
133      <bezel element="text_e"><bounds x="63" y="93" width="10" height="10" /></bezel>
134      <bezel element="text_w"><bounds x="21" y="93" width="10" height="10" /></bezel>
135
136
137   <!-- crop borders -->
138
139      <bezel element="static_black"><bounds x="92" y="0" width="10" height="160" /></bezel>
140      <bezel element="static_black"><bounds x="0" y="146" width="100" height="10" /></bezel>
141
53142   </view>
54143</mamelayout>


Previous 199869 Revisions Next


© 1997-2024 The MAME Team